~michael-sheldon/ubuntu-keyboard/fix-1407584

« back to all changes in this revision

Viewing changes to src/view/abstracttexteditor.cpp

  • Committer: CI Train Bot
  • Author(s): Michael Sheldon
  • Date: 2014-12-09 15:37:31 UTC
  • mfrom: (256.1.3 fix-1398503)
  • Revision ID: ci-train-bot@canonical.com-20141209153731-n738gq4dayayukeb
Disables automatic insertion of space characters after punctuation except when punctuation has been added by double space. Fixes: #1398503
Approved by: PS Jenkins bot

Show diffs side-by-side

added added

removed removed

Lines of Context:
465
465
                // this means we should commit the candidate, add the separator and whitespace
466
466
                d->text->setPreedit(d->text->primaryCandidate());
467
467
                d->text->appendToPreedit(text);
468
 
                if (d->keyboardState == "CHARACTERS" && !email_detected) {
469
 
                    d->appendix_for_previous_preedit = d->word_engine->languageFeature()->appendixForReplacedPreedit(d->text->preedit());
470
 
                    d->text->appendToPreedit(d->appendix_for_previous_preedit);
471
 
                }
472
468
                commitPreedit();
473
469
                if (!email_detected) {
474
470
                    auto_caps_activated = d->word_engine->languageFeature()->activateAutoCaps(d->text->surroundingLeft() + d->text->preedit() + text);
484
480
                d->text->appendToPreedit(text);
485
481
                if (!email_detected) {
486
482
                    auto_caps_activated = d->word_engine->languageFeature()->activateAutoCaps(d->text->surroundingLeft() + d->text->preedit());
487
 
                    if(isSeparator && d->keyboardState == "CHARACTERS") {
488
 
                        d->text->appendToPreedit(d->word_engine->languageFeature()->appendixForReplacedPreedit(d->text->preedit()));
489
 
                    }
490
483
                }
491
484
                commitPreedit();
492
485
                alreadyAppended = true;