Getting Started |
Panels Control |
|
The Panels Control add flexibility to the design of your user interfaces, and simplify the layout of multi-function forms.
The Panels Control is a User Interface control that contains one or more Panels. Each Panel acts as a surface upon which you can place other UI controls, such as buttons and sliders, etc. The Panels Control determines which Panel is visible, that is, only one Panel is visible at a time: the other Panels in its collection are hidden.
This allows you to group related controls together and reuse the area they occupy to display different groups at different times, depending on the context that your form is operating in.
Your UI might need to control a satellite receiver, plasma screen and DVD player, for example. Usually the operator would only need to control one of these devices at any one time. Instead of building a separate form for each device, you can group the controls for each into their own Panel. In this example you would have three Panels: only one of which would be visible at any one time for the operator to interact with.
The diagram below illustrates three Panels, each of which has a different set of buttons for each device being controlled, and are located on the shaded area of the form. The form also includes a set of controls that are always displayed, regardless of which Panel is visible, and a background image that is applied to the form:
Three Panels, the Form and Background Image.
This has the added advantage that all other controls on the form outside of the Panels Control remain always visible and accessible. Your application may require general status controls that don't depend on the currently visible Panel, or could be the controls that select which Panel is visible. This is easier to achieve using the Panels Control than with separate forms, as any controls or actions that need to be common would need to be duplicated onto each form.
Like forms, Panels can also have background images applied. Your UI might have a different background image for each Panel, so that the operator can easily recognize which set of controls are currently active.
Panels can also have transparent backgrounds, which means that the background color of the form, or any image applied to the form will be visible through the Panel: the controls will appear to float on top of the background.
Notes
The transparency feature of Panels is not the same as the Opacity feature of forms: only forms support opacity. You can find out more about transparency and opacity effects in the Forms and Controls reference.
The graphical buttons and background image in the diagram above are part of the 'Tala' graphics template available for Stardraw Control. Read the Graphics Templates section to find out more about purchasing and applying graphics templates.