[wxPython-users] Text on a bitmap or throbber

Patrick Van Pelt patrick at laika.com
Fri Nov 16 09:48:40 PST 2007


I'm still new-ish to python, but I've been doing something that may help.

I'm doing some custom label-drawing in an app I'm developing.  What I've been doing is drawing the bitmap icon and a few optional overlays into a memoryDC, then using the DrawText function to apply my own custom labels.  The text is simply overlayed so the background is transparent.  I'm not sure about constraining the size to the throbber, but you can probably write something that checks the available area, then scales the drawing rectangle (and font size if necessary).

----- Original Message -----
From: "Craig Douglas" <craig.douglas at rtkinstruments.com>
To: wxpython-users at lists.wxwidgets.org
Sent: Friday, November 16, 2007 8:28:40 AM (GMT-0800) America/Tijuana
Subject: [wxPython-users]  Text on a bitmap or throbber

Ok, not sure if there is a simple solution to this, but I have a throbber 
which I want to put some user defined text onto.  My problem is that I need 
the text to wrap and not go out of the size of the throbber, so I can't use 
the built in label in throbber.

StaticText seems to take it's background colour from the background colour of 
parent windows, which makes a mess of my throbber.  I'm needing just text over 
my throbber with a trnsparent background which wraps and centers and the size 
can be constrained.  Basically a StaticText with transparent backgrounds.

Searches haven't brought up much but i'm sure this is a relatively common 
problem/requirement?


---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe at lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help at lists.wxwidgets.org



_____________________________________________________________________
The information contained in this message and its attachments is
confidential and proprietary to LAIKA, Inc.  By opening this email
or any of its attachments, you agree to keep all such information
confidential and not to use, distribute, disclose or copy any part
of such information without the prior written consent of LAIKA,
Inc.  If you are not the intended recipient of this message, any use,
distribution, disclosure or copying of such information is prohibited.
If received in error, please contact the sender. 





More information about the wxpython-users mailing list