Rogue Wave Views Gadgets Package API Reference Guide |
Rogue Wave Views Documentation Home |
Class used to handle docking operations. More...
#include <ilviews/gadgets/dockpane.h>
Inherited by IlvAbstractBarDockable.
Public Member Functions | |
IlvDockable (IlvPane *pane=0) | |
Constructor. More... | |
virtual IlBoolean | acceptDocking (const IlvDockableContainer *container, IlUInt index) const |
Indicates whether the pane connected to this dockable instance can dock to the specified dockable container. More... | |
virtual void | dock (IlvDockableContainer *container, IlUInt index, const IlvRect &rect) |
Docks the pane connected to this dockable instance. More... | |
IlvDirection | getDockingDirection () const |
Returns the preferred docking direction of this dockable instance. More... | |
IlvPane * | getPane () const |
Returns the pane connected to this dockable instance. More... | |
const char * | getTitle () const |
Returns the title displayed by the top window when the pane is undocked. More... | |
IlBoolean | isDocked () const |
Returns the dockable state of this dockable instance. More... | |
void | setDockingDirection (IlvDirection direction) |
Sets the preferred docking direction of this dockable instance. More... | |
void | setPane (IlvPane *pane) |
Sets the pane managed by this dockable instance. More... | |
void | setTitle (const char *title) |
Sets the title displayed by the top window when the pane is undocked. More... | |
virtual IlvPanedContainer * | unDock (const IlvRect &rect, IlBoolean show=IlTrue) |
Undocks the pane connected to this dockable instance. More... | |
Static Public Member Functions | |
static IlvDockable * | GetDockable (const IlvPane *pane) |
Returns the instance of IlvDockable that is connected to the specified pane. More... | |
static void | SetDockable (IlvPane *pane, IlvDockable *dockable) |
Connects an instance of IlvDockable to the specified pane. More... | |
Class used to handle docking operations.
Library: ilvadvgdt
Instances of the class IlvDockable
manage docking operations for the IlvPane
object to which they are linked. A pane is said to be docked when it belongs to a dockable container or undocked when it is contained in a special top view. A docked pane is one that is added to a dockable container with the method IlvDockableContainer::addDockingPane
.
IlvDockable::IlvDockable | ( | IlvPane * | pane = 0 | ) |
Constructor.
Initializes a new instance of the IlvDockable
class connected to pane.
pane | The pane to be connected with this instance of IlvDockable . If pane is 0, the pane will have to be set with the IlvDockable::setPane method or the IlvDockable::SetDockable static method later. |
|
virtual |
Indicates whether the pane connected to this dockable instance can dock to the specified dockable container.
You can override this method in subclasses to filter docking operations. This methods calls the IlvDockableContainer::acceptDocking
method.
container | The potential target dockable container. |
index | The position where the pane will be docked in container. |
IlvDockable
.
|
virtual |
Docks the pane connected to this dockable instance.
Docks the pane associated with this instance of IlvDockable
to the dockable container container, at the position specified by the index parameter. This method does nothing if the pane is already docked.
container | The dockable container to which the pane will be docked. |
index | The index specifying the position where the pane will be docked in container. |
rect | The preferred size of the pane. If the dockable container is oriented vertically, the pane height is that of rect. If it is oriented horizontally, the pane width is that of rect. |
|
static |
Returns the instance of IlvDockable
that is connected to the specified pane.
pane | The pane. |
IlvDockable
connected to pane or 0 if there is none. IlvDirection IlvDockable::getDockingDirection | ( | ) | const |
Returns the preferred docking direction of this dockable instance.
When a preferred docking direction has been set with IlvDockable::setDockingDirection
, docking operations are restricted to dockable containers whose orientation matches the specified preferred docking direction. For example, if you want a pane to be docked only to vertical dockable containers, call setDockingDirection(IlvVertical)
.
IlvPane* IlvDockable::getPane | ( | ) | const |
Returns the pane connected to this dockable instance.
IlvDockable
. const char* IlvDockable::getTitle | ( | ) | const |
Returns the title displayed by the top window when the pane is undocked.
0
if no title has been defined. In this case, the title displayed by the top window is the name of the pane. IlBoolean IlvDockable::isDocked | ( | ) | const |
Returns the dockable state of this dockable instance.
IlTrue
if the pane is docked, that is, if it belongs to an IlvDockableContainer
object.
|
static |
Connects an instance of IlvDockable
to the specified pane.
Connects dockable to pane. If an instance of IlvDockable
was already connected to pane, it is removed but not deleted.
pane | The pane to which dockable will be connected. |
dockable | The instance of IlvDockable to connect to pane. |
void IlvDockable::setDockingDirection | ( | IlvDirection | direction | ) |
Sets the preferred docking direction of this dockable instance.
Calling this method restricts docking operation for this dockable instance to dockable containers that match the preferred docking direction. The default value is IlvBadPosition
, which means that no preferred direction has been set. In this case, the pane can be docked in both IlvHorizontal
and IlvVertical
dockable containers.
direction | The preferred docking direction. Valid values are: IlvVertical , IlvHorizontal |
void IlvDockable::setPane | ( | IlvPane * | pane | ) |
Sets the pane managed by this dockable instance.
Note that this method does not connect pane to the instance of IlvDockable
, but simply changes the pane to which it is connected. To connect a pane with an instance of IlvDockable
, use the IlvDockable::SetDockable
method.
pane | The pane to be linked to this instance of IlvDockable . |
void IlvDockable::setTitle | ( | const char * | title | ) |
Sets the title displayed by the top window when the pane is undocked.
When the pane is undocked, it is placed in a special top window. Calling this method lets you specify the title of this top window. If a title was already set, it gets deleted.
title | The title displayed by the top window when the pane is undocked. |
|
virtual |
Undocks the pane connected to this dockable instance.
Removes the pane associated with this instance of IlvDockable
from its container, and adds it to a new top paned container. The new container is resized to rect. This method does nothing if the pane is not docked.
rect | The size and position of the pane in global screen coordinates when undocked. |
show | Not documented. |
© Copyright 2018, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.