aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/desktop-utils/lumina-textedit
diff options
context:
space:
mode:
authorKen Moore <moorekou@gmail.com>2016-05-02 12:36:10 -0400
committerKen Moore <moorekou@gmail.com>2016-05-02 12:36:10 -0400
commit9c95b9bd854e953e75ac34f2fbcd28e0e7fd0160 (patch)
tree9ac3f6c37057c9a5af00e0b8d9c9698bbc1e2356 /src-qt5/desktop-utils/lumina-textedit
parentFix a geometry calculation for panel placements on X monitors which are not a... (diff)
downloadlumina-9c95b9bd854e953e75ac34f2fbcd28e0e7fd0160.tar.gz
lumina-9c95b9bd854e953e75ac34f2fbcd28e0e7fd0160.tar.bz2
lumina-9c95b9bd854e953e75ac34f2fbcd28e0e7fd0160.zip
Adjust the single-replace logic in lumina-textedit. Have it replace the current selection match, and find the next one (don't replace the next one until the user can see it highlighted first).
Diffstat (limited to 'src-qt5/desktop-utils/lumina-textedit')
-rw-r--r--src-qt5/desktop-utils/lumina-textedit/MainUI.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp
index 7425b399..b5d65559 100644
--- a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp
+++ b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp
@@ -300,16 +300,16 @@ void MainUI::replaceOne(){
bool done = false;
if(cur->textCursor().selectedText()==ui->line_find->text()){
cur->insertPlainText(ui->line_replace->text());
- done = true;
- }else{
+ //done = true;
+ }//else{
//Find/replace the next occurance of the string
bool found = cur->find( ui->line_find->text(), ui->tool_find_casesensitive->isChecked() ? QTextDocument::FindCaseSensitively : QTextDocument::FindFlags() );
- if(found){ cur->insertPlainText(ui->line_replace->text()); done = true;}
- }
- if(done){
+ //if(found){ cur->insertPlainText(ui->line_replace->text()); done = true;}
+ //}
+ /*if(done){
//Re-highlight the newly-inserted text
cur->find( ui->line_replace->text(), QTextDocument::FindCaseSensitively | QTextDocument::FindBackward);
- }
+ }*/
}
void MainUI::replaceAll(){
bgstack15