Difference between revisions of "DesktopPagePanel"

From Xojo Documentation

(Created page with "N/A")
 
 
Line 1: Line 1:
N/A
+
{{ClassBox
 +
| super=[[DesktopUIControl]]
 +
| platform=all
 +
| scope=global
 +
}}
 +
{{Description
 +
| text=Used to organize controls on hidden panels. Only the controls on the current panel are visible to the user. This control does not display a user interface at run-time.
 +
}}
 +
 
 +
<dynamicTable id="Events" super="DesktopUIControl" class="eventTable" title="Events" columns="3">
 +
{{Event | name=PanelChanged | description=PanelChanged()&#x0A;The frontmost panel has changed. }}
 +
</dynamicTable>
 +
 
 +
<dynamicTable id="Properties" super="DesktopUIControl" class="propertyTable" title="Properties" columns="3">
 +
{{Property | name=LastAddedPanelIndex | type=Integer | platform=all | readonly=yes | description=( Integer)&nbsp;&nbsp;The number of the last panel added with AddPanel or AddPanelAt.  }}
 +
{{Property | name=PanelCount | type=Integer | platform=all | readonly=yes | description=( Integer)&nbsp;&nbsp;Gets the number of panels in the PagePanel. }}
 +
{{Property | name=SelectedPanelIndex | type=Integer | platform=all | description=( Integer)&nbsp;&nbsp;The number of the currently selected panel. The first panel is number zero.  }}
 +
</dynamicTable>
 +
 
 +
<dynamicTable id="Methods" super="DesktopUIControl" class="methodTable" title="Methods" columns="3">
 +
{{Method | name=AddPanel | newinversion=2021r3=AddPanel()&#x0A;Appends a new panel after the last panel. }}
 +
{{Method | name=AddPanelAt | params=Index as [[Integer]], Name as [[String]] | description=AddPanelAt(Index as Integer)&#x0A;Inserts a new panel at the specified position. The first panel is numbered zero.  }}
 +
{{Method | name=RemovePanelAt | params=Index as [[Integer]] | description=RemovePanelAt(Index as Integer)&#x0A;Removes the panel specified by Index. The first panel is numbered zero.  }}
 +
</dynamicTable>
 +
 
 +
==Notes==
 +
The '''DesktopPagePanel''' control allows you to add controls to panels, just as you add controls to [[DesktopTabPanel]]s. The difference is that the '''DesktopPagePanel''' control itself is not visible in your built application. Only the controls on the currently selected panel are visible. You change the displayed panel by changing the [[DesktopPagePanel.SelectedPanelIndex|SelectedPanelIndex]] property. PagePanels cannot be embedded inside PagePanels.
 +
 
 +
You get or set the panel on which a control is located via the PanelIndex property of the [[DesktopControl]] class. The first panel is numbered zero.
 +
 
 +
In the IDE, you can add, insert, delete, reorder and navigate from panel to panel, just like a [[DesktopTabPanel]]. When building an interface using the '''DesktopPagePanel''', you can take advantage of the Control Hierarchy, discussed in the section on the [[DesktopUIControl]] object.
 +
 
 +
==Examples==
 +
The following line of code moves a [[DesktopListBox]] from its current panel to the second panel of a '''DesktopPagePanel'''.
 +
 +
<rbcode>
 +
ListBox1.PanelIndex = 1
 +
</rbcode>
 +
 
 +
==See Also==
 +
[[DesktopTabPanel]] control; [[DesktopUIControl]] class.
 +
 
 +
[[Category:Desktop]]
 +
[[Category:Desktop Controls]]

Latest revision as of 19:18, 23 July 2021

Class (inherits from DesktopUIControl)

Used to organize controls on hidden panels. Only the controls on the current panel are visible to the user. This control does not display a user interface at run-time.

Events
Closing FocusLost MouseExit
ConstructContextualMenu FocusReceived MouseMove
ContextualMenuItemSelected KeyDown MouseUp
DragEnter KeyUp MouseWheel
DragExit MouseDown Opening
DragOver MouseDrag PanelChanged
DropObject MouseEnter
Properties
Active fa-lock-32.png LockBottom Scope fa-lock-32.png
AllowAutoDeactivate LockLeft SelectedPanelIndex
AllowTabStop LockRight TabIndex
Enabled LockTop Tooltip
Handle fa-lock-32.png MouseCursor Top
Height Name fa-lock-32.png Transparent
Index fa-lock-32.png PanelCount fa-lock-32.png Visible
LastAddedPanelIndex fa-lock-32.png PanelIndex Width
Left Parent Window fa-lock-32.png
Methods
AcceptFileDrop AddPanel Refresh
AcceptPictureDrop AddPanelAt RemovePanelAt
AcceptRawDataDrop Close SetFocus
AcceptTextDrop DrawInto

Notes

The DesktopPagePanel control allows you to add controls to panels, just as you add controls to DesktopTabPanels. The difference is that the DesktopPagePanel control itself is not visible in your built application. Only the controls on the currently selected panel are visible. You change the displayed panel by changing the SelectedPanelIndex property. PagePanels cannot be embedded inside PagePanels.

You get or set the panel on which a control is located via the PanelIndex property of the DesktopControl class. The first panel is numbered zero.

In the IDE, you can add, insert, delete, reorder and navigate from panel to panel, just like a DesktopTabPanel. When building an interface using the DesktopPagePanel, you can take advantage of the Control Hierarchy, discussed in the section on the DesktopUIControl object.

Examples

The following line of code moves a DesktopListBox from its current panel to the second panel of a DesktopPagePanel.

ListBox1.PanelIndex = 1

See Also

DesktopTabPanel control; DesktopUIControl class.