rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Studio Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

IlvStInspectorPanel Class Reference

Inspector class. More...

#include <ivstudio/inspectors/insppnl.h>

Inheritance diagram for IlvStInspectorPanel:
IlvStIGraphicInspectorPanel IlvStIGadgetInspectorPanel

List of all members.

Public Member Functions

 IlvStInspectorPanel (IlvDisplay *display, const char *title, const char *filename=0, IlvSystemView transientFor=0, IlvStIAccessor::UpdateMode mode=IlvStIAccessor::OnApply)
 Constructor.
void addAccessor (IlvStIAccessor *acc)
 Adds the accessor to the main editor of the inspector panel.
void addEditor (IlvStIEditor *editor)
 Adds the editor to the list of editors.
IlvNotebookPage * addPage (const char *title, const char *filename, IlUShort idx=(IlUShort)-1, IlvBitmap *bitmap=0, IlBoolean transparent=IlTrue)
 Creates a notebook page.
virtual void applyChange (IlvGraphic *obj)
 Called to apply the modifications to the graphic object.
IlvStIPropertyAccessorbuildPropertyAccessor (const char *name)
 Creates an accessor to the property of the inspected object.
const IlvStIAccessorfindAccessor (const char *name) const
 Searches for the accessor in the tree of accessors.
IlvStIAccessorfindAccessor (const char *name)
 Searches for the accessor in the tree of accessors.
const IlvStIEditorfindEditor (const char *name) const
 Searches for an editor.
IlvStIEditorfindEditor (const char *name)
 Searches for an editor.
IlvNotebook * getGenericNotebook () const
 Returns the generic notebook of the inspector panel.
IlvStIInspectedObjectAccessorgetInspectedGraphicAccessor () const
 Returns the accessor to the inspected object.
IlvGraphicgetInspectedObject ()
 Returns the current inspected object.
IlvStIAccessor ** getInspectedObjectAccessors (IlUInt &count) const
 Returns the array of accessors to the inspected object.
const IlvStIMainEditorgetMainEditor () const
 Returns the main editor.
IlvStIMainEditorgetMainEditor ()
 Returns the main editor.
IlvGraphicgetPanelObject (const char *name) const
 Returns a graphic object in the inspector panel.
virtual void initFrom (IlvGraphic *obj)
 Called to initialize the editors with the graphic object.
virtual void initializeEditors ()
 Called to initialize the editors.
IlvStIEditorlink (const char *gadgetName, IlvStIPropertyAccessor *accessor, IlvStIEditor::NotificationMode mode=IlvStIEditor::AsOwner)
 Creates an editor which is associated with a gadget.
IlvStIEditorlink (const char *gadgetName, const IlSymbol *valueName, IlvStIEditor::NotificationMode mode=IlvStIEditor::AsOwner)
 Creates an editor which is associated with a gadget.
IlBoolean removeAccessor (IlvStIAccessor *acc)
 Removes the accessor from the main editor of the inspector panel.
IlBoolean removeEditor (IlvStIEditor *editor)
 Removes an editor.
IlBoolean removeEditor (const char *name)
 Removes an editor.
IlBoolean removePage (IlUShort idx)
 Removes a notebook page from the generic notebook.

Detailed Description

Inspector class.

Library: ivstudio

This class defines an inspector panel, which is used to inspect a graphic object. To that end, it handles a set of accessors and editors.

See also:
IlvStIAccessor, IlvStIInspectedObjectAccessor, IlvStIMainEditor.

Constructor & Destructor Documentation

IlvStInspectorPanel::IlvStInspectorPanel ( IlvDisplay display,
const char *  title,
const char *  filename = 0,
IlvSystemView  transientFor = 0,
IlvStIAccessor::UpdateMode  mode = IlvStIAccessor::OnApply 
)

Constructor.

Initializes an instance of IlvStInspectorPanel.

Parameters:
display The display used to create the inspector panel.
title The title of the inspector panel.
filename The path to the .ilv file that loads the inspector.
transientFor The view system for which the inspector is transient.
mode Specifies when the modifications are applied to the inspected object. By default, modifications are performed when the user presses the Apply button.

Member Function Documentation

void IlvStInspectorPanel::addAccessor ( IlvStIAccessor acc  ) 

Adds the accessor to the main editor of the inspector panel.

Parameters:
acc The accessor.
void IlvStInspectorPanel::addEditor ( IlvStIEditor editor  ) 

Adds the editor to the list of editors.

Parameters:
editor The editor.
IlvNotebookPage* IlvStInspectorPanel::addPage ( const char *  title,
const char *  filename,
IlUShort  idx = (IlUShort)-1,
IlvBitmap bitmap = 0,
IlBoolean  transparent = IlTrue 
)

Creates a notebook page.

Creates a notebook page with the specified title, file name, bitmap, and transparency setting. The new page is added to a generic notebook at the position indicated.

Parameters:
title The page title.
filename The page file name.
idx The insertion position, if the value is -1, the page is inserted at the end.
bitmap The page bitmap.
transparent Set this to IlFalse if you do not want bitmap transparency.
Returns:
The created page.
virtual void IlvStInspectorPanel::applyChange ( IlvGraphic obj  )  [virtual]

Called to apply the modifications to the graphic object.

Parameters:
obj The graphic object.

Reimplemented in IlvStIGraphicInspectorPanel, and IlvStIGadgetInspectorPanel.

IlvStIPropertyAccessor* IlvStInspectorPanel::buildPropertyAccessor ( const char *  name  ) 

Creates an accessor to the property of the inspected object.

Parameters:
name The property name.
Returns:
The accessor to the property.
const IlvStIAccessor* IlvStInspectorPanel::findAccessor ( const char *  name  )  const

Searches for the accessor in the tree of accessors.

Searches for the accessor in the tree of accessors that are owned by the inspector.

Parameters:
name The accessor name.
Returns:
The accessor if found, otherwise returns 0.
IlvStIAccessor* IlvStInspectorPanel::findAccessor ( const char *  name  ) 

Searches for the accessor in the tree of accessors.

Searches for the accessor in the tree of accessors that are owned by the inspector.

Parameters:
name The accessor name.
Returns:
The accessor if found, otherwise returns 0.
const IlvStIEditor* IlvStInspectorPanel::findEditor ( const char *  name  )  const

Searches for an editor.

Searches for the editor in the tree of editors that are owned by the inspector.

Parameters:
name The editor name.
Returns:
The editor if found, otherwise returns 0.
IlvStIEditor* IlvStInspectorPanel::findEditor ( const char *  name  ) 

Searches for an editor.

Searches for the editor in the tree of editors that are owned by the inspector.

Parameters:
name The editor name.
Returns:
The editor if found, otherwise returns 0.
IlvNotebook* IlvStInspectorPanel::getGenericNotebook (  )  const

Returns the generic notebook of the inspector panel.

Returns:
The generic notebook of the inspector panel.
IlvStIInspectedObjectAccessor* IlvStInspectorPanel::getInspectedGraphicAccessor (  )  const

Returns the accessor to the inspected object.

Returns:
The accessor to the inspected object.
IlvGraphic* IlvStInspectorPanel::getInspectedObject (  ) 

Returns the current inspected object.

Returns:
The current inspected object.
IlvStIAccessor** IlvStInspectorPanel::getInspectedObjectAccessors ( IlUInt count  )  const

Returns the array of accessors to the inspected object.

The returned array must be deleted by the user.

Parameters:
count Contains the accessor count.
Returns:
The array of accessors. The returned array should be deleted when no longer used. You must call delete[] in order to delete this array properly.
const IlvStIMainEditor& IlvStInspectorPanel::getMainEditor (  )  const

Returns the main editor.

This editor contains all other editors and accessors.

Returns:
A reference to the main editor.
IlvStIMainEditor& IlvStInspectorPanel::getMainEditor (  ) 

Returns the main editor.

This editor contains all other editors and accessors.

Returns:
A reference to the main editor.
IlvGraphic* IlvStInspectorPanel::getPanelObject ( const char *  name  )  const

Returns a graphic object in the inspector panel.

Parameters:
name The graphic object name.
Returns:
The graphic object if found, otherwise returns 0.
virtual void IlvStInspectorPanel::initFrom ( IlvGraphic obj  )  [virtual]

Called to initialize the editors with the graphic object.

Parameters:
obj The graphic object.

Reimplemented in IlvStIGraphicInspectorPanel, and IlvStIGadgetInspectorPanel.

virtual void IlvStInspectorPanel::initializeEditors (  )  [virtual]

Called to initialize the editors.

Adds or removes notebook pages from the inspector panel and creates all the editors and accessors of the inspector panel. Pages should be added to the inspector panel before adding the editors that are associated with the gadgets in these pages.

Reimplemented in IlvStIGraphicInspectorPanel, and IlvStIGadgetInspectorPanel.

IlvStIEditor* IlvStInspectorPanel::link ( const char *  gadgetName,
IlvStIPropertyAccessor accessor,
IlvStIEditor::NotificationMode  mode = IlvStIEditor::AsOwner 
)

Creates an editor which is associated with a gadget.

Creates an editor with the notification mode specified and associates it with the gadget. Then it adds the created editor to the specified accessor. For example, to link a text field gadget named textField to an object name returned by an accessor, type the following:
link("textField", accessor);
The text field is initialized with the value returned by the accessor. When the text field is modified, it notifies the accessor of this change automatically.

Parameters:
gadgetName The gadget name.
accessor The accessor to access to graphic object.
mode The notification mode of the editor.
Returns:
The created editor.
IlvStIEditor* IlvStInspectorPanel::link ( const char *  gadgetName,
const IlSymbol valueName,
IlvStIEditor::NotificationMode  mode = IlvStIEditor::AsOwner 
)

Creates an editor which is associated with a gadget.

Creates an editor with the notification mode specified and associates it with a gadget. It also creates an accessor that accesses the property of the graphic object, and adds the created editor to the created accessor. For example, to link a toggle gadget named toggle to the frame property of a button returned by an accessor, type the following:
link("toggle", accessor, IlvButton::_viewFrame);
The toggle is initialized with the value of the _viewFrame property of the object. When the toggle is modified, it notifies the accessor of this change automatically.

Parameters:
gadgetName The gadget name.
valueName The property name of the graphic object.
mode The notification mode of the editor.
Returns:
The created editor.
IlBoolean IlvStInspectorPanel::removeAccessor ( IlvStIAccessor acc  ) 

Removes the accessor from the main editor of the inspector panel.

Parameters:
acc The accessor.
Returns:
IlTrue if successful, otherwise returns IlFalse.
IlBoolean IlvStInspectorPanel::removeEditor ( IlvStIEditor editor  ) 

Removes an editor.

Removes the editor from the list of editors.

Parameters:
editor The editor.
Returns:
IlTrue if successful, otherwise returns IlFalse.
IlBoolean IlvStInspectorPanel::removeEditor ( const char *  name  ) 

Removes an editor.

Removes the editor from the list of editors.

Parameters:
name The editor name.
Returns:
IlTrue if successful, otherwise returns IlFalse.
IlBoolean IlvStInspectorPanel::removePage ( IlUShort  idx  ) 

Removes a notebook page from the generic notebook.

Parameters:
idx The position of the notebook page.
Returns:
IlTrue if successful, otherwise returns IlFalse.
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

© 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.