This isn't standardized, but matches what VTE does.
printf '\e[0 q' # reset to default
Ref. https://bugzilla.gnome.org/show_bug.cgi?id=720821 and
https://bug720821.bugzilla-attachments.gnome.org/attachment.cgi?id=291238
hindenburg |
Konsole |
This isn't standardized, but matches what VTE does.
printf '\e[0 q' # reset to default
Ref. https://bugzilla.gnome.org/show_bug.cgi?id=720821 and
https://bug720821.bugzilla-attachments.gnome.org/attachment.cgi?id=291238
Automatic diff as part of commit; lint not applicable. |
Automatic diff as part of commit; unit tests not applicable. |
Hello.
IIRC, I researched that issue when I submitted the DECSCUSR diff; and the current behaviour matches the VT510[1], VT520[2] documentation and the XTerm implementation.
And I went with the logic that matching the VT docs and XTerm behaviour is a safer way of implementing this, as the main consumers of such features are terminal apps like vim, which, AFAICS, tend to implement those features based on XTerm (as the de-facto terminal emulator out there).
So, in my mind anyway, this makes things easier for those apps, as they wouldn't have to add special workarounds/quirks for Konsole.
[1] https://www.vt100.net/docs/vt510-rm/DECSCUSR.html
[2] https://www.vt100.net/docs/vt520-rm/
Yeah, the current way is fine, but I started using it in my own application, and I missed a way to just reset to the original state.
And ref. the linked discussion in the gnome bugtracker for gnome terminal/vte, the doc is a bit ambigous, so they chose to interpret it in a way that also enables applications to easily reset the cursor style.
And ref. compatibility; this patch makes konsole more compatible with gnome terminal (and the other terminals using vte).
You have a point there; with the way it's implemented now there's no way to reset the cursor style except executing reset, which would most likely be too much.