• Post Reply Bookmark Topic Watch Topic
  • New Topic

how can i add same label repetedly for the frame  RSS feed

 
damodar kumar
Ranch Hand
Posts: 77
Android Chrome MyEclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,



how can i add same label repetedly for the frame





please suggest

Thanks

Dam.
 
Maneesh Godbole
Bartender
Posts: 11445
18
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by damodar kumar:

how can i add same label repetedly for the frame


You cannot add the same label repeatedly.
You can take the following approach.
Subclass JLabel to create your own CustomLabel.
Set all the background,foreground,opaque properties in the CustomLabel so that they are the attributes for all instances of CustomLabel.
Then on the UI, you create as many instances of CustomLabel and add them to the UI.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!