Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

SyntaxEdit and Find Find/Replace Dialog

I'm using LMDEditExecFindDialog() to display the find dialog for SyntaxEdit.

One thing that would be REALLY USEFUL is if the find and find/replace dialogs remembered their last positions and sizes. It's really annoying when someone has to resize or reposition these dialogs constantly.

What is the easiest way to have a Find dialog (and Find/Replace dialog) that remembers its size (width being most important) and (preferably) also its position? Could you add some properties to TLMDEditSearchDlgOptions for the dialog size and location and track them that way?

Or what is the best way for me to implement this in my application?

Thank you!

Comments

  • 9 Comments sorted by Votes Date Added
  • Hi,

    We will consider this feature for the next release. Its probably not so complex to implement, and I think, its will be usefull addition.
  • Great, thank you. I agree that it would be very useful and should be easy to implement.

    Oh, on a related note, when you try to resize the find dialog and the replace dialog vertically, the vertical double arrow appears to indicate that this is possible, but vertical resize of these dialogs is not possible, only horizontal resize. Not a big deal but if you can easily fix this then I think you should.
  • edited December 2017 Posts: 177Vote Up0Vote Down
    So I downloaded the latest version and it does not appear that this change was made. :( I really wanted to include this in my next major release but I guess that won't happen.

    Can this be improved for the next release? I'd really like the find and find/replace dialogs to remember their position and sizes... at least during a single run.
  • Done. 

    I've added Position property for Find and Replace dialogs (and corresponding low-level functions options). Also, new FindDialogPos and FindDialogWidth global variables, which allow to store dialogs position, have been added.
  • Great! Thank you!
  • edited February 2018 Posts: 177Vote Up0Vote Down
    I updated to LMD SyntaxEdit 2018.0 and the Find and Replace dialogs are not remembering their positions or widths.

    Also, FindDialogWidth is 0 before and after calling this function:
      TLMDEditSearchResult sresult{LMDEditExecFindDialog(dialogcaption,Edit,LMDSearchDlgOptions)};

    Shouldn't the last width of the find dialog be stored in FindDialogWidth?

    So either it's not working or I'm doing something wrong... what could be the problem? I really wanted to finally get this into my application.

  • Hi,

    You need to set SearchOptions.Position, for example: 

    SearchOptions.Position := [spRememberPos, spRememberWidth]
  • Ahh.... OK... it works! Good addition but perhaps it should remember position and width by default?

    Thanks!

    I really wish you guys would add some new features to your editor. Of all the other editors I've tried (in order to "modernize" the editor in my app), they seem to have enough problems and bugs that it hasn't been worth the time and hassle of switching from SyntaxEdit which has worked "well enough" and reliably enough for years.

    For example, one feature I'd really like to see is a vertical color bar in the gutter that shows which lines have changed and which are unsaved. That is really useful... plus highlighting all occurrences of a search simultaneously.
  • > Good addition but perhaps it should remember position and width by default?

    No. For backward compatibility.
Sign In or Register to comment.