PavelTorgashov / FastColoredTextBox

Fast Colored TextBox for Syntax Highlighting. The text editor component for .NET.
Other
1.21k stars 463 forks source link

Change text in Find Dialog #231

Closed NotroDev closed 2 years ago

NotroDev commented 3 years ago

Hi, it's possible to change text inside find (and find & replace) dialog? I would like to be able to adapt them to the chosen user language. And if that's not possible, it would be nice to have this feature in the next update.

Daxanius commented 2 years ago

Hey! I was just looking trough the pull requests and issues for things I could improve on my own variant and stumbled upon this.

I don't know if you still need this, but I'm currently working on a fork of this repo for my own project. It's available on NuGet and I'll definetly be looking at feedback here and seeing how I can improve upon it.

Link: https://www.nuget.org/packages/Dax-FCTB/

In my fork, it's possible to change the find/replace/goto dialogs trough code by just changing the FindForm, ReplaceForm or GoToForm properties of FastColoredTextBox.

Heres an example on how you can do this:

fastColoredTextBox.FindForm = new(fastColoredTextBox) {
    BackColor = Color.Black,
    ForeColor = Color.White,
    Text = "Form title!"
};

Keep in mind this fork is still very much a work in progress and things will change in the future.