Rogue Wave Views 5.6 |
Rogue Wave Views |
Rogue Wave Views Documentation Home |
An interactor that controls the visible area of a view by using a movable rectangle in another view. More...
#include <ilviews/manager/magview.h>
Public Member Functions | |
virtual void | abort () |
Aborts the interaction. | |
virtual void | adjustView (const IlvRect &rect) |
Adjusts the visible area of the target view according to the specified control rectangle. | |
virtual void | computeRectangle () |
Computes the internal control rectangle according to the overview and the target transformer. | |
IlvDrawSelection * | getDrawSelection () |
Returns the selection object used by the interactor in resizing mode. | |
IlvGraphic * | getGraphic () const |
Returns the graphic object used by the interactor as the magnifier. | |
IlvView * | getTarget () const |
Returns the target view of the interactor. | |
virtual void | handleEvent (IlvEvent &event) |
Handles events for the manager view. | |
virtual void | init () |
Initialization, when the interactor is attached to a view. | |
IlBoolean | isAutoTranslating () const |
Checks if the auto translate mode is on or not. | |
IlBoolean | isAutoZoomConstrained () const |
Checks if the auto zoom mode is constrained. | |
IlBoolean | isAutoZooming () const |
Checks whether the auto zoom mode is on. | |
IlBoolean | isResizingAllowed () const |
Checks if the control rectangle can be resized. | |
virtual void | resetOverview () |
Resets the overview. | |
void | setAutoTranslating (IlBoolean set) |
Enables or disables the auto translate mode. | |
void | setAutoZoomConstrained (IlBoolean set) |
void | setAutoZooming (IlBoolean set) |
Enables or disables the auto zoom mode. | |
void | setDrawSelection (IlvDrawSelection *dr) |
Sets the selection object used by the interactor in resizing mode. | |
void | setGraphic (IlvGraphic *gr) |
Sets the graphic object used as the magnifier. | |
void | setResizingAllowed (IlBoolean allow) |
Specifies whether the control rectangle can be resized. | |
void | setTarget (IlvView *view) |
Sets the target view of the interactor. |
An interactor that controls the visible area of a view by using a movable rectangle in another view.
This interactor is used to create an overview window. The overview window shows the entire contents of a manager while the main window shows only a part of the manager. When the interactor is set on the overview window, the rectangle drawn by the interactor shows the visible area of the manager in the main window. It changes the visible area of the main window when the rectangle in the overview window is moved. The view controlled by the interactor is called the target view. The rectangle drawn on the overview window is represented by a graphic object called the magnifier. It can be a filled rectangle or an empty rectangle. The auto zoom mode and the auto translate allow the overview to be automatically zoomed or translated to follow the display in the main window. Library: ilvmgr
virtual void IlvManagerMagViewInteractor::abort | ( | ) | [virtual] |
Aborts the interaction.
Called by the manager when the user changes the current interactor. It resets the interactor to a state in which it appears to have never been launched. A common implementation is to erase the ghost image. Call this member function to inhibit the interactor action in particular circumstances.
Reimplemented from IlvManagerViewInteractor.
virtual void IlvManagerMagViewInteractor::adjustView | ( | const IlvRect & | rect | ) | [virtual] |
Adjusts the visible area of the target view according to the specified control rectangle.
rect | The control rectangle. |
IlvDrawSelection* IlvManagerMagViewInteractor::getDrawSelection | ( | ) |
Returns the selection object used by the interactor in resizing mode.
IlvGraphic* IlvManagerMagViewInteractor::getGraphic | ( | ) | const |
Returns the graphic object used by the interactor as the magnifier.
The default graphic object used is a framed grid where the frame is drawn with the background color of the object palette and the grid is drawn with the foreground color.
IlvView* IlvManagerMagViewInteractor::getTarget | ( | ) | const |
Returns the target view of the interactor.
The target view is the one controlled by the overview.
virtual void IlvManagerMagViewInteractor::handleEvent | ( | IlvEvent & | event | ) | [virtual] |
Handles events for the manager view.
Called by the manager for which the interactor was created with every event it receives in the interactor view.
Implements IlvManagerViewInteractor.
virtual void IlvManagerMagViewInteractor::init | ( | ) | [virtual] |
Initialization, when the interactor is attached to a view.
Resets the interactor to its initial state.
Called by the manager whenever the interactor is associated with a view. An association of this kind is established by the member function IlvManager::setInteractor
.
Reimplemented from IlvManagerViewInteractor.
IlBoolean IlvManagerMagViewInteractor::isAutoTranslating | ( | ) | const |
Checks if the auto translate mode is on or not.
Returns IlTrue
if the auto translate mode is activated.
IlBoolean IlvManagerMagViewInteractor::isAutoZoomConstrained | ( | ) | const |
Checks if the auto zoom mode is constrained.
IlTrue
if the auto zoom mode is constrained, IlFalse
otherwise. IlBoolean IlvManagerMagViewInteractor::isAutoZooming | ( | ) | const |
Checks whether the auto zoom mode is on.
Returns IlTrue
if the auto zoom mode is activated.
IlBoolean IlvManagerMagViewInteractor::isResizingAllowed | ( | ) | const |
Checks if the control rectangle can be resized.
IlTrue
if the control rectangle can be resized, IlFalse
otherwise. virtual void IlvManagerMagViewInteractor::resetOverview | ( | ) | [virtual] |
Resets the overview.
Resets the internal flags of the overview used to manage the auto zoom mode and the auto zoom constrained mode.
void IlvManagerMagViewInteractor::setAutoTranslating | ( | IlBoolean | set | ) |
Enables or disables the auto translate mode.
When the auto translate mode is enabled, the overview window automatically scrolls so that the visible area of the target view remains inside the overview window.
By default, this mode is disabled.
set | Indicates whether auto translate must be enabled. |
void IlvManagerMagViewInteractor::setAutoZoomConstrained | ( | IlBoolean | set | ) |
Constrains the auto zoom mode so that the overview is never less zoomed than its content.
void IlvManagerMagViewInteractor::setAutoZooming | ( | IlBoolean | set | ) |
Enables or disables the auto zoom mode.
With the auto zoom mode enabled, the overview automatically zooms when the target view is zoomed in or out to maintain a constant ratio between the zoom factor of the overview and the zoom factor of the target view. By default, this mode is disabled.
set | Boolean indicating if auto zoom is enabled or not. |
void IlvManagerMagViewInteractor::setDrawSelection | ( | IlvDrawSelection * | dr | ) |
Sets the selection object used by the interactor in resizing mode.
The interactor is the owner of the object so that its destructor will destroy it.
dr | The selection object to use. |
void IlvManagerMagViewInteractor::setGraphic | ( | IlvGraphic * | gr | ) |
Sets the graphic object used as the magnifier.
The default graphic object used is a framed grid where the frame is drawn with the background color of the object palette and the grid is drawn with the foreground color. The interactor is the owner of the graphic so that its destructor will destroy it.
gr | The graphic object to use. |
void IlvManagerMagViewInteractor::setResizingAllowed | ( | IlBoolean | allow | ) |
Specifies whether the control rectangle can be resized.
When resizing is allowed, a resizing handle appears at each corner of the control rectangle. The object used for the resizing handles is a subclass of IlvDrawSelection
.
allow | Specifies whether the control rectangle can be resized. |
void IlvManagerMagViewInteractor::setTarget | ( | IlvView * | view | ) |
Sets the target view of the interactor.
The target view is the one controlled by the overview.
view | The target view. |
© Copyright 2012, 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.