Python Reference Guide
 
Loading...
Searching...
No Matches
FBToolLayoutManager Class Reference

Tool Layout Manager class. More...

#include <pyfbsdk_generated.h>

Inheritance diagram for FBToolLayoutManager:

Public Member Functions

str CreateLayout (str pLayoutName)
 Create a new layout from the current layout state.
 
bool DeleteLayout (int pLayoutIdx)
 Delete the layout associated with the given layout index.
 
bool DeleteLayout (str pLayoutName)
 Delete the layout with the given layout name.
 
bool GetAutoUpdateLayout ()
 Get the 'Auto-update Layout' state value.
 
int GetCurrentLayoutIdx ()
 Get the layout index of the current layout.
 
str GetCurrentLayoutName ()
 Get the name of the current layout.
 
int GetCustomLayoutCount ()
 Get the number of custom layouts.
 
int GetFactoryLayoutCount ()
 Get the number of factory layouts.
 
str GetLayoutName (int pLayoutIdx)
 Get the layout name associated with the given layout index.
 
bool GetPreventDocking ()
 Get the 'Prevent Docking' state value.
 
str RenameLayout (str pOldLayoutName, str pNewLayoutName)
 Rename a layout.
 
bool SetAutoUpdateLayout (bool pAutoUpdate)
 Set the 'Auto-update Layout' state value.
 
bool SetCurrentLayout (int pLayoutIdx)
 Set the current layout from the given layout index.
 
bool SetCurrentLayout (str pLayoutName)
 Set the current layout from the given layout name.
 
bool SetPreventDocking (bool pPreventDocking)
 Set the 'Prevent Docking' state value.
 
bool UpdateCurrentLayout ()
 Update the current layout from the current layout state.
 
- Public Member Functions inherited from FBComponent
 FBComponent ()
 Constructor.
 
str ClassName ()
 Get the class name.
 
 DisableObjectFlags (FBObjectFlag pFlags)
 Disable a specific Object Flags.
 
 EnableObjectFlags (FBObjectFlag pFlags)
 Enable a specific Object Flags.
 
bool FBCreate ()
 Open Reality Creation function.
 
 FBDelete ()
 Open Reality deletion function.
 
 FBDestroy ()
 Open Reality destruction function.
 
FBObjectFlag GetObjectFlags ()
 Get all Object Flags (concatenated).
 
bool GetObjectStatus (FBObjectStatus pStatus)
 Check to see if an object status is enabled.
 
FBFileReference GetOwnerFileReference (p0)
 Get the owner FileReference object.
 
 HardSelect ()
 HardSelect.
 
bool HasObjectFlags (FBObjectFlag pFlags)
 Check whether a specific object flag is enabled.
 
bool Is (int pTypeId)
 Returns true if object is of type TypeId.
 
bool ProcessNamespaceHierarchy (FBNamespaceAction pNamespaceAction, str pNamespaceName, str pReplaceTo=None, bool pAddRight=True)
 ProcessNamespaceHierarchy.
 
bool ProcessObjectNamespace (FBNamespaceAction pNamespaceAction, str pNamespaceName, str pReplaceTo=None, bool pAddRight=True)
 ProcessObjectNamespace.
 
int PropertyAdd (FBProperty pProperty)
 Add a property to the component's property manager.
 
bool PropertyAddReferenceProperty (FBProperty pReferenceProperty)
 Add a reference property to the component's property manager.
 
FBProperty PropertyCreate (str pName, FBType pType, str pDataType, bool pAnimatable, bool pIsUser=False, FBProperty pReferenceSource=None)
 Create user or dynamic property.
 
 PropertyGetModifiedList (FBArrayTemplate< FB > pPropList, FBPlugModificationFlag pModificationFlags)
 Get list of properties which have been modified since last loading.
 
 PropertyRemove (FBProperty pProperty)
 Remove a Property from the component's Property manager.
 
 SetObjectFlags (FBObjectFlag pFlags)
 SetObjectFlags.
 
 SetObjectStatus (FBObjectStatus pStatus, bool pValue)
 Enable/Disable a specific Object Status.
 

Additional Inherited Members

- Public Attributes inherited from FBComponent
FBListComponent Components
 List: List of components.

 
str LongName
 Read Write Property: Name and namespace for object.

 
str Name
 Read Write Property: Unique name of object. See sample: RemoveSuffixFromNameOfSceneElements.py.
 
FBListComponent Parents
 List: Parents.

 
FBManager PropertyList
 Read Only Property: Manages all of the properties for the component.

 
bool Selected
 Read Write Property: Selected property.

 
int TypeInfo
 Contains the Type information of the object.

 
- Public Attributes inherited from FBPlug
str ClassGroupName
 ClassGroupName of the object.

 
int TypeInfo
 TypeInfo.

 

Detailed Description

Tool Layout Manager class.


This class allows users to interact with Layouts.Sample Python code:

from pyfbsdk import *
lToolLayoutMan = FBToolLayoutManager()
# Delete all existing custom layout
for i in range( lToolLayoutMan.GetCustomLayoutCount() ):
lToolLayoutMan.DeleteLayout( lToolLayoutMan.GetCustomLayoutCount() - 1 )
# Create a new layout
lToolLayoutMan.CreateLayout( "MyLayout" )
# Print the names of all the factory layouts
print "Factory layouts:"
print "----------------"
for aLayoutIdx in range(lToolLayoutMan.GetFactoryLayoutCount()):
print lToolLayoutMan.GetLayoutName(-aLayoutIdx-1)
# Print the names of all the custom layouts
print ""
print "Custom layouts:"
print "----------------"
for aLayoutIdx in range(lToolLayoutMan.GetCustomLayoutCount()):
print lToolLayoutMan.GetLayoutName(aLayoutIdx)
# Set the Scripting Layout
lToolLayoutMan.SetCurrentLayout( -2 )
# Delete the custom layout
lToolLayoutMan.DeleteLayout( "MyLayout" )
Tool Layout Manager class.
Definition: pyfbsdk_generated.h:20104
int GetFactoryLayoutCount()
Get the number of factory layouts.
str CreateLayout(str pLayoutName)
Create a new layout from the current layout state.
int GetCustomLayoutCount()
Get the number of custom layouts.
bool DeleteLayout(int pLayoutIdx)
Delete the layout associated with the given layout index.
str GetLayoutName(int pLayoutIdx)
Get the layout name associated with the given layout index.
bool SetCurrentLayout(int pLayoutIdx)
Set the current layout from the given layout index.
Python module pyfbsk.
Definition: pyfbsdk.h:90

Member Function Documentation

◆ CreateLayout()

str CreateLayout ( str  pLayoutName)

Create a new layout from the current layout state.

Parameters
pLayoutNameThe new layout name to create.
Returns
The new layout's name (could be different that the one supplied) if the operation is successful, nullptr (C++) or None (Python) otherwise.

◆ DeleteLayout() [1/2]

bool DeleteLayout ( int  pLayoutIdx)

Delete the layout associated with the given layout index.

Deleting a factory layout is not permitted.

Parameters
pLayoutIdxThe layout index to delete.
Returns
True if the operation is successful, false otherwise.

◆ DeleteLayout() [2/2]

bool DeleteLayout ( str  pLayoutName)

Delete the layout with the given layout name.

Deleting a factory layout is not permitted.

Parameters
pLayoutNameThe layout name to delete.
Returns
True if the operation is successful, false otherwise.

◆ GetAutoUpdateLayout()

bool GetAutoUpdateLayout ( )

Get the 'Auto-update Layout' state value.

Returns
The 'Auto-update Layout' state value.

◆ GetCurrentLayoutIdx()

int GetCurrentLayoutIdx ( )

Get the layout index of the current layout.

Returns
The layout index of the current layout.

◆ GetCurrentLayoutName()

str GetCurrentLayoutName ( )

Get the name of the current layout.

Returns
The name of the current layout.

◆ GetCustomLayoutCount()

int GetCustomLayoutCount ( )

Get the number of custom layouts.

Returns
The number of custom layouts.

◆ GetFactoryLayoutCount()

int GetFactoryLayoutCount ( )

Get the number of factory layouts.

Returns
The number of factory layouts.

◆ GetLayoutName()

str GetLayoutName ( int  pLayoutIdx)

Get the layout name associated with the given layout index.

Parameters
pLayoutIdxThe layout index to query. The factory layouts are using negative indices.
Returns
The layout name if the operation is successful, nullptr (C++) or None (Python) otherwise.

◆ GetPreventDocking()

bool GetPreventDocking ( )

Get the 'Prevent Docking' state value.

Note: When 'Prevent Docking' state is true, it is possible to temporary allow docking a window by holding the SHIFT key before moving it. When 'Prevent Docking' state is false, it is possible to temporary prevent docking a window by holding the CTRL key before moving it.

Returns
The 'Prevent Docking' state value.

◆ RenameLayout()

str RenameLayout ( str  pOldLayoutName,
str  pNewLayoutName 
)

Rename a layout.

Renaming a factory layout is not permitted.

Parameters
pOldLayoutNameThe layout's name to rename.
pNewLayoutNameThe new layout name.
Returns
The new layout's name (could be different that the one supplied) if the operation is successful, nullptr (C++) or None (Python) otherwise.

◆ SetAutoUpdateLayout()

bool SetAutoUpdateLayout ( bool  pAutoUpdate)

Set the 'Auto-update Layout' state value.

Parameters
pAutoUpdateThe 'Auto-update Layout' state value.
Returns
True if the operation is successful, false otherwise.

◆ SetCurrentLayout() [1/2]

bool SetCurrentLayout ( int  pLayoutIdx)

Set the current layout from the given layout index.

Parameters
pLayoutIdxThe layout index to set as the current layout. The factory layouts are using negative indices.
Returns
True if the operation is successful, false otherwise.

◆ SetCurrentLayout() [2/2]

bool SetCurrentLayout ( str  pLayoutName)

Set the current layout from the given layout name.

Parameters
pLayoutNameThe layout's name to set as the current layout.
Returns
True if the operation is successful, false otherwise.

◆ SetPreventDocking()

bool SetPreventDocking ( bool  pPreventDocking)

Set the 'Prevent Docking' state value.

Note: When 'Prevent Docking' state is true, it is possible to temporary allow docking a window by holding the SHIFT key before moving it. When 'Prevent Docking' state is false, it is possible to temporary prevent docking a window by holding the CTRL key before moving it.

Parameters
pPreventDockingThe 'Prevent Docking' state value.
Returns
True if the operation is successful, false otherwise.

◆ UpdateCurrentLayout()

bool UpdateCurrentLayout ( )

Update the current layout from the current layout state.

Updating a factory layout is not permitted.

Returns
True if the operation is successful, false otherwise.