Can I specify an 'autocase' for RegEx patterns in Dynamic language

SyntaxEditor for Windows Forms Forum

Posted 11 years ago by Michael Dempsey - Sr. Developer, Teradata Corp
Version: 12.1.0303
Avatar

My dynamic language conains about 400 keywords of which only 6 are defined using RexEx patterns.

All Explicit patterns are defined in uppercase with AutoCaseCorrect.

I need to be able to specify that the keywords matching the RegEx patterns are also uppercased.
I realize that 'AutoCaseCorrect' makes no sense for a RegEx pattern but is there an 'AutoCase=Upper' or similar?

When I first created my app (using another companies editor) customers quickly complained about a few keywords that failed to display in uppercase. That vendor added a Case property that allowed me to fix the problem.

I am now converting the app to SyntaxEditor and need a way around the problem.

If there is no such option currently please add this as a request for future addition.
(The request would be to support Upper, Lower, and maybe Proper, 'auto' case options on RegEx pattern groups)

Thanks

  

fi

Comments (2)

Posted 11 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hi Mike,

Sorry but we don't have any such option right now.  We have the CaseSensitivity option on explicit patterns but that doesn't work on regexes.  I'll log the request to add an auto case option.

For more info, could you describe some of the patterns and output keywords that you want to see here?  Just so we get a better idea of the context for this request.  Thanks!


Actipro Software Support

Posted 11 years ago by Michael Dempsey - Sr. Developer, Teradata Corp
Avatar

One example would be:
    PatternValue="(BT|BEGIN\s+TRANSACTION)"

I have to use a RegEx here for 2 reasons:
a) The user may type tabs or multiple spaces between 'Begin' and 'Transaction'
b) Either of these options (BT or the compound string) constitutes the start of an AutoOutlining block

similarly
    PatternValue="(ET|END\s+TRANSACTION)"
represents the end of the above outlining block.

And PatternValue="\.SET\s+\w*"

There are also half a dozen other 'compond' keywords ('END IF', 'END LOOP' etc.) that should also be defined as RegEx patterns but I am currently defining them as explicit patters (and hoping the user does not type multiple spaces or tabs) in order to avoid the casing problem. (These also define outlining blocks)

The latest build of this product (v24.1.0) was released 2 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.