Difference between revisions of "GUIComponent"

From Virtual World Web Wiki
Jump to: navigation, search
(Documentation for the GUIComponent class)
(Documentation for the GUIComponent class)
Line 44: Line 44:
  
 
:{{CSharp|string Name {get; set;} }}
 
:{{CSharp|string Name {get; set;} }}
 
:{{CSharp|string NodeID {get; set;} }}
 
 
 
:{{CSharp|ComponentLayoutExtended PanelLayoutExtended {get;} }}
 
:{{CSharp|ComponentLayoutExtended PanelLayoutExtended {get;} }}
 
::
 
::
 
::The component's layout properties if it's in a layout group
 
::The component's layout properties if it's in a layout group
  
:{{CSharp|GUIContainer ParentSetFromJS {get; set;} }}
+
:{{CSharp|GUIContainer Parent {get; set;} }}
 +
::
 +
::Changes the parent within the hierarchy
  
 
:{{CSharp|int SiblingIndex {get; set;} }}
 
:{{CSharp|int SiblingIndex {get; set;} }}
Line 78: Line 77:
  
 
:{{CSharp|bool Visible {get; set;} }}
 
:{{CSharp|bool Visible {get; set;} }}
 
 
:{{CSharp|GUIBaseWindow Window {get; set;} }}
 
:{{CSharp|GUIBaseWindow Window {get; set;} }}
 
::
 
::

Revision as of 17:57, 27 April 2017

This is the base class for all GUI components. More

  • Inherits class: GUIContainer
  • This is a JavaScript visible object

Remarks [edit]

Properties

bool AllowDrag {get; set;}
Can you drag this component?
bool AllowDrop {get; set;}
Can this component accept drops?
string ContextTag {get; set;}
Setting a ContextTag causes this component to trigger a context menu when right-clicked. The ContextTag can then be checked in the OnPrepareMenu event.
DragItemExtended DragItem {get;}
Details related to this item's drag capabilities
DropTargetExtended DropTarget {get;}
Details about this component's drop-accepting abilities
bool Enabled {get; set;}
Is this component enabled for interaction
bool FitHorizontal {get; set;}
Should this component adjust its horizontal size to accomodate its content? Note: Content does not include Children unless this component also has a LayoutGroup
bool FitVertical {get; set;}
Should this component adjust its vertical size to accomodate its content? Note: Content does not include Children unless this component also has a LayoutGroup
bool IgnoreLayout {get; set;}
Do not apply a parent LayoutGroup to this Component
string Name {get; set;}
ComponentLayoutExtended PanelLayoutExtended {get;}
The component's layout properties if it's in a layout group
GUIContainer Parent {get; set;}
Changes the parent within the hierarchy
int SiblingIndex {get; set;}
What is this component's index within its parents children list
string ToolTip {get; set;}
Text to display when mousing over the component
ResourceValue ToolTipCursor {get; set;}
Cursor to display when mousing over the component
bool ToolTipCursorMiddle {get; set;}
When using a custom cursor, should the cursor be centered (like a crosshair?)
ResourceValue ToolTipImage {get; set;}
Image to display when mousing over the component
string ToolTipTitle {get; set;}
Title text to display when mousing over the component
bool Visible {get; set;}
GUIBaseWindow Window {get; set;}
Which window is this component part of?

Methods

GUIComponent Clone(GUIContainer parent = NULL)
Duplicates this component, optionally under a new parent