Article View: borland.public.jbuilder.java.swing
Article #11330Re: inspector bites icon
From: Greg Hamer
Date: Thu, 10 Jun 1999 00:00
Date: Thu, 10 Jun 1999 00:00
108 lines
6006 bytes
6006 bytes
Hmm. I tried it with JBuilder 2.01 (Help | About shows build #174) and it worked. Bill Winspur wrote: > Greg, > my ZoomIcon class source is attached. Thanks for your attention to the problem. > Bill. > > Greg Hamer wrote: > > > The elements in an inspectors drop-down list are not instantiated until needed. No > > point in making the designer slower than it already is. Whether it is a bug in > > JBuilder or something in your ZoomIcon class reamins to be seen; it is certainly a > > JBuilder bug that you can't determine what the problem is. The simplest > > explanation for the behaviour you describe would be if the ZoomIcon class was not > > public, or its constructor was not public. Can't think of any other explanations, > > but if you could send me the class, I would be happy to figure out what is going > > wrong. > > > > Bill Winspur wrote: > > > > > Thanks Greg, > > > I assigned the logging to to stderr. Unfortunately, the inspector's process of > > > ignoring assignment of a property from a property editor's drop down did not > > > produce any errors. > > > > > > However, I have since verified that my Icon works when assigned to the > > > JButton.icon property, by creating the button using 'Jbutton(Icon)' > > > constructor. I just added the icon argument to the constuctor invocation > > > generated by the IDE to do this. Interesting results from this experiment are: > > > > > > 1. inspector does not display the assignment of the icon to the button > > > 2. the icon is not drawn at design time > > > 3. the button IS drawn properly with its Icon at run time. > > > > > > So, I now have a work around for the problem of not being able to assign the > > > icons in the inspector, but it is ugly. WYS is not WYG and I now dont trust the > > > IDE to know when a property assginment is invalid. I've had this problem > > > before, and found a similar work around. I would still like to know if the > > > problem of not being able to assign a selection from a property editor's drop > > > down list is: > > > > > > a) a bug in the IDE > > > b) a compatibility conflict with the assigned element that the IDE finds by > > > reflection at assignment time and simply does not publish. If so... > > > . . . Why is it not detected before the element gets into the propEd's drop > > > down ? > > > . . . Is there something I can do to prevent the conflict and get WYSIWYG back > > > for my layout ? > > > . . . What problems could I encounter by having circumvented the IDE's > > > (postulated) compatibility checks ? > > > > > > Even when wysiwyg is not an issue, i.e. when assigning properties with no > > > visual consequences, this silent rejection of apparently valid property > > > assignments is a pain. Under the JBuilder IDE, it disrupts the process of > > > developing easily wired components for distribution/sale. Properties cannot be > > > wired up in the JBuilder IDE, but can be wired up by programmatic techniques. > > > I'm going to check this out in Symantec Cafe next week. Maybe I'll get > > > diagnostics if the problem is mine. > > > > > > I'm using JB2. > > > > > > Greg Hamer wrote: > > > > > > > If you turn on logging for JBuilder, you may see some stack traces for your > > > > problem. > > > > To turn on logging, edit lib\jbuilder.properties while JBuilder is not > > > > running . > > > > Near the top of the file, change the line > > > > jbuilder.logOutput=nul > > > > to point to a file. > > > > In JBuilder3, some design time problems write messages to the message view. > > > > > > > > Bill Winspur wrote: > > > > > > > > > I'm attempting to set the icon property of a JButton in the inspector. > > > > > I've created class ZoomIcon, which extends Object and implements Icon. A > > > > > ZoomIcon instance draws a plus sign or a minus sign when its paintIcon > > > > > method is invoked (intended to save a couple of gif downloads). > > > > > > > > > > In a test JFrame, having only the single JButton on it, I create an > > > > > instance of ZoomIcon by: > > > > > > > > > > Icon plusSign = new ZoomIcon(ZoomIcon.PlusSign); > > > > > > > > > > In its drop down menu, the 'icon' property editor of the JButton's > > > > > inspector shows plusSign, BUT .... when I select plus sign from the drop > > > > > down, the inspector flickers and fails to assign it to the property. > > > > > > > > > > 1. Given that the property editor accepted the ZoomIcon, which IDE > > > > > component subsequently rejected it ? > > > > > > > > > > 2. Is there a diagrnostic/logging trace that would show why the property > > > > > was rejected ? > > > > > > > > > > 3 What conditions can cause reject of a property assignment from the > > > > > drop down list.? > > > > > > > > > > I've pored over the archives to no avail, except that a similar problem > > > > > has been reported before <34F1CA3B.91027487@csi.com>, but there is no > > > > > resolution of it in the archive. > > > > > > > > > > Thanks in advance for any help you can give. > > ------------------------------------------------------------------------ > Name: ZoomIcon.java > ZoomIcon.java Type: Java Source (application/x-unknown-content-type-JBuilder.Java) > Encoding: base64
Technical Details
Message-ID:
<37600C19.A63E299A@borland.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<375747BC.B95AB01D@wynnon.com> <37588946.7591048A@borland.com> <37596FAA.71C07039@wynnon.com> <375AE4BC.27194B99@borland.com> <375C48BE.C9C6831@wynnon.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 111d45,3c5e4ef4c2212740 X-Google-Attributes: gid111d45,public From: Greg Hamer <ghamer@borland.com> Subject: Re: inspector bites icon Date: 1999/06/10 Message-ID: <37600C19.A63E299A@borland.com> X-Deja-AN: 488024356 Content-Transfer-Encoding: 7bit References: <375747BC.B95AB01D@wynnon.com> <37588946.7591048A@borland.com> <37596FAA.71C07039@wynnon.com> <375AE4BC.27194B99@borland.com> <375C48BE.C9C6831@wynnon.com> X-Accept-Language: en Content-Type: text/plain; charset=us-ascii Organization: Another Netscape Collabra Server User Mime-Version: 1.0 Newsgroups: borland.public.jbuilder.java.swing