1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 12:07:45 +00:00

TextEditor+LibGUI: Add case matching and wrap around optionality

Adds simple ASCII case matching and wrap around toggles to
TextEditor's find/replace widget and reorganizes its layout
This commit is contained in:
thankyouverycool 2021-02-21 19:01:26 -05:00 committed by Andreas Kling
parent b4c0314f1d
commit 3e987eba2b
5 changed files with 98 additions and 106 deletions

View file

@ -109,8 +109,8 @@ public:
Vector<TextRange> find_all(const StringView& needle, bool regmatch = false);
void update_regex_matches(const StringView&);
TextRange find_next(const StringView&, const TextPosition& start = {}, SearchShouldWrap = SearchShouldWrap::Yes, bool regmatch = false);
TextRange find_previous(const StringView&, const TextPosition& start = {}, SearchShouldWrap = SearchShouldWrap::Yes, bool regmatch = false);
TextRange find_next(const StringView&, const TextPosition& start = {}, SearchShouldWrap = SearchShouldWrap::Yes, bool regmatch = false, bool match_case = true);
TextRange find_previous(const StringView&, const TextPosition& start = {}, SearchShouldWrap = SearchShouldWrap::Yes, bool regmatch = false, bool match_case = true);
TextPosition next_position_after(const TextPosition&, SearchShouldWrap = SearchShouldWrap::Yes) const;
TextPosition previous_position_before(const TextPosition&, SearchShouldWrap = SearchShouldWrap::Yes) const;