ASHISH031192 / mintty

Automatically exported from code.google.com/p/mintty
0 stars 0 forks source link

GUI options for changing ANSI colours #193

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
It would be great if there were options to change the colors that are actually 
displayed when showing ANSI color.  This is the same feature that is in PuTTY 
under Window -> Colours.

An example use for this is that by default vim and other programs render bash 
comments in blue, and the default blue (0,0,127) is almost impossible to read 
on a black background.  I would like to be able to change the color of this 
blue or make it brighter by adjusting the RGB values that are displayed.

Original issue reported on code.google.com by brian.ma...@gmail.com on 30 Jun 2010 at 4:02

GoogleCodeExporter commented 8 years ago
Please see the manual for escape sequences that allow you to change the colours.

Original comment by andy.koppe on 30 Jun 2010 at 7:36

GoogleCodeExporter commented 8 years ago
Then consider this a request to add that feature into the main configuration 
dialog, as configuring this by escape sequences is extremely arcane.  There are 
other color options in the config dialog, and it only makes sense to have the 
rest in there as well.

Original comment by brian.ma...@gmail.com on 30 Jun 2010 at 7:48

GoogleCodeExporter commented 8 years ago
Lots of people want to change the text, background and cursor colours, hence 
the config dialog buttons. Fiddling with the ANSI colours, meanwhile, is more 
of a minority pursuit, hence the escape sequence support only. Those sure 
aren't intuitive, but they do have some advantages over GUI options: they work 
across different xterm-compatible terminals, and they can be used in scripts, 
allowing application-specific colour settings. Having said all that, something 
like gnome-terminal's GUI for setting those colours would be nice to have.

As for the vim problem at hand, I think changing ANSI Blue is the wrong fix for 
that. Vim shouldn't be using dark blue on black in the first place, and it's 
easy to stop it from doing so, by sticking this into .vimrc:

hi comment ctermfg=blue

Or perhaps:

hi comment ctermfg=darkcyan

Original comment by andy.koppe on 2 Jul 2010 at 6:40

GoogleCodeExporter commented 8 years ago

Original comment by andy.koppe on 2 Jul 2010 at 6:41

GoogleCodeExporter commented 8 years ago
Added config file options for the ANSI colours in r973 on trunk.

Original comment by andy.koppe on 15 Aug 2010 at 3:55

GoogleCodeExporter commented 8 years ago
Vim actually has a setting for telling it whether a terminal with a light or 
dark background is used:

:set background=dark

This makes it use lighter colours appropriate for a dark background. (Thanks to 
Andrew Aylett for this tip.)

Original comment by andy.koppe on 18 Aug 2010 at 6:21

GoogleCodeExporter commented 8 years ago
Mintty 0.9 introduced the ability to set the ANSI colours in the .minttyrc 
file, e.g.:

Blue=0,0,255

They can also be specified on the command line using the -o option. (-o 
Blue=0,0,255). See the configuration section of the manual for all the colour 
names.

Original comment by andy.koppe on 30 Oct 2010 at 5:25

GoogleCodeExporter commented 8 years ago
The .minttyrc file is only for the local terminal. When I ssh into another 
server, the color blue is too dark. In PuTTY, whatever color I set is also the 
color I see on an ssh session.

Original comment by slack...@gmail.com on 14 Jan 2011 at 3:18

GoogleCodeExporter commented 8 years ago
Config file settings are not specific to local sessions. In fact mintty has no 
concept of local and remote sessions. If the problem persists, please enter a 
separate issue with relevant details.

Original comment by andy.koppe on 14 Jan 2011 at 6:56

GoogleCodeExporter commented 8 years ago
I tried this and it works. Just add these to your .bashrc

# make colors fancy on 256 console # http://www.frexx.de/xterm-256-notes/
# http://web.njit.edu/~kevin/rgb.txt.html || use with xterm-256color
# 
http://chadaustin.me/2009/10/reasons-why-mintty-is-the-best-terminal-on-windows/

echo -ne "\e]4;0;#030303\a"  # 4;0 is Dark Black
echo -ne "\e]4;1;#FF0000\a"  # 4;1 is Dark Red #CD3333|#C81E1E
echo -ne "\e]4;2;#005F00\a"  # 4;2 is Dark Green
echo -ne "\e]4;3;#E2C400\a"  # 4;3 is Dark Yellow
echo -ne "\e]4;4;#007fff\a"  # 4;4 is Dark Blue #005FFF
echo -ne "\e]4;5;#FF005F\a"  # 4;5 is Dark Magenta #963C59
echo -ne "\e]4;6;#00AF87\a"  # 4;6 is Dark Cyan #99CC32|#009696
echo -ne "\e]4;7;#707070\a"  # 4;7 is Dark White aka Grey
echo -ne "\e]4;8;#3B3B3B\a"  # 4;8 is Light Black
echo -ne "\e]4;9;#FF6347\a"  # 4;9 is Light Red #FF4040|#E40021
echo -ne "\e]4;10;#99CC32\a" # 4;10 is Light Green #C0FF3E|#7FFF00|#55D763
echo -ne "\e]4;11;#FFD700\a" # 4;11 is Light Yellow #FFD800|#FFF796
echo -ne "\e]4;12;#87CEEB\a" # 4;12 is Light Blue #1E90FF|#007FFF|#4186BE
echo -ne "\e]4;13;#FF6EB4\a" # 4;13 is Light Magenta #FF6EB4|#CF9EBE|#D75F87
echo -ne "\e]4;14;#00D7D7\a" # 4;14 is Light Cyan #96CDCD
echo -ne "\e]4;15;#EEEEEE\a" # 4;15 is Light White

Original comment by white.he...@gmail.com on 24 May 2012 at 4:46

GoogleCodeExporter commented 8 years ago
While the information posted in comment #10 is useful, it is irrelevant for 
this ticket.  The purpose of a ticket or feature request is not to get 
information about a workaround to make something do what you want, the purpose 
is to request improvements so the workaround is not needed in the first place.

Original comment by brian.ma...@gmail.com on 24 May 2012 at 7:18

GoogleCodeExporter commented 8 years ago
I wanted this and I see some others do too so here is a patch for people to use 
as they wish.

I've also attached an image for illustrative purposes.

Original comment by james.da...@gmail.com on 26 Apr 2014 at 11:54

Attachments:

GoogleCodeExporter commented 8 years ago
See https://github.com/mintty/mintty/issues for further progress on this issue.

Original comment by towom...@googlemail.com on 7 Aug 2015 at 1:26