Re: [gtk-list] [patch] bug corrections for transparent pixmap in gdkpixmap.c



Patrice Fortier wrote:
> 
> 
> The author suppose that the black color is the first in the colormap
> and that the white color is the last one.
> This is be true for linux in true-color (depth 15-32).
> If you're in pseudo-color (256 colors) the black color is the entry 0
> (right), and white the entry 1 (oops). Maybe X can handle this for a
> bitmap (1 plane).
> But he real problem is that on a SUN (or HP, I don't remember), these
> 2 entries are swapped: 0 is white, and black is 1. So your mask is
> inverted...
> I don't like gdk_color_white/black() either, but unfortunatly we'll have
> to stick to this solution until we find a better one :(.

The better solution should be to use the Xlib function/macro  for 
requesting the white or black:
 
 BlackPixel 
 BlackPixelOfScreen
 WhitePixel
 WhitePixelOfScreen


        GSI - Gesellschaft fuer Schwerionen Forschung
Kay Winkler           Planckstrasse 1          D-64291
Darmstadt             
K.Winkler@gsi.de   Tel: (49)6159/71-2551    Fax:(49)6159/71-2785



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]