Changing image background colour on canvas? 
Author Message
 Changing image background colour on canvas?
I'm playing with the canvas widget at the moment...

...I have a canvas on which I have drawn a rectangle (to which I have
given the tag "imagebackground"). Inside the rectangle I have created
an "image". The image has a transparent background, so the image
background matches the rectangle background. So far so good...

...However I would like to be able to change the colour of the
rectangle so that the colour of the image background changes. If I
use...

.mycanvas itemconfigure imagebackground -fill red

...The colour of the rectangle changes to red, but the image is wiped
out.

How can I change the colour of rectangle such that the image in it is
preserved?

Many Thanks,
   =Adrian=



Tue, 09 May 2006 00:12:07 GMT  
 Changing image background colour on canvas?

| .mycanvas itemconfigure imagebackground -fill red
|
| ...The colour of the rectangle changes to red, but the image is
| wiped out.

Does
    pathName raise tagOrId ?aboveThis?
       Move all of the items given by tagOrId to a new position
       in the display list just after the item given by aboveThis.
help here (i.e. `raise' the image)?

R'



Tue, 09 May 2006 00:37:25 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Setting image background colour in text widget?

2. can't make image and background colour match

3. VW2 Changing Background Colour

4. changing background colour of an rc_graphic window

5. Changing background colour of BLT hiertable

6. How to change Pythonwin background colour?

7. Printing colour images on a colour printer

8. Displaying an image in the background of a canvas

9. Background image/bitmap on Canvas

10. How can i change background color afte setting in canvas command

11. in canvas text item can background color be changed

 

 
Powered by phpBB® Forum Software