Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / June 2007

Tip: Looking for answers? Try searching our database.

Synth, can't use different styles in check boxes

Thread view: 
Kgbol - 14 Jun 2007 14:02 GMT
Hi , when i tried to create  2 different styles of check boxes in xml
file the program had an exception, and used default look and feal. I
put this styles like that:

<style id="cB1">
<imageIcon id="check_off" path="images/dziel.png"/>
<imageIcon id="check_on" path="images/dzielZaznaczony.png"/>
<property key="CheckBox.icon" value="check_off"/>
<state value="SELECTED">
<property key="CheckBox.icon" value="check_on"/>
</state>
</style>
<bind style="cB1" type="name" key="box1"/>

<style id="cB2">
<imageIcon id="check_off" path="images/razy.png"/>
<imageIcon id="check_on" path="images/razyZaznaczony.png"/>
<property key="CheckBox.icon" value="check_off"/>
<state value="SELECTED">
<property key="CheckBox.icon" value="check_on"/>
</state>
</style>
<bind style="cB2" type="name" key="box2"/>

when i comment one of those styles the program uses Synth look & feel.
My question is, why does it happen? And can i do somenthing about it.
Kgbol - 14 Jun 2007 14:28 GMT
OK i solve it myself, i had the same ImageIcon id's for both check
boxes. They should to have different names.

............
<imageIcon id="check_off" path="images/dziel.png"/>
<imageIcon id="check_on" path="images/dzielZaznaczony.png"/>
............
<imageIcon id="check_off2" path="images/razy.png"/>
<imageIcon id="check_on2" path="images/razyZaznaczony.png"/>


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.