FaqUnexpectComponentMove

(Difference between revisions)
Line 4: Line 4:
Yes, actually you can minimize occurrence of this behavior when you keep the rules listed below.
Yes, actually you can minimize occurrence of this behavior when you keep the rules listed below.
-
# '''To have a concept of Designing Form'''. It's better to have an exact idea how the form will look like. Because it is better to insert the component on place which won't be changed then  
+
# '''Have a concept of the designing form'''. It's better to have a relatively precise idea how the form will look like in advance. It's better to add components on the right places directly, with the right (suggested) spacing, rather then throwing them randomly on canvas and then trying to rearrange them.
-
# '''Design smaller part'''. Try to use smaller areas for design .. e.g. you have complicated form - then It's recommended to divide it into small parts using panels. It is easier to repair panel with 5 components then big form with 20 ones.  
+
# '''Design by smaller parts'''. Try to divide complicated UI into sub-panels when suitable. You can then also switch (focus) design only to these individual panels. The visual design is easier to manage when composed from less complex parts.
-
# '''Alignment Tools'''. [[Image:AlignmentTools_FaqUnexpectComponentMove.png]] Use alignment tools from the designer toolbar in case when you want to center components, align them along the left/right column .. etc.  
+
# '''Alignment Tools'''. [[Image:AlignmentTools_FaqUnexpectComponentMove.png]] Use alignment tools from the designer toolbar in case when you want to center already placed components, align them along the left/right column etc - instead of rearranging them by mouse one by one.
-
# '''Guide Lines'''. Use guide lines during placing the components into container which helps to keep preferred gap.  
+
# '''Guide Lines'''. Pay attention to the guidelines that appear when dragging components and use them to place/align/anchor components as needed.
-
# '''Space Around Components'''. If you just want to do cosmetic adjustment and edit position of components towards each other, use tool from popup menu "Space Around Components" instead of manual moving or adjustment. You can set preferred gap manually like Default small/medium/large this way.
+
# '''Space Around Components'''. If you want to do small adjustments like moving components towards each other, which in fact means to adjust the space between components or at the border, use the "Space Around Components" dialog from the popup menu. It's much easier to set the desired space directly than trying to move multiple components manually.
-
# '''The Same Size Tool'''. If you have e.g. 2 components and you want them to have the same size (width/height), don't do it manually. Use tool from popup menu invoked on selected components - Same Size.  
+
# '''The Same Size Tool'''. To make several components of the same size, don't try to resize them to match each others size. Instead use the "Same Size" actions from popup menu on selected components.
   
   

Revision as of 16:06, 1 February 2011

Can I avoid the state when components unexpectedly moved in container during design of GroupLayout?

Yes, actually you can minimize occurrence of this behavior when you keep the rules listed below.

  1. Have a concept of the designing form. It's better to have a relatively precise idea how the form will look like in advance. It's better to add components on the right places directly, with the right (suggested) spacing, rather then throwing them randomly on canvas and then trying to rearrange them.
  2. Design by smaller parts. Try to divide complicated UI into sub-panels when suitable. You can then also switch (focus) design only to these individual panels. The visual design is easier to manage when composed from less complex parts.
  3. Alignment Tools. Image:AlignmentTools_FaqUnexpectComponentMove.png Use alignment tools from the designer toolbar in case when you want to center already placed components, align them along the left/right column etc - instead of rearranging them by mouse one by one.
  4. Guide Lines. Pay attention to the guidelines that appear when dragging components and use them to place/align/anchor components as needed.
  5. Space Around Components. If you want to do small adjustments like moving components towards each other, which in fact means to adjust the space between components or at the border, use the "Space Around Components" dialog from the popup menu. It's much easier to set the desired space directly than trying to move multiple components manually.
  6. The Same Size Tool. To make several components of the same size, don't try to resize them to match each others size. Instead use the "Same Size" actions from popup menu on selected components.



  Applies to: All NetBeans versions
  Platforms: All
Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo