For Programmers: Free Programming Magazines  


Home > Archive > Java Help > April 2005 > JTable - Left align icon in cell









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author JTable - Left align icon in cell
farseer

2005-04-23, 8:57 pm

Hi,
i'm not well versed in swing as yet and have a question related to
custome cell renderers.
I have a custom cell renerer that adds and icon to in cell based on a
condition. If the condition is met, the cell would contain both text
and the icon. My question is, is there a way to have the icon appear
left justified, while the text remains centered in cell?

My guess is i my might have to create a panel or something, but i was
hoping it was possible with a label or other lightweight
components..(is JPanel light weight)?

thanks much...

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com