New issue 105 by eleith: extend vt100.js to support xterm 256 colors
http://code.google.com/p/shellinabox/issues/detail?id=105
i really like my vim/screen/mutt/finch colors as defined by my server conf
files.
since vt100 emulators can support 256 colors by interpreting additional
escape codes sent by the server, i went ahead and implemented this on my
local copy of shellinabox.
the only changes i made were in vt100.js and some of the included css files.
with these updates, i can run screen/vim/mutt with full 256 color support
as per the color themes on the server. the css files i changed merely
provide the base 16 system colors as well as a default
background/front-color.
perhaps others would like this feature as well?
and btw, this is a great project, thanks for your work. i learned a lot
about terminal emulators going through your code...
Attachments:
vt100.js 150 KB
white-on-black.css 352 bytes
color.css 1.9 KB
i made the same changes in color.css to styles.css as well. basically i
just matched the 16 system colors to that of Terminal.app as found here:
http://en.wikipedia.org/wiki/Ansi_escape_codes#Colors
Attachments:
styles.css 4.9 KB
attaching newer vt100.js and styles.css, adding my changes into the version
in trunk, rather from the tar.gz versions which are outdated compared to
trunk.
Attachments:
vt100.js 171 KB
styles.css 7.3 KB
I have the vt100 & style.css a test today. They work great.
Thanks!
I have tested the vt100.js/styless.css today. They work great.
Thanks!
These patches are great. There still a few things that need to be improved,
though.
* The bgAnsi* classes in your color.css are setting 'color' when they
should be setting 'background-color'.
* An off-by-one error in two places in vt100.js is preventing ansi0 and
bgAnsi0 from being used at all.
* A logic error in vt100.js is causing it to incorrectly set the foreground
color to ansi7 for text which has the default color + bright attribute.
* When setting text to bold, you used "text-weight:bold;". It should
be "font-weight:bold;"
I have fixed all of the above, and attached the updated files.
Attachments:
color.css 1.4 KB
vt100.js 171 KB
Please provide a patch file instead of individual files.