Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How do you make a JavaBean which has a static size?

javabean size static
0
Posted

How do you make a JavaBean which has a static size?

0

Location: http://www.jguru.com/faq/view.jsp?EID=39608 Created: Apr 24, 2000 Modified: 2001-07-24 10:28:25.884 Author: John Zukowski (http://www.jguru.com/guru/viewbio.jsp?EID=7) Question originally posed by Asim Raja (http://www.jguru.com/guru/viewbio.jsp?EID=24654 To make a fixed size component, just override the getMinimum/Preferred methods to return the fixed size. You should also provide the bean with its own BeanInfo class to effectively hide the size properties. That way, they won’t appear. You may find it necessary to update the deprecated methods, too, like preferredSize(), but that shouldn’t be necessary. See the Juggler bean that comes with the BDK for one such fixed size component. If you’re class isn’t a subclass of Component, all this is irrelevant.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123