Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 155143 - BaseCaret doesn't respect CARET_COLOR_OVERWRITE_MODE anymore
BaseCaret doesn't respect CARET_COLOR_OVERWRITE_MODE anymore
Status: RESOLVED FIXED
Product: editor
Classification: Unclassified
Component: Painting & Printing
6.x
All All
: P3 (vote)
: 6.x
Assigned To: michaelpigg
issues@editor
: NETFIX, SIMPLEFIX
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-12-10 14:43 UTC by emi
Modified: 2009-10-14 10:35 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
:


Attachments
Use CARET_COLOR_OVERWRITE_MODE in BaseCaret (1.33 KB, patch)
2008-12-10 14:44 UTC, emi
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description emi 2008-12-10 14:43:15 UTC
Hy,

BaseCaret doesn't use the CARET_COLOR_OVERWRITE_MODE value anymore, it uses CARET_COLOR_INSERT_MODE for insert *and*
overwrite.

This seems to be a regression starting revision 84624 : d8ca6bd84a75 (
http://hg.netbeans.org/main/diff/d8ca6bd84a75/editor.lib/src/org/netbeans/editor/BaseCaret.java ).

See the attached patch which fixes the problem.

PS: I don't take credit for this patch, I'm just posting it here. It's done by Andreea Pitici, a work colleague of mine
from Joseki Bold.
Comment 1 emi 2008-12-10 14:44:01 UTC
Created attachment 74807 [details]
Use CARET_COLOR_OVERWRITE_MODE in BaseCaret
Comment 2 Miloslav Metelka 2009-01-07 13:01:40 UTC
Thanks for the patch. However there must be a visual setting added into the tools->options as well (currently there's
just 'Caret color').
Comment 3 emi 2009-01-07 13:16:33 UTC
Indeed I guess there should also something in Tools->Options.

But that doesn't keep the bug from happening when CARET_COLOR_OVERWRITE_MODE is changed programatically. This is how we
found the bug actually.
Comment 4 Jiri Kovalsky 2009-03-30 15:15:48 UTC
Miloslav Metelka agreed that he would review and integrate a patch for this issue contributed by the NetFIX [1] team.

[1] http://wiki.netbeans.org/NetFIX
Comment 5 Vitezslav Stejskal 2009-10-09 13:38:45 UTC
dd9f35712718 - applied the patch and added 'Caret Color (Overwrite mode)' among Tools-Options -> Fonts & Colors ->
Highlights. Thanks for the patch
Comment 6 Quality Engineering 2009-10-14 10:35:44 UTC
Integrated into 'main-golden', will be available in build *200910140201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/dd9f35712718
User: Vita Stejskal <vstejskal@netbeans.org>
Log: #155143: Adding 'Caret Color (Overwrite mode)' setting and fixing BaseCaret to use it (thanks to Emilian Bold and Andreea Pitici)


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo