[MPlayer-dev-eng] [PATCH] color console for win32

Zuxy Meng zuxy.meng at gmail.com
Sun Dec 16 15:17:21 CET 2007


Hi,

2007/12/16, Gianluigi Tiesi <mplayer at netfarm.it>:
> Hi all,
>
> I've made a patch to make color console work on win32
> win32 console does not supports ansi escape strings
> (ansi.sys needs to be loaded by it's 16bit stuff)
>
> on win32 it works in a slightly different way
> all colors are brightened because non bright colors
> suck a bit on the win32 console
>
> to achieve the same behaviour of unix
> I've added in comment two different guards
> for if
>
> STATUSLINE text was changed to STATUS since it's 10 chars
> while the format of the string uses %9s
>
> The code is tested on xp sp2 and win98
>
> I've added a check using istty() if the stream is not
> attached to a terminal it skips the color code
> (plus adding the "SECTION")
> this may be usefull also on unix
>
> Regards

Hmm I submitted a similar patch some days earlier but never applied.
Of course yours look much finer :-)

-- 
Zuxy
Beauty is truth,
While truth is beauty.
PGP KeyID: E8555ED6



More information about the MPlayer-dev-eng mailing list