Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » IMP » Toggle comment behavior in LPG editor
Toggle comment behavior in LPG editor [message #576563] Sun, 13 September 2009 01:37
Brian Payton is currently offline Brian PaytonFriend
Messages: 152
Registered: July 2009
Senior Member
Here's a minor fit'n'finish item I came across in the LPG source editor.

In the editor, the "Toggle comment" action (Ctrl+/) adds LPG comments in
a way that is kind of ugly. Let's say you have a rule like this:

col_expr_cl ::=
col_expr_spec
| col_expr_cl , col_expr_spec

The toggle comment action does this:

-- col_expr_cl ::=
-- col_expr_spec
-- | col_expr_cl , col_expr_spec

The equivalent action in the Java editor works a little differently. If
you toggle comments on this:

if (uniqueOpt != null) {
index.setUnique(true);
}

you get this:

// if (uniqueOpt != null) {
// index.setUnique(true);
// }

which I think makes it easier to spot sections of code that are
commented out.
Previous Topic:Missing lpg Fragment
Next Topic:LPG editor text coloring
Goto Forum:
  


Current Time: Sun Dec 21 23:57:18 GMT 2014

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

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