On 07. 09. 22 19:46, Peter Cheung wrote:
hi
    1. I want to customize the editor's side bar (the one showing the line 
number), I want to add some icon to it. Any example for this?

Two ways:
1/ register a sidebar on the 'west' side. See editor.fold.nbui module - you're free to paint whatever you want. 2/ make an annotation and assign a glyph to it. See the Editor Annotations APIs, e.g. debugger annotations for example.

    2. The highlightfactory + highlighter is highlighting the editor by char 
offset. Is it possible to highlight some rows?

At least two ways.
- make an AnnotationType of 'line' type. Use Annoation API to mark the line.
- make the highlight include the terminating newline and include HighlightsContainer.ATTR_EXTENDS_EOL = true in its attributes.

-S.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@netbeans.apache.org
For additional commands, e-mail: dev-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists



Reply via email to