Issue Details (XML | Word | Printable)

Key: UVE-327
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: ULC Team
Reporter: Sibylle Peter
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
ULCVisualEditor

Custom widgets created with VE added to another container using choose Bean do not show in the correct size at design time

Created: 20/Dec/05 05:51 PM   Updated: 05/Nov/09 03:05 PM
Component/s: core
Affects Version/s: ULC Visual Editor 5.0
Fix Version/s: ULC Visual Editor 6.1.2

Issue Links:
Reference
 


 Description  « Hide
Description of a special szenario, but true for all custom widgets:
  • create a class which extends from ULCToolBar (e.g. MyToolBar)
  • add some buttons in it, save.
  • Create a class which extends from ULCFrame
  • create a border layout pane
  • add the MyToolBar to the borderlayout pane
  • add the borderlayoutpane to the frame.
    --> the MyToolBar is not shown correctly on the canvas. During runtime everything is fine.

Reason: When no preferred size is set in ULC, there is no way to find out the preferred size computed of the layout manager in Swing. Therefore we just assume a "default" preferred size (20,20) during design time.

Workaround:

  • set the preferred size to something meaningful in the frame class and wrap it in:

if (Beans.isDesignTime() {
toolbar.setPreferredSize(new Dimension(100, 50);
}



 All   Comments   Change History      Sort Order: Ascending order - Click to sort in descending order
Janak Mulani added a comment - 02/Nov/09 06:52 PM
see the comment for UVE-349