This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 172845

Summary: display gray background for read only files
Product: editor Reporter: Ondrej Langr <olangr>
Component: Painting & PrintingAssignee: issues@editor <issues>
Status: RESOLVED FIXED    
Severity: blocker Keywords: SIMPLEFIX
Priority: P2    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:
Attachments: generated code sections ...

Description Ondrej Langr 2009-09-23 10:10:48 UTC
Currently a read only file is indicated in the tab by a gray font, which is not too easy to spot. 

Since read-only file obviously can not be modified, the same indication for all code in read-only file should be used as
is for example for generated (read-only) code in jFrames. 

In other words, read-only files should have gray background for all code when opened, to immediately communicate that
they cannot be edited.
Comment 1 Vitezslav Stejskal 2009-11-20 07:46:00 UTC
How should the gray background be positioned to other highlights that also set background colors, eg current line, text selection, text search, mark occurences, etc. What shade of gray it should be? The same as for the guarded sections? Thanks
Comment 2 Ondrej Langr 2009-11-24 03:00:52 UTC
Created attachment 91585 [details]
generated code sections ... 

Please use the same appearance & highlighting as in generated code sections ..
Comment 3 Vitezslav Stejskal 2009-12-22 08:59:31 UTC
http://hg.netbeans.org/jet-main/rev/e6d34a0b43db
Comment 4 Quality Engineering 2009-12-27 23:37:18 UTC
Integrated into 'main-golden', will be available in build *200912280201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/e6d34a0b43db
User: Vita Stejskal <vstejskal@netbeans.org>
Log: #172845: display gray background for read only files
Comment 5 Vladimir Voskresensky 2009-12-28 04:07:57 UTC
Hello Ondrej,

Could you, please, think over this decision once more based on daily bits.
Looks quite strange and hard for eyes... 
Italic in header was not annoying at all, but blinking backgrounds of files is too colorful.
Now any navigation into library class (like String) changes background.
In our (C++) area any jump into system header file change background as well.

I understand that "same" approach for read-only blocks is a good idea, but generated (read-only) code in jFrames is collapsed by default and all other background is consistent with other editors, while now editors are blinking and it's very hard for eyes
Comment 6 meeks 2011-07-12 17:15:25 UTC
see 180826
Comment 7 Miloslav Metelka 2011-08-11 15:53:47 UTC
Closing as this should work fine AFAIK.