Creating bitmap variants
Hi again. I’ve got a bitmap with a transparent background and am
trying to create variants of it to use under different conditions; for
example, the bitmap but with a border or a little glyph in the corner.
This is what I’m doing to create the new bitmap:
mem = wxMemoryDC();
mem.SelectObject(self.__pixOn);
mem.SetPen(wxLIGHT_GREY_PEN);
mem.SetBrush(wxWHITE_BRUSH);
mem.SetBackground(wxWHITE_BRUSH);
mem.SetLogicalFunction(wxSET);
mem.DrawLines((wxPoint(1, 1), wxPoint(w-2, 1), wxPoint(w-2, h-2),
wxPoint(1, h-2), wxPoint(1, 1)));
mem.SelectObject(wxNullBitmap);
However, it seems tha the transparency mask in self.__pixOn is
getting in the way because the lines I draw are masked by the non-transparent
parts of the bitmap.
What I’d like is to have my drawing overlay (or underlay) the bitmap image.
Anyone done this before?
···
Jeff Kotula Systems Architecture Manager
Vital Images jkotula@vitalimages.com
Renunciation is not giving up the things of this world,
but accepting that they go away.
-- Suzuki Roshi