The previous behavior was actually the intended one, the URL hints are
intended to strictly increase from start to finish (physically on the
keyboard).
It might not be "technically" correct, but that's the original behavior
before the refactor (and I think it makes the most sense, that's why I
implemented it that way originally).
Also fixes activating the first URL, activating 0 didn't work.
This reverts commit 28e1a3e634.
BUG: 427293
Good explanation from Tomaz (he's better with words than me):
I think he wants to quick swap the text from primary and secondary screens:
ls folder
vim somefile.txt
- mmm, what's the name of the file I need, I just did the LS for that reason -
peek into primary screen, note the file name, go back to secondary screen
Merge request:
https://invent.kde.org/utilities/konsole/-/merge_requests/210
Traditionally konsole only was able to parse OSC sequences terminated with
non-standard BEL. In 324d78c07f konsole was extended to parse sequences
terminated by 7-bit ST (ESC \) as well. But the OSC responses were still
hardcoded to reply only with sequences with BEL. But replying to 7-bit ST
terminated sequences with a reply terminated by a non-standard terminator
is wrong.
This commit passes the terminator along and changes the response to match
the original request.
printf "\033]10;?\a" replies with "^[]10;rgb:fcfc/fcfc/fcfc^G"
printf "\033]10;?\033\\" replies with "^[]10;rgb:fcfc/fcfc/fcfc^[\"
Then if one of the classes that inherit HotSpot need to reimplement an
input event, it can do so. I think this way we get less code duplication,
and if we need to change those methods, there is a chance only changing the
base implementation is necessary.
This also fixes file filter.
Initialise member variables in FilterChain ctor, particularly initialising
_showUrlHint prevents an issue where url hints are displayed when moving
the mouse for the first time in a newly opened konsole window even if no
url hint modifiers are pressed.
In keyPressEvent it seems calling update() on the TerminalDisplay isn't
needed.
Code is way simpler now, a lot of duplicated code is removed
from TerminalDisplay, and the behavior is split into the
hotSpot classes instead of having TerminalDisplay be a god class
that knows how to handle everything.
This also simplifies creation of new filters
FilterChain contains all the hotspots, it's the best place
to calculate the collective region. This removes code from
the TerminalDisplay, and that's much needed.
This was harder than I tought. Because of the static initialization
static linkage order, we ended up having two different values of
a static variable on the code, that where supposedly only one.
https://stackoverflow.com/questions/26547454/static-variable-is-initialized-twice
The choosen change: Use OBJECT instead of STATIC for linking also
made me fix a few other profile headers to use the correct folder.