Web forum is in read-only mode. Login as active registered customer for write access
  Forum Search   New Posts New Posts

TAdvMemo, check if in comment

 Post Reply Post Reply
Author
Werner Stefan View Drop Down
New Member
New Member
Avatar

Joined: 05 Mar 2019
Posts: 2
Post Options Post Options   Quote Werner Stefan Quote  Post ReplyReply Direct Link To This Post Topic: TAdvMemo, check if in comment
    Posted: 17 May 2019 at 8:36am
Hi,

I'm using TAdvMemo in my project. For a special feature I need to check if the caret (CurX, CurY) is currently located inside a (multi-line) comment or a quoted text. Is this possible?

Kind regards,

Stefan
Back to Top
Bruno Fierens View Drop Down
TMS Support
TMS Support
Avatar

Joined: 11 May 2010
Posts: 7701
Post Options Post Options   Quote Bruno Fierens Quote  Post ReplyReply Direct Link To This Post Posted: 18 May 2019 at 8:55am
Unfortunately there is no such function available at this time.
The only function we could easily expose is to get the style of a line, i.e. retrieve whether a line is a comment line. We can add a function like:
if AdvMemo.GetLineStyle(ALine).isComment then...

That is something we could add for the next update of TAdvMemo.
To get the same per token, i.e. at X,Y position will be a lot more work to integrate.
Back to Top
Werner Stefan View Drop Down
New Member
New Member
Avatar

Joined: 05 Mar 2019
Posts: 2
Post Options Post Options   Quote Werner Stefan Quote  Post ReplyReply Direct Link To This Post Posted: 18 May 2019 at 10:05am
Thank you for the answer, it would be nice if you can implement this feature in to the next update.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down