eclipse texteditor: source code folding

M

Martin

I have written an eclipse source code text editor plugin.
Now I want to do source code folding (collapsible sections). It should
be possible to collapse "do-end" sections.

In my myTextEditor, I have a createSourceViewer, createPartControl and
getAdapter.

For testing, I added an annotation within the method
"createpartControl".
This worked and the source code can now collapsed at one position.

But of course, addAnnotation should not be in createPartControl.
It shoud be placed in a code part which is called when the source code
is loaded and after changes in the source code.

So where is this? Where do i have to place "addAnnotation"?

Jens Martin Schlatter
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top