[Mono-winforms-list] Concerns about system colors?

Maser, Dan Dan.Maser at inin.com
Fri Apr 20 16:27:20 EDT 2007


 
 I wonder if I should raise concerns about the System colors in mono?
What I'm seeing is a little strange.  My app code uses System colors
for everything and looks as expected in Win32 but on linux mono it
doesn't look natural.  But it's not as clear what it *should* look
like either.  

 The colors for most apps are set in the /usr/lib/X11/app-defaults
directory per application I suppose.  So for example I see gnome
terminal windows that are black-on-white and highlight text
white-on-black.  I have standard xterms that are black-on-grey and
highlight white-on-black. Both of these seem normal because the two
colors have a high contrast.  However, my mono app has black-on-grey
(which is ok) but highlights white-on-gray.  The white-on-grey
highlight looks pretty bad for two reasons: the white-on-grey isn't a
high enough contrast plus the highlight background and non-highlight
background are both grey which doesn't clearly indicate what's
highlighted.
 
 Sorry for the long-winded explanation.  I guess what I'm wondering
foremost is if there's an some /usr/lib/X11/app-defaults resources
file I can specify that will set the system colors I like?  If not,
can someone explain where the system colors come from?
 
 In case it helps my app draws its window as 
  not highlighted: SystemColors.WindowText on SystemColors.Window 
  highlighted:     SystemColors.HighlightText on SystemColors.Highlight
 

 I see that there's some colors hard coded into
mcs/class/System.Drawing/System.Drawing/KnownColors.cs.  The relevant
colors for my case are:
 
Window        FF FF FF   (this is black-on-white)
WindowText    00 00 00
 
Highlight     31 6A C5   (this is white-on-bluish)
HighlightText FF FF FF
 
   Which seems reasonable to me. However it seems as though my current
"active theme" is apparently overriding these.  It's not obvious to me
where I need to change things.  And most importantly I don't see any
other apps looking strange... And this theme is the default them for the
REHL OS and I haven't updated it.

  
   Thanks in advance for any ideas!
     Dan Maser
 



More information about the Mono-winforms-list mailing list