Name

basetabpane — A non-visual tabpane for the basetabs component.

Synopsis

LZX: basetabpane
JavaScript: basetabpane
Type: Class
Access: public
Topic: Components.Base Components
Declared in: lps/components/base/basetabs.lzx

Description

A basetabpane is the non-visual container for content in basetabs. Each basetabpane has a corresponding basetab created. Normally, you won't want to extend this class. If you want a consistent background across all basetabpanes, you can add a background to your basetabscontent component. If you want a different background for each basetabpane, you could do that in the content placed inside of your basetabpane.

Be aware that the content of basetabpane is initstage="late" . You can override this by declaring an initstage on a specific subclass or instance of basetabpane.

            <basetabpane initstage="normal">
              <!-- ..content... -->
            </basetabpane>
            
[Note] Note
The parent of a basetabpane is basetabs, but its immediate parent is the default placement of the basetabscontent.

Example 25. parent and immediate parent of basetabpane

            <canvas width="500" height="140" debug="true">
              <debug x="150" y="10"/>
              
              <include href="base"/>
            
              <class name="aquatab" extends="basetab" width="40" height="20" bgcolor="aqua">
                <text>tab</text>
              </class>
              
              <class name="borderedtabscontent" extends="basetabscontent" bgcolor="black">
                <attribute name="defaultplacement" value="borderedcontent" type="string"/>
                <view name="borderedcontent"
                      x="${parent.parent.bordersize}"
                      y="${parent.parent.bordersize}"
                      width="${parent.width-(2*parent.parent.bordersize)}"
                      height="${parent.height-(2*parent.parent.bordersize)}"
                      clip="true" bgcolor="red"/>
              </class>
            
              <basetabs x="10" y="10" bordersize="3" 
                        tabclass="aquatab" 
                        contentclass="borderedtabscontent">
                <basetabpane name="one">
                  <handler name="onvisible" args="isvisible">
                    if (isvisible) {
                      Debug.write("parent: " + parent);
                      Debug.write("immediate parent: " + immediateparent);
                    }
                  </handler>
                  <text>one</text>
                </basetabpane>
                <basetabpane>
                  <text>two</text>
                </basetabpane>
                <basetabpane>
                  <text height="${parent.height}" width="${parent.width}" 
                        bgcolor="green">
                    three
                  </text>
                </basetabpane>
              </basetabs>
            </canvas>
            

The basetabpane for basetabs. If width and height are not set, all basetabpanes will resize themselves to largest basetabpane or the width of the basetabsbar, whichever is larger. The content of the basetabpane is initstage late. You can override this value by setting initstage late on basetabpane.

Superclass Chain

node (LzNode) » view (LzView) » basecomponent » basetabpane

Known Subclasses

Known Direct Subclasses: tabpane

Details

Properties (9)

datacontrolsvisibility
<attribute name="datacontrolsvisibility" value="false" />
public var datacontrolsvisibility;
If a datapath tag is declared, this attribute will be passed to the datapath when it's created. Default is false.
inset_bottom
<attribute name="inset_bottom" type="number" value="${parent.inset_bottom}" />
public var inset_bottom : Number;
Bottom inset for basetabpane in tabs content. Default is basetabs's inset_bottom.
inset_left
<attribute name="inset_left" type="number" value="${parent.inset_left}" />
public var inset_left : Number;
Left inset for basetabpane in tabs content. Default is basetabs's inset_left.
inset_right
<attribute name="inset_right" type="number" value="${parent.inset_right}" />
public var inset_right : Number;
Right inset for basetabpane in tabs content. Default is basetabs's inset_right.
inset_top
<attribute name="inset_top" type="number" value="${parent.inset_top}" />
public var inset_top : Number;
Top inset for basetabpane in tabs content. Default is basetabs's inset_top.
selected
<attribute name="selected" type="boolean" value="false" />
public var selected : Boolean;
If a basetabpane is selected, then it will be shown. Its associated tab will be also be selected.
tab
<attribute name="tab" type="expression" value="null" />
public read-only var tab : Object;
The tab associated with this basetabpane.
tabclass
<attribute name="tabclass" type="string" />
public final var tabclass : String;
The tabclass to use to instantiate its associated tab. This overrides the basetabs tabclass. Leave undefined here so that basetabs can have it.
text
<attribute name="text" type="text" value="tab" />
public var text : String;
Text value for tab. Default is 'tab'.

LZX Synopsis

<class name="basetabpane" extends=" basecomponent ">
  <attribute name=" datacontrolsvisibility " value="false" />
  <attribute name=" inset_bottom " type="number" value="${parent.inset_bottom}" />
  <attribute name=" inset_left " type="number" value="${parent.inset_left}" />
  <attribute name=" inset_right " type="number" value="${parent.inset_right}" />
  <attribute name=" inset_top " type="number" value="${parent.inset_top}" />
  <attribute name=" selected " type="boolean" value="false" />
  <attribute name=" tab " type="expression" value="null" />
  <attribute name=" tabclass " type="string" />
  <attribute name=" text " type="text" value="tab" />
</class>

JavaScript Synopsis

public basetabpane extends  basecomponent  {
  public var datacontrolsvisibility ;
  public var inset_bottom  : Number;
  public var inset_left  : Number;
  public var inset_right  : Number;
  public var inset_top  : Number;
  public var selected  : Boolean;
  public read-only var tab  : Object;
  public final var tabclass  : String;
  public var text  : String;
}