Allow to use scrolling (Shift+Up/Down/PgUp/PgDown/Home/End) and a key
for showing URL hints when the view is in read-only mode.
Details
- Reviewers
hindenburg - Group Reviewers
Konsole - Commits
- R319:d6e7512b7552: Allow view-controlling keys in read-only mode
R319:b94162c11b3e: Allow view-controlling keys in read-only mode
R319:6635190c1295: Allow view-controlling keys in read-only mode
R319:2e086c852eac: Allow view-controlling keys in read-only mode
- Prepare
- Turn on scrollback
- Set at least one modifier key for "Show URL hints" (edit profile → advanced)
- Generate a few screens of text in Konsole
- Display some URL (e.g. echo 'www.kde.org')
- Display current time every second: while sleep 1; do printf '\r%s' "$(date)"; done
- Turn on read-only mode
- Patch tests
- Hold down URL hint key - the URL should be underlined with square and a digit on the left
- Press <URL-hint-key>+1 - the URL should open in a web browser
- Scroll the view with Shift+Up/Down/PgUp/PgDown/Home/End - the view should scroll
- Split the view, do previous test in each split - only currently active split should scroll
- Regressions tests
- Press different keys (including Ctrl+C, Ctrl+Z, etc; skip those mapped to Konsole actions) - nothing in terminal should happen
- Press Ctrl+S - the time should not stop updating
- Use IME to enter text - nothing in terminal should be shown
Diff Detail
- Repository
- R319 Konsole
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Check for valid session pointer before checking it for read-only state.
The case with null session happened when using iBus + Anthy, typing Japanese and accepting the text.
I partially reverted this in https://cgit.kde.org/konsole.git/commit/?h=Applications/18.04&id=7f2af0da1d3da1b232b57f5a98399601e53850b0
it was causing one test to fail and I don't want 18.04 to have any issues this late.
You should also revert TerminalDisplay.cpp part - with partial revert you can input text in read-only mode.
BTW. Can this be reopened for further investigation (possibly after release), or new review request will be better?
you can patch against master - I just won't backport to 18.04 until we're sure there are no issues.
thanks - passes the ASAN on my box - I'll double-check and commit to master - if no issues, I'll commit to 18.04 before the release.
Same test still fails on isReadOnly = currentView->sessionController()->isReadOnly();
note that is only seen when using ASAN - I'll look at it later
https://build.kde.org/job/Applications%20konsole%20kf5-qt5%20FreeBSDQt5.9/166/testReport/junit/(root)/TestSuite/TerminalInterfaceTest/
https://build.kde.org/job/Applications%20konsole%20kf5-qt5%20SUSEQt5.9/173/testReport/junit/(root)/TestSuite/TerminalInterfaceTest/
I won't commit to 18.04 until this is resolved.
I committed two changes so the test doesn't crash - it still fails but thats another issue
I've made one more change, in separate review as this one is already on master: https://phabricator.kde.org/D11762