[Konsole-devel] Support for dim color support, i.e., \e[2m [includes patch]

Antonio Russo antonio.e.russo at gmail.com
Fri Apr 22 03:29:07 UTC 2016


The escape code \e[2m should allow for "dimmed" text to be displayed. This is supported in, e.g., xterm and the standard Linux console. The
attached patches implement the infrastructure for color schemes to support dimmed colors [dim-color-support], prevents regressions with the
shipped themes [colorscheme-compat], and provides a full theme for the Linux color scheme [linux-colorscheme].

I.e., this should now work (by which I mean, show as different intensities in the linux color scheme):
echo -e 'A\e[2mA'

The other color schemes are essentially unaffected by this patch---someone with some aesthetic sense ought to check the colors out.

I noticed two other things while adding this feature:

In src/Vt102Emulation.cpp , the support for removing "intense" or "bold" (i.e., \e[21m) was not properly implemented. This patch should also
address this problem. I would appreciate comments verifying my (very limited) understanding of vt102 emulation.

This can be seen by checking:
echo -e 'A\e[1mA\e[21mA'

Additionally, the comments in src/Screen.cpp seem to be misleading or wrong, and the "RE_INTENSIVE" constant appear vestigial from some earlier
implementation of bold/intensive. I started making changes there, but it seems like it might be better off without any comment there, or better
still rewriting it entirely.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-colorscheme-compat.diff.gz
Type: application/gzip
Size: 1875 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/konsole-devel/attachments/20160421/d4b50f52/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-dim-color-support.diff.gz
Type: application/gzip
Size: 3796 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/konsole-devel/attachments/20160421/d4b50f52/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-linux-colorscheme.diff.gz
Type: application/gzip
Size: 538 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/konsole-devel/attachments/20160421/d4b50f52/attachment-0002.bin>


More information about the konsole-devel mailing list