Internal Panels

  Displaying background images
  The Scrollable definition

Often you can realize a layout only by creating internal panels. You drop a JPanel onto a grid cell and what you get is a grid inside a grid.
An internal panel  Example 16
Tip: You can create internal panels from any contiguous selection by choosing 'Apply Panel to Selection'. This command replaces the current selection with an internal panel containing the selection.

With 'Show Internal Grids' deselected, the internal panel acts like any other container: To select components inside the panel, you need to double-click it in order to switch to its hierarchy level.
With 'Show Internal Grids' selected, the internal grid shines through and components can be selected directly. (Because this can be confusing for beginners, the flag is deselected by default.)
Note: With 'Show Internal Grids' selected, you cannot select the internal panel with a mouse click. You can select it either by Ctrl-Alt-clicking it or by choosing 'Select Panel' from the panel's context menu.


Displaying background images     Top of page

You specify a background image with the bgImage property. All other settings are optional.
bgImageDoubleBuffered: Deselect this to save memory. The default is true.
bgImageHorizontalAlignment: One of LEFT, CENTER or RIGHT.The default is CENTER.
bgImageScaleMode: One of SCALE_NONE, SCALE_HORIZONTAL, SCALE_VERTICAL, SCALE_BOTH, SCALE_TO_FIT, SCALE_TO_FILL, REPEAT_HORIZONTAL, REPEAT_VERTICAL or REPEAT_BOTH. The default is SCALE_NONE.
bgImageVerticalAlignment: One of TOP, CENTER or BOTTOM. The default is CENTER.
Panel with background image  Example 17


The Scrollable definition     Top of page

Every RadiPanel has a scrollableDefinition property:

A ScrollableDefinition has the following settings:
With Fill horizontal deselected, the panel will not fill the viewport horizontally if its width is less than the viewport's width.
With Fill vertical deselected, the panel will not fill the viewport vertically if its height is less than the viewport's height.
Note: If the panel's design grid has no cells with a column/row weight > 0, settings made here are meaningless.
Define the viewport's width and height.
Select either the panel's preferred width/height (scrolling in either the horizontal or vertical direction will be disabled) or select a fixed width/height (scrolling in either the horizontal or vertical direction will be enabled if the given value is smaller than the panel's preferred width/height).
Note: Setting the scroll pane's preferredWidth property will override 'Scrollable viewport size' settings.
Unit increment defines, how far the viewport's content will scroll after a click on one of the arrow buttons. Select an Absolute increment (in pixels) or a Relative increment (in percent), relative either to the panel size or to the viewport size.
Block increment defines, how far the viewport's content will scroll after a click in the scrollbar track. Settings are similar to the ones in unit increment.