Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Need some help regarding with MultiLineRule
Need some help regarding with MultiLineRule [message #464491] Fri, 09 March 2007 06:33 Go to next message
SarayuGeethanjali is currently offline SarayuGeethanjaliFriend
Messages: 7
Registered: July 2009
Junior Member
Hi,

I need to Highlight multiple lines in a text editor.

Eg:

IMPORTS
A,
B,
c;

Color color_oid = new Color(Display.getCurrent(), 0, 0, 205);
IToken oid = new Token(new TextAttribute(color_oid, null, SWT.NONE));
rules[i++] = new MultiLineRule("IMPORTS ", ";", oid);

By this way I am not able to highlight the multiple lines. But when I give
one extra space before IMPORTS word, it is highlighting.


(one space)IMPORTS
A,
B,
c;

rules[i++] = new MultiLineRule(" IMPORTS",";", oid);

There is no extra space before the "IMPORTS" word in all files which I
need to highlight multiple lines.

Please let me know how to handle this one.

Thanks,
Sarayu.
Re: Need some help regarding with MultiLineRule [message #464602 is a reply to message #464491] Mon, 12 March 2007 13:47 Go to previous message
Dani Megert is currently offline Dani MegertFriend
Messages: 3802
Registered: July 2009
Senior Member
SarayuGeethanjali wrote:

> Hi,
>
> I need to Highlight multiple lines in a text editor.
>
> Eg:
>
> IMPORTS
> A,
> B,
> c;
>
> Color color_oid = new Color(Display.getCurrent(), 0, 0, 205);
> IToken oid = new Token(new TextAttribute(color_oid, null, SWT.NONE));
> rules[i++] = new MultiLineRule("IMPORTS ", ";", oid);
>
> By this way I am not able to highlight the multiple lines. But when I
> give
> one extra space before IMPORTS word, it is highlighting.
>
>
> (one space)IMPORTS
> A,
> B,
> c;
>
> rules[i++] = new MultiLineRule(" IMPORTS",";", oid);
>
> There is no extra space before the "IMPORTS" word in all files which I
> need to highlight multiple lines.
>
> Please let me know how to handle this one.

Maybe you are seeing https://bugs.eclipse.org/bugs/show_bug.cgi?id=174061

Dani

>
> Thanks,
> Sarayu.
>
>
>
Previous Topic:[CommonNavigator] Dependency on org.eclipse.ui.ide and others
Next Topic:Why does Window->Open Perspective lauch a new instance of the rcp App?
Goto Forum:
  


Current Time: Sat Sep 07 10:39:47 GMT 2024

Powered by FUDForum. Page generated in 0.03707 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top