D23457: Port regex search to QRegularExpression

Ahmad Samir noreply at phabricator.kde.org
Sun Aug 25 22:19:22 BST 2019


ahmadsamir created this revision.
ahmadsamir added reviewers: KTextEditor, dhaumann, cullmann.
Herald added projects: Kate, Frameworks.
ahmadsamir requested review of this revision.

REVISION SUMMARY
  - Do away with the kateregexp class; move isMultiLine() to kateregexpsearch
  - \s can match a newline
  - Dot '.' will match any character except a newline by default; it can be set to match a newline if QRegularExpression::DotMatchesEverythingOption is set, right now it can be set implicitly as a match directive, '(?s)', in the search pattern
  - Explicitly enable QRegularExpression::MultilineOption, more details about that are in KateRegExpSearch::search()
  - Update the relevant unit tests (searchbar_test, regexpsearch_test)

TEST PLAN
  All unit tests pass except for vimode_emulatedcommandbar
  
  Search away, test it for as long as possible before committing

REPOSITORY
  R39 KTextEditor

BRANCH
  ahmad/qregularexpression (branched from master)

REVISION DETAIL
  https://phabricator.kde.org/D23457

AFFECTED FILES
  autotests/src/regexpsearch_test.cpp
  autotests/src/regexpsearch_test.h
  src/CMakeLists.txt
  src/document/katedocument.cpp
  src/search/kateplaintextsearch.cpp
  src/search/kateregexp.cpp
  src/search/kateregexp.h
  src/search/kateregexpsearch.cpp
  src/search/kateregexpsearch.h
  src/search/katesearchbar.cpp
  src/search/katesearchbar.h
  src/utils/katesedcmd.cpp
  src/utils/katesedcmd.h

To: ahmadsamir, #ktexteditor, dhaumann, cullmann
Cc: kde-frameworks-devel, kwrite-devel, LeGast00n, GB_2, domson, michaelh, ngraham, bruns, demsking, cullmann, sars, dhaumann
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kwrite-devel/attachments/20190825/5d321ea5/attachment-0001.html>


More information about the KWrite-Devel mailing list