#include <ProductView.h>

Public Member Functions | |
| virtual void | setPaperSize (double dWidth, double dHeight)=0 |
| virtual void | getPaperSize (double &dWidth, double &dHeight) const =0 |
| virtual void | setPaperColor (const ColorType &paperColor)=0 |
| virtual ColorType | getPaperColor () const =0 |
| virtual void | setDpi (unsigned int dpi)=0 |
| virtual unsigned int | getDpi () const =0 |
| virtual bool | loadTemplate (const std::string &filename)=0 |
| virtual bool | saveTemplate (const std::string &filename) const =0 |
| virtual AnnotationLayer * | getLayoutLayer () const =0 |
| virtual ClassificationLayer * | getClassificationLayer () const =0 |
| virtual void | setActiveLayer (GraphicLayer *pLayer)=0 |
| virtual GraphicLayer * | getActiveLayer () const =0 |
| virtual bool | setActiveEditObject (GraphicObject *pObject)=0 |
| virtual GraphicObject * | getActiveEditObject () const =0 |
| virtual bool | setActiveEditView (View *pView)=0 |
| virtual View * | getActiveEditView () const =0 |
Static Public Member Functions | |
| static const Filename * | getSettingTemplateFile () |
| static bool | hasSettingTemplateFile () |
| static void | setSettingTemplateFile (Filename *pNewValue, bool setIfSame=false) |
| static std::string | getSettingTemplateFileKey () |
| static const Filename * | getSettingTemplatePath () |
| static bool | hasSettingTemplatePath () |
| static void | setSettingTemplatePath (Filename *pNewValue, bool setIfSame=false) |
| static std::string | getSettingTemplatePathKey () |
| static PositionType | getSettingClassificationMarkingPositions () |
| static bool | hasSettingClassificationMarkingPositions () |
| static void | setSettingClassificationMarkingPositions (PositionType newValue, bool setIfSame=false) |
| static std::string | getSettingClassificationMarkingPositionsKey () |
| static const std::string & | signalPaperSizeChanged () |
| static const std::string & | signalPaperColorChanged () |
| static const std::string & | signalDpiChanged () |
| static const std::string & | signalLayerActivated () |
Protected Member Functions | |
| virtual | ~ProductView () |
The product view provides a means by which custom output products can be created. The view contains an annotation layer called the layout layer that is displayed on a sheet of paper. Annotation objects can be added to the layout layer to create a finished product. View objects are often used in the layout layer to display data or results. Because views can be modified separately, the product view contains an active edit view. The active edit view object is identified in the layout layer with selection handles. The view also contains a classification layer to specify classification markings for the product.
The product view defines the following mouse modes, where the name given is the name populated by MouseMode::getName():
This subclass of Subject will notify upon the following conditions:
Definition at line 52 of file ProductView.h.
| virtual ProductView::~ProductView | ( | ) | [protected, virtual] |
This should be destroyed by calling DesktopServices::deleteView.
Definition at line 434 of file ProductView.h.
| static const Filename* ProductView::getSettingTemplateFile | ( | ) | [static] |
Returns the current value for this setting.
If this setting does not exist in ConfigurationSettings, a NULL value will be returned.
Please see Settings Macros for more details
NULL if not found. Definition at line 63 of file ProductView.h.
| static bool ProductView::hasSettingTemplateFile | ( | ) | [static] |
Returns true if this setting exists in ConfigurationSettings.
It may still be NULL however.
Please see Settings Macros for more details
true if this setting exists, false otherwise. Definition at line 70 of file ProductView.h.
| static void ProductView::setSettingTemplateFile | ( | Filename * | pNewValue, | |
| bool | setIfSame = false | |||
| ) | [static] |
Changes the current value of this setting to the new value.
Please see Settings Macros for more details
| pNewValue | the new value for this setting. If NULL, the value will not be set. | |
| setIfSame | If true, the value will be set into ConfigurationSettings even if the pNewValue and existing value are the same. This has the side-effect of making the value a per-user setting and stored in the user's configuration file. If false, this value will only be set if the pNewValue and existing value are different. Therefore the value will only be stored in the user's configuration file if the pNewValue is unique to the user. |
Definition at line 86 of file ProductView.h.
| static std::string ProductView::getSettingTemplateFileKey | ( | ) | [static] |
Returns the key for this setting that could be passed to ConfigurationSettings::getSetting() or ConfigurationSettings::setSetting().
Please see Settings Macros for more details
Definition at line 94 of file ProductView.h.
| static const Filename* ProductView::getSettingTemplatePath | ( | ) | [static] |
Returns the current value for this setting.
If this setting does not exist in ConfigurationSettings, a NULL value will be returned.
Please see Settings Macros for more details
NULL if not found. Definition at line 103 of file ProductView.h.
| static bool ProductView::hasSettingTemplatePath | ( | ) | [static] |
Returns true if this setting exists in ConfigurationSettings.
It may still be NULL however.
Please see Settings Macros for more details
true if this setting exists, false otherwise. Definition at line 110 of file ProductView.h.
| static void ProductView::setSettingTemplatePath | ( | Filename * | pNewValue, | |
| bool | setIfSame = false | |||
| ) | [static] |
Changes the current value of this setting to the new value.
Please see Settings Macros for more details
| pNewValue | the new value for this setting. If NULL, the value will not be set. | |
| setIfSame | If true, the value will be set into ConfigurationSettings even if the pNewValue and existing value are the same. This has the side-effect of making the value a per-user setting and stored in the user's configuration file. If false, this value will only be set if the pNewValue and existing value are different. Therefore the value will only be stored in the user's configuration file if the pNewValue is unique to the user. |
Definition at line 126 of file ProductView.h.
| static std::string ProductView::getSettingTemplatePathKey | ( | ) | [static] |
Returns the key for this setting that could be passed to ConfigurationSettings::getSetting() or ConfigurationSettings::setSetting().
Please see Settings Macros for more details
Definition at line 134 of file ProductView.h.
| static PositionType ProductView::getSettingClassificationMarkingPositions | ( | ) | [static] |
Returns the current value for this setting.
If this setting does not exist in ConfigurationSettings, a verification error will be logged to the message log and potentially a verification error message box will be displayed to the user.
Please see Settings Macros for more details
Definition at line 145 of file ProductView.h.
| static bool ProductView::hasSettingClassificationMarkingPositions | ( | ) | [static] |
Returns true if this setting exists and has a value in ConfigurationSettings.
Please see Settings Macros for more details
true if this setting exists, false otherwise. Definition at line 152 of file ProductView.h.
| static void ProductView::setSettingClassificationMarkingPositions | ( | PositionType | newValue, | |
| bool | setIfSame = false | |||
| ) | [static] |
Changes the current value of this setting to the new value.
Please see Settings Macros for more details
| newValue | the new value for this setting. | |
| setIfSame | If true, the value will be set into ConfigurationSettings even if the newValue and existing value are the same. This has the side-effect of making the value a per-user setting and stored in the user's configuration file. If false, this value will only be set if the newValue and existing value are different. Therefore the value will only be stored in the user's configuration file if the newValue is unique to the user. |
Definition at line 168 of file ProductView.h.
| static std::string ProductView::getSettingClassificationMarkingPositionsKey | ( | ) | [static] |
Returns the key for this setting that could be passed to ConfigurationSettings::getSetting() or ConfigurationSettings::setSetting().
Please see Settings Macros for more details
Definition at line 176 of file ProductView.h.
| static const std::string& ProductView::signalPaperSizeChanged | ( | ) | [static] |
Emitted with boost::any<std::pair<double,double> > when the paper size is changed.
Definition at line 182 of file ProductView.h.
| static const std::string& ProductView::signalPaperColorChanged | ( | ) | [static] |
Emitted with boost::any<ColorType> when the paper color is changed.
Definition at line 187 of file ProductView.h.
| static const std::string& ProductView::signalDpiChanged | ( | ) | [static] |
Emitted with boost::any<unsigned int> when the paper dpi changes.
Definition at line 192 of file ProductView.h.
| static const std::string& ProductView::signalLayerActivated | ( | ) | [static] |
Emitted with boost::any<Layer*> when a layer is activated.
Definition at line 197 of file ProductView.h.
| virtual void ProductView::setPaperSize | ( | double | dWidth, | |
| double | dHeight | |||
| ) | [pure virtual] |
Sets the paper size.
This method does not call View::refresh() so that multiple calls to modify view settings can be made without refreshing the view after each modification.
| dWidth | The new width of the displayed paper in inches. | |
| dHeight | The new height of the displayed paper in inches. |
| virtual void ProductView::getPaperSize | ( | double & | dWidth, | |
| double & | dHeight | |||
| ) | const [pure virtual] |
Retrieves the paper size.
| dWidth | Populated with the width of the displayed paper in inches. | |
| dHeight | Populated with the height of the displayed paper in inches. |
| virtual void ProductView::setPaperColor | ( | const ColorType & | paperColor | ) | [pure virtual] |
Sets the paper color.
The paper color extends to the edge of the paper area. Depending on the view zoom level, this may or may not extend to the edge of the view area.
This method does not call View::refresh() so that multiple calls to modify view settings can be made without refreshing the view after each modification.
| paperColor | The new paper color. |
| virtual ColorType ProductView::getPaperColor | ( | ) | const [pure virtual] |
| virtual void ProductView::setDpi | ( | unsigned int | dpi | ) | [pure virtual] |
Sets the dots per inch (DPI) of the paper.
The paper DPI is used in conjunction with the paper size to establish the coordinate extents of the paper used by the Layout annotation layer. The default DPI is 100, so a paper size of 8.5 by 11 has paper coordinate extents of 850 and 1100.
This method does not call View::refresh() so that multiple calls to modify view settings can be made without refreshing the view after each modification.
| dpi | The new dots per inch value of the paper. |
| virtual unsigned int ProductView::getDpi | ( | ) | const [pure virtual] |
Returns the dots per inch (DPI) of the displayed paper.
The paper DPI is used in conjunction with the paper size to establish the coordinate extents of the paper used by the Layout annotation layer. The default DPI is 100, so a paper size of 8.5 by 11 has paper coordinate extents of 850 and 1100.
| virtual bool ProductView::loadTemplate | ( | const std::string & | filename | ) | [pure virtual] |
Loads a product template from a file.
A product template is a set of annotation objects displayed in the layout layer. Loading a template from a file removes all objects currently displayed in the layout layer.
| filename | The filename of the template to load. An empty string will cause a file selection dialog box to be displayed for the user to select a file. |
| virtual bool ProductView::saveTemplate | ( | const std::string & | filename | ) | const [pure virtual] |
Saves the annotation objects in the layout layer as a template.
| filename | The destination filename of the template to save. An empty string will cause a file selection dialog box to be displayed for the user to select a file. |
| virtual AnnotationLayer* ProductView::getLayoutLayer | ( | ) | const [pure virtual] |
Returns the annotation layer for the product's annotation objects.
| virtual ClassificationLayer* ProductView::getClassificationLayer | ( | ) | const [pure virtual] |
Returns the classification layer used to display the product classification markings.
| virtual void ProductView::setActiveLayer | ( | GraphicLayer * | pLayer | ) | [pure virtual] |
Sets the active layer in the view.
The active layer will appear on the toolbar if there is no active edit view.
| pLayer | The layer to activate. This must be either the layout layer or the classification layer. |
| virtual GraphicLayer* ProductView::getActiveLayer | ( | ) | const [pure virtual] |
Returns the active product view layer.
| virtual bool ProductView::setActiveEditObject | ( | GraphicObject * | pObject | ) | [pure virtual] |
Sets the active view object that processes mouse and other events.
This method enables and disables editing of a view inside of its annotation view object. The active view object appears with selection handles and all mouse events are processed by the view instead of the layout layer.
The active edit view object can also be set according to its view by calling setActiveEditView().
| pObject | The annotation view object to set as the active edit object. If this value is non-NULL, the active layer becomes NULL. If the value is NULL, editing of the view is disabled and editing of the layout layer is enabled. |
| virtual GraphicObject* ProductView::getActiveEditObject | ( | ) | const [pure virtual] |
Returns the annotation view object that has view editing enabled.
This method returns the current annotation object containing the view that can be edited. The view inside the annotation object can be obtained directly by calling getActiveEditView().
| virtual bool ProductView::setActiveEditView | ( | View * | pView | ) | [pure virtual] |
Sets the active view that processes mouse and other events.
This method enables and disables editing of a view inside of its annotation view object. The active view object appears with selection handles and all mouse events are processed by the view instead of the layout layer.
The active edit view object can also be set according to its annotation object by calling setActiveEditObject().
| pView | The view to set as the active edit view. The view must be contained in a valid annotation view object in the layout layer. If the view object containing this view is found, the active layer becomes NULL. Set this value to NULL to disable view editing and enable editing of the layout layer. |
| virtual View* ProductView::getActiveEditView | ( | ) | const [pure virtual] |
Returns the view that has editing enabled.
This method returns the view inside the annotation view object that is currently active. This is identical to getActiveEditObject()->getObjectView().