This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 257780 - Jbutton text and/or label properties can be removed from code, but still in form file.
Summary: Jbutton text and/or label properties can be removed from code, but still in f...
Status: RESOLVED INCOMPLETE
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 8.1
Hardware: PC Windows 10 x64
: P3 normal (vote)
Assignee: issues@guibuilder
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-01-31 09:00 UTC by burksr
Modified: 2016-02-15 16:43 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description burksr 2016-01-31 09:00:49 UTC
This seems to be an intermittent problem that I cannot reliably reproduce except to say, it has happened to me many times.

When you enter a value for the text property of the jbutton using the property editor, the label value property is set to match and the label heading will stay non-bolded indicating a default value. If you look at the generated code and the form file, you will see that the text property is set, but not the label property.

If you change the label property in the property editor, the text property is set to match the label and the text heading will be non-bolded indicating a default value. The generated code and the form file will indicate the label property.

On the same Jbutton, if you alter which one you enter a value for, at some point, the generated code will not have a setting for either, but the form will still have it and the designer will show it. Once this happens, you only need to set the value in either of the properties to get the generated code to correct itself.

I have not been able to determine exactly how to reproduce this, but I have done it several times.
Comment 1 Tomas Pavek 2016-02-15 16:43:43 UTC
Hi, I'm sorry but I don't understand what the problem is. First, it makes no sense to set 'text' and 'label' property back and forth over each other. Internally they set the same thing, but there's no need to set 'label' (it is deprecated), so just use 'text'.

Second, if the two properties get into some strange state then please save the form and attach it here so we can look at it. But right now I really don't see what to fix... Thanks