FBEditProperty Class Reference


Detailed Description

Property editor widget.

This widget allows users to edit the values of a property without having to manually customize the GUI depending on the type of the property being edited.

SDK objects can have three types of properties:

  1. An internal property which maps to an actual property that can be seen in the property editor tool of the application. This type of property is usually obtained from the PropertyList data member.

  2. SDK-only property which does not maps onto an existing property of the encapsulated object. The existence of these types of property is often to make the object interface simpler. All the FBPropertyList-types will fall into this category, except for FBPropertyListObjects.

  3. SDK property which maps onto an existing object property, but does so indirectly using function calls instead of direct property access. This is usually for historical reason. In this case the property will usually be present twice in the PropertyList: once as an SDK-Only property and another time as an internal property.

Another limitation of this widget is that it can only display non hidden internal properties. To get around this issue, the property flag can be changed to unhide it. Doing so will also cause the property to be visible via the property tool.

       // In a tool header file...
       FBEditProperty mEditProperty;

       // In a tool source file...
       HFBModel lModel = FBFindModelByName( "ModelName" );
       if( lModel )
       {
           HFBProperty lProperty = lModel->PropertyList.Find( "RotationOrder" );
           if( lProperty &&
               lProperty->IsInternal() &&
               !lProperty->GetPropertyFlag( kFBPropertyFlagHideProperty ))
           {
               mEditProperty.Property = lProperty;
           }
       }
Examples
UI/PropertyDrop.py
Inheritance diagram for FBEditProperty:
Inheritance graph
[legend]

List of all members.

Public Member Functions

  __init__ ()
  Constructor.

Public Attributes

FBPropertyBase  Property
  Read Write Property: Property to edit.
FBPropertyBase  SliderMin
  Read Write Property: Should the property be editable using a slider, set the minimum value atainable with the slider.
FBPropertyBase  SliderMax
  Read Write Property: Should the property be editable using a slider, set the maximum value atainable with the slider.
FBPropertyBase  SmallInc
  Read Write Property: Indicate the small increment applied when click-draging on the property value (usually right-click-dragging).
FBPropertyBase  LargeInc
  Read Write Property: Indicate the large increment applied when click-draging on the property value (usually left-click-dragging).
FBPropertyBase  Precision
  Read Write Property: Used to specify the width and precision of the value shown.
FBPropertyBase  CaptionSize
  Read Write Property: Indicate how much width should the Property Editor reserve for displaying the property name.

Member Function Documentation

__init__ ( )

Member Data Documentation

FBPropertyBase Property

Read Write Property: Property to edit.

Set to NULL to disable.

FBPropertyBase SliderMin

Read Write Property: Should the property be editable using a slider, set the minimum value atainable with the slider.

FBPropertyBase SliderMax

Read Write Property: Should the property be editable using a slider, set the maximum value atainable with the slider.

FBPropertyBase SmallInc

Read Write Property: Indicate the small increment applied when click-draging on the property value (usually right-click-dragging).

FBPropertyBase LargeInc

Read Write Property: Indicate the large increment applied when click-draging on the property value (usually left-click-dragging).

FBPropertyBase Precision

Read Write Property: Used to specify the width and precision of the value shown.

A value of 7.2 indicates to show at minimum 7 numbers, with 2 decimals.

FBPropertyBase CaptionSize

Read Write Property: Indicate how much width should the Property Editor reserve for displaying the property name.


FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty
FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty FBEditProperty