Re: [Swingwt-developers] customized TableCellRenderer does not call paint() method
Status: Beta
Brought to you by:
bobintetley
From: Robin Rawson-T. <ro...@ra...> - 2004-11-17 20:49:19
|
Wu, Lei wrote: > thank you. this works but the BufferedImage is presented as a black > block unless selected. > there are also cases we need both icon and custom painting, it would > be nice if you add paint support to swingwt api. The reason it's black is that GC/Graphics default to black as the background colour. With the Graphics object in your paint method, call setBackground(color) ) and fillRectangle() on it before your code. Use the SystemColor class if you want to grab a colour available from the current widget theme for your desktop instead of hard coding one. I'll look at adding the paint call in. Cheers, Rob -- ===================================================== Robin Rawson-Tetley (ro...@ra...) Jabber: bob...@ja... Yahoo: bobintetley MSN: bobintetley Home: http://www.rawsontetley.org Animal Shelter Manager (http://sheltermanager.sourceforge.net) SwingWT (http://swingwt.sourceforge.net) I prefer encrypted email. Download my public key from http://www.rawsontetley.org/rrtpk.asc |