Commit 341e84dc authored by Kurt Hindenburg's avatar Kurt Hindenburg

use \033 instead of \e (pedantic)

parent f83854fe
...@@ -2869,8 +2869,8 @@ void TerminalDisplay::doPaste(QString text, bool appendReturn) ...@@ -2869,8 +2869,8 @@ void TerminalDisplay::doPaste(QString text, bool appendReturn)
if (!text.isEmpty()) { if (!text.isEmpty()) {
text.replace('\n', '\r'); text.replace('\n', '\r');
if (bracketedPasteMode()) { if (bracketedPasteMode()) {
text.prepend("\e[200~"); text.prepend("\033[200~");
text.append("\e[201~"); text.append("\033[201~");
} }
// perform paste by simulating keypress events // perform paste by simulating keypress events
QKeyEvent e(QEvent::KeyPress, 0, Qt::NoModifier, text); QKeyEvent e(QEvent::KeyPress, 0, Qt::NoModifier, text);
......
...@@ -67,19 +67,19 @@ void KeyboardTranslatorTest::testEntryTextWildcards_data() ...@@ -67,19 +67,19 @@ void KeyboardTranslatorTest::testEntryTextWildcards_data()
// text, results: no mod, shift, alt, control // text, results: no mod, shift, alt, control
entry.clear();; entry.clear();;
entry << QByteArray("\E[24;*~") << QByteArray("\E[24;1~") << QByteArray("\E[24;2~") << QByteArray("\E[24;3~") << QByteArray("\E[24;5~"); entry << QByteArray("\033[24;*~") << QByteArray("\033[24;1~") << QByteArray("\033[24;2~") << QByteArray("\033[24;3~") << QByteArray("\033[24;5~");
QTest::newRow("\E[24;*~ yes wildcards no modifiers")<< entry[0] << entry[1] << true << Qt::KeyboardModifiers(Qt::NoModifier); QTest::newRow("\033[24;*~ yes wildcards no modifiers")<< entry[0] << entry[1] << true << Qt::KeyboardModifiers(Qt::NoModifier);
QTest::newRow("\E[24;*~ yes wildcards Shift modifiers")<< entry[0] << entry[2] << true << Qt::KeyboardModifiers(Qt::ShiftModifier); QTest::newRow("\033[24;*~ yes wildcards Shift modifiers")<< entry[0] << entry[2] << true << Qt::KeyboardModifiers(Qt::ShiftModifier);
QTest::newRow("\E[24;*~ yes wildcards Alt modifiers")<< entry[0] << entry[3] << true << Qt::KeyboardModifiers(Qt::AltModifier); QTest::newRow("\033[24;*~ yes wildcards Alt modifiers")<< entry[0] << entry[3] << true << Qt::KeyboardModifiers(Qt::AltModifier);
QTest::newRow("\E[24;*~ yes wildcards Control modifiers")<< entry[0] << entry[4] << true << Qt::KeyboardModifiers(Qt::ControlModifier); QTest::newRow("\033[24;*~ yes wildcards Control modifiers")<< entry[0] << entry[4] << true << Qt::KeyboardModifiers(Qt::ControlModifier);
// combinations // combinations
entry.clear();; entry.clear();;
entry << QByteArray("\E[24;*~") << QByteArray("\E[24;4~") << QByteArray("\E[24;6~") << QByteArray("\E[24;8~") << QByteArray("\E[24;7~"); entry << QByteArray("\033[24;*~") << QByteArray("\033[24;4~") << QByteArray("\033[24;6~") << QByteArray("\033[24;8~") << QByteArray("\033[24;7~");
QTest::newRow("\E[24;*~ yes wildcards Shift+Alt modifiers")<< entry[0] << entry[1] << true << Qt::KeyboardModifiers(Qt::ShiftModifier | Qt::AltModifier); QTest::newRow("\033[24;*~ yes wildcards Shift+Alt modifiers")<< entry[0] << entry[1] << true << Qt::KeyboardModifiers(Qt::ShiftModifier | Qt::AltModifier);
QTest::newRow("\E[24;*~ yes wildcards Shift+Control modifiers")<< entry[0] << entry[2] << true << Qt::KeyboardModifiers(Qt::ShiftModifier | Qt::ControlModifier); QTest::newRow("\033[24;*~ yes wildcards Shift+Control modifiers")<< entry[0] << entry[2] << true << Qt::KeyboardModifiers(Qt::ShiftModifier | Qt::ControlModifier);
QTest::newRow("\E[24;*~ yes wildcards Shift+Alt+Control modifiers")<< entry[0] << entry[3] << true << Qt::KeyboardModifiers(Qt::ShiftModifier | Qt::AltModifier | Qt::ControlModifier); QTest::newRow("\033[24;*~ yes wildcards Shift+Alt+Control modifiers")<< entry[0] << entry[3] << true << Qt::KeyboardModifiers(Qt::ShiftModifier | Qt::AltModifier | Qt::ControlModifier);
QTest::newRow("\E[24;*~ yes wildcards Alt+Control modifiers")<< entry[0] << entry[4] << true << Qt::KeyboardModifiers(Qt::AltModifier | Qt::ControlModifier); QTest::newRow("\033[24;*~ yes wildcards Alt+Control modifiers")<< entry[0] << entry[4] << true << Qt::KeyboardModifiers(Qt::AltModifier | Qt::ControlModifier);
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment