The Artima Developer Community
Sponsored Link

Java Answers Forum
Property Names in Swing

1 reply on 1 page. Most recent reply: Sep 4, 2003 11:56 PM by zenykx

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 1 reply on 1 page
Nicolae Cismaru

Posts: 1
Nickname: nicolae
Registered: Sep, 2003

Property Names in Swing Posted: Sep 2, 2003 3:41 AM
Reply to this message Reply
Advertisement
From what I see, a PropertyChangeEvent is fired whenever a property is changed in a Swing component. I assume that there is a convention that the property name from the event must be the same with that of the component field that is changed. If so, is this convention useful somewhere?

When the border is changed, by means of setBorder, then firePropertyChange("border", oldBorder, border) is called.

Can anybody tell me why the names of properties are not declared as string constants of the component class? For the border example it could be something like JComponent.BORDER_PROPERTY_NAME.

Thank you, Nicu


zenykx

Posts: 69
Nickname: zenykx
Registered: May, 2003

Re: Property Names in Swing Posted: Sep 4, 2003 11:56 PM
Reply to this message Reply
I don't really get your question. Try read the API :)

Flat View: This topic has 1 reply on 1 page
Topic: please i need  your help Previous Topic   Next Topic Topic: Reading Images from JTextPane

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use