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.
Hi I have written a simple BeanInfo with NetBeans for my own custom layout. But there's a small problem with the generated code: when setting items like Short Description Code, Display Name Code, and whatever that's a String, NetBeans does not put double quotes in the generated code. So one has to write "Custom Layout" instead of Custom Layout in the value field to get the correct generated code. It's always reproducable.
Are the properties 'Short Description Code' and 'Display Name Code' really of String type? Don't you have your own PropertyEditor for them? Or don't you set them via Form Connection property editor? BTW If you set something as code then there cannot be quotes put automatically because as code you can provide anything, not just Strings. Can you give more details? Or best - to attach or send me your layout manader so I could try it? Thanks
Created attachment 11860 [details] Source Code and Binaries for EqualiedLayout
Oops... I forgot to send the comment itself... So here it is: Hi After clicking on the "BeanInfo Editor..." menu-item in the popup menu that becomes visible when someone clicks on the "Bean Patterns" node of a class, a dialog opens. (In that dialog) and in the right panel for the "Bean" node's only child there are several items: Name, Expert, Hidden, ... and finally "Display Name Code", and "Short Description Code". I think these items should have a "..." button like the Component Inspector and the user should be able to select if he/she wants to set thses values with custom code or directly. But now the only option is custom code... Not very important but I think adding the forementioned option makes this part of NetBeans more consistent with the rest of the IDE. BTW, my layout-manager (EqualizedLayout) and its BeanInfo and and PropertyEditor are attached to this post (as a jar file). Is there any chance to see it in the next version of NetBeans ? ;-)
Oh, this was my misunderstanding - I thought you meant code generation in form editor, but it was actually the BeanInfo editor. It really has not special property editors for code like form editor has. This could be taken as enhancement request... As for the EqualizedLayout appearing in NetBeans standard distribution - that's not possible, we use just standard components from JDK, no custom components or libraries. On the other hand it would be nice to have e.g. a special module on netbeans.org collecting useful beans, layouts etc for visual development; users could download them additionally. But that's just an idea...