CheckBox
Since: BlackBerry 10.0.0
#include <bb/cascades/CheckBox>
A checkbox control with two states: checked or unchecked.
The checkbox can also have optional text beside it. You can use this text to describe the purpose of the checkbox or the option that it represents.
To toggle the state of a checkbox, the user can touch anywhere inside the control, including its text.
The visual appearance of the checkbox is predefined and cannot be changed. The optional text is always left-aligned and has predefined font, font size, and color. The checkbox itself is right-aligned.

Here's how to create a checkbox and set the text property in C++:
CheckBox *checkbox1 = CheckBox::create(); checkbox1->setText("Simple check box");Here's how to use the builder pattern to create a checkbox in C++:
CheckBox *checkbox2 = CheckBox::create() .text("Simple check box");Here's how to create a checkbox in QML:
CheckBox { id: checkBox1 checked: true }The size of the checkbox behaves as follows:
If there is no text beside the checkbox (the text property is null), the width is fixed and the properties Control::preferredWidth, Control::minWidth, and Control::maxWidth are not used.
If there is text beside the checkbox (the text property is not null), the default behavior of the width is to fill the width of the parent. The width also has a device-dependent minimum limit to ensure that at least a small portion of text along with the checkbox is shown when layout space is limited.
The height is fixed and the properties Control::preferredHeight, Control::minHeight, and Control::maxHeight are not used.
Overview
Inheritance
QML properties
text | : QString |
accessibility | : bb::cascades::AbstractA11yObject [read-only]![]() |
accessibilityMode | : bb::cascades::A11yMode::Type![]() |
attachedObjects | : QDeclarativeListProperty< QObject > [read-only]![]() |
keyListeners | : QDeclarativeListProperty [read-only]![]() |
bottomMargin | : float![]() |
bottomMarginSet | : bool [read-only]![]() |
bottomPadding | : float![]() |
builtInShortcutsEnabled | : bool![]() |
checked | : bool![]() |
contextMenuHandler | : bb::cascades::ContextMenuHandler![]() |
enabled | : bool![]() |
focusAutoShow | : bb::cascades::FocusAutoShow::Type![]() |
focused | : bool [read-only]![]() |
focusPolicy | : bb::cascades::FocusPolicy::Type![]() |
focusRetentionPolicyFlags | : bb::cascades::FocusRetentionPolicy::Types![]() |
horizontalAlignment | : bb::cascades::HorizontalAlignment::Type![]() |
implicitLayoutAnimationsEnabled | : bool![]() |
inputRoute | : bb::cascades::InputRouteProperties [read-only]![]() |
layoutProperties | : bb::cascades::LayoutProperties![]() |
leftMargin | : float![]() |
leftMarginSet | : bool [read-only]![]() |
leftPadding | : float![]() |
locallyFocused | : bool![]() |
margin | : bb::cascades::Spacings [read-only]![]() |
maxHeight | : float![]() |
maxWidth | : float![]() |
minHeight | : float![]() |
minWidth | : float![]() |
navigation | : bb::cascades::Navigation [read-only]![]() |
objectName | : QString![]() |
opacity | : float![]() |
overlapTouchPolicy | : bb::cascades::OverlapTouchPolicy::Type![]() |
parent | : QObject [read-only]![]() |
pivotX | : float![]() |
pivotY | : float![]() |
preferredHeight | : float![]() |
preferredHeightSet | : bool [read-only]![]() |
preferredWidth | : float![]() |
preferredWidthSet | : bool [read-only]![]() |
rightMargin | : float![]() |
rightMarginSet | : bool [read-only]![]() |
rightPadding | : float![]() |
rotationZ | : float![]() |
scaleX | : float![]() |
scaleY | : float![]() |
topMargin | : float![]() |
topMarginSet | : bool [read-only]![]() |
topPadding | : float![]() |
touchPropagationMode | : bb::cascades::TouchPropagationMode::Type![]() |
translationX | : float![]() |
translationY | : float![]() |
ui | : bb::cascades::UIConfig [read-only]![]() |
verticalAlignment | : bb::cascades::VerticalAlignment::Type![]() |
visible | : bool![]() |
QML signals
Properties Index
Public Functions Index
CheckBox (Container *parent=0) | |
virtual | ~CheckBox () |
Q_SLOT void | resetText () |
Q_SLOT void | setText (const QString &text) |
QString | text () const |
bb::cascades::AbstractA11yObject * | accessibility () const ![]() |
bb::cascades::A11yMode::Type | accessibilityMode () const ![]() |
ActionSet * | actionSetAt (int index) const ![]() |
int | actionSetCount () const ![]() |
void | addActionSet (bb::cascades::ActionSet *actionSet)![]() |
void | addAnimation (AbstractAnimation *animation)![]() |
Q_INVOKABLE void | addEffect (bb::cascades::AbstractEffect *effect)![]() |
void | addEventHandler (AbstractEventHandler *eventHandler)![]() |
void | addGestureHandler (GestureHandler *gestureHandler)![]() |
Q_INVOKABLE void | addKeyListener (bb::cascades::KeyListener *keyListener)![]() |
Q_INVOKABLE void | addShortcut (bb::cascades::AbstractShortcut *shortcut)![]() |
void | addTouchBehavior (TouchBehavior *touchBehavior)![]() |
AbstractAnimation * | animationAt (int index) const ![]() |
int | animationCount () const ![]() |
float | bottomMargin () const ![]() |
float | bottomPadding () const ![]() |
Q_INVOKABLE bool | builtInShortcutsEnabled () const ![]() |
bb::cascades::ContextMenuHandler * | contextMenuHandler () const ![]() |
Q_INVOKABLE void | disableAllShortcuts ()![]() |
Q_INVOKABLE void | enableAllShortcuts ()![]() |
virtual bool | event (QEvent *event)![]() |
bb::cascades::FocusAutoShow::Type | focusAutoShow () const ![]() |
bb::cascades::FocusPolicy::Type | focusPolicy () const ![]() |
bb::cascades::FocusRetentionPolicy::Types | focusRetentionPolicyFlags ()![]() |
bb::cascades::HorizontalAlignment::Type | horizontalAlignment () const ![]() |
bool | implicitLayoutAnimationsEnabled () const ![]() |
bb::cascades::InputRouteProperties * | inputRoute () const ![]() |
bool | isBottomMarginSet () const ![]() |
bool | isChecked () const ![]() |
bool | isEnabled () const ![]() |
bool | isFocused () const ![]() |
bool | isLeftMarginSet () const ![]() |
bool | isLocallyFocused () const ![]() |
bool | isPreferredHeightSet () const ![]() |
bool | isPreferredWidthSet () const ![]() |
bool | isRightMarginSet () const ![]() |
bool | isTopMarginSet () const ![]() |
bool | isVisible () const ![]() |
Q_INVOKABLE bb::cascades::KeyListener * | keyListenerAt (int index) const ![]() |
Q_INVOKABLE int | keyListenerCount () const ![]() |
bb::cascades::LayoutProperties * | layoutProperties () const ![]() |
float | leftMargin () const ![]() |
float | leftPadding () const ![]() |
Q_SLOT void | loseFocus ()![]() |
bb::cascades::Spacings * | margin ()![]() |
float | maxHeight () const ![]() |
float | maxWidth () const ![]() |
float | minHeight () const ![]() |
float | minWidth () const ![]() |
bb::cascades::Navigation * | navigation () const ![]() |
float | opacity () const ![]() |
bb::cascades::OverlapTouchPolicy::Type | overlapTouchPolicy () const ![]() |
float | pivotX () const ![]() |
float | pivotY () const ![]() |
float | preferredHeight () const ![]() |
float | preferredWidth () const ![]() |
bool | removeActionSet (bb::cascades::ActionSet *actionSet)![]() |
void | removeAllActionSets ()![]() |
void | removeAllAnimations ()![]() |
void | removeAllEventHandlers ()![]() |
void | removeAllGestureHandlers ()![]() |
Q_INVOKABLE void | removeAllKeyListeners ()![]() |
Q_INVOKABLE void | removeAllShortcuts ()![]() |
void | removeAllTouchBehaviors ()![]() |
bool | removeAnimation (AbstractAnimation *animation)![]() |
Q_INVOKABLE void | removeEffect (bb::cascades::AbstractEffect *effect)![]() |
bool | removeEventHandler (AbstractEventHandler *eventHandler)![]() |
bool | removeGestureHandler (GestureHandler *gestureHandler)![]() |
Q_INVOKABLE bool | removeKeyListener (bb::cascades::KeyListener *keyListener)![]() |
Q_INVOKABLE bool | removeShortcut (bb::cascades::AbstractShortcut *shortcut)![]() |
bool | removeTouchBehavior (TouchBehavior *touchBehavior)![]() |
Q_SLOT void | requestFocus ()![]() |
Q_SLOT void | resetAccessibilityMode ()![]() |
Q_SLOT void | resetBottomMargin ()![]() |
Q_SLOT void | resetBottomPadding ()![]() |
Q_INVOKABLE void | resetBuiltInShortcutsEnabled ()![]() |
Q_SLOT void | resetChecked ()![]() |
Q_SLOT void | resetContextMenuHandler ()![]() |
Q_SLOT void | resetEnabled ()![]() |
Q_SLOT void | resetFocusAutoShow ()![]() |
Q_SLOT void | resetFocusPolicy ()![]() |
Q_SLOT void | resetFocusRetentionPolicyFlags ()![]() |
Q_SLOT void | resetHorizontalAlignment ()![]() |
Q_SLOT void | resetImplicitLayoutAnimationsEnabled ()![]() |
Q_SLOT void | resetLayoutProperties ()![]() |
Q_SLOT void | resetLeftMargin ()![]() |
Q_SLOT void | resetLeftPadding ()![]() |
Q_SLOT void | resetLocallyFocused ()![]() |
Q_SLOT void | resetMaxHeight ()![]() |
Q_SLOT void | resetMaxWidth ()![]() |
Q_SLOT void | resetMinHeight ()![]() |
Q_SLOT void | resetMinWidth ()![]() |
Q_SLOT void | resetOpacity ()![]() |
Q_SLOT void | resetOverlapTouchPolicy ()![]() |
Q_SLOT void | resetPivot ()![]() |
Q_SLOT void | resetPivotX ()![]() |
Q_SLOT void | resetPivotY ()![]() |
Q_SLOT void | resetPreferredHeight ()![]() |
Q_SLOT void | resetPreferredSize ()![]() |
Q_SLOT void | resetPreferredWidth ()![]() |
Q_SLOT void | resetRightMargin ()![]() |
Q_SLOT void | resetRightPadding ()![]() |
Q_SLOT void | resetRotationZ ()![]() |
Q_SLOT void | resetScale ()![]() |
Q_SLOT void | resetScaleX ()![]() |
Q_SLOT void | resetScaleY ()![]() |
Q_SLOT void | resetTopMargin ()![]() |
Q_SLOT void | resetTopPadding ()![]() |
Q_SLOT void | resetTouchPropagationMode ()![]() |
Q_SLOT void | resetTranslation ()![]() |
Q_SLOT void | resetTranslationX ()![]() |
Q_SLOT void | resetTranslationY ()![]() |
Q_SLOT void | resetVerticalAlignment ()![]() |
Q_SLOT void | resetVisible ()![]() |
float | rightMargin () const ![]() |
float | rightPadding () const ![]() |
float | rotationZ () const ![]() |
float | scaleX () const ![]() |
float | scaleY () const ![]() |
Q_SLOT void | setAccessibilityMode (bb::cascades::A11yMode::Type accessibilityMode)![]() |
Q_SLOT void | setBottomMargin (float bottomMargin)![]() |
Q_SLOT void | setBottomPadding (float bottomPadding)![]() |
Q_INVOKABLE void | setBuiltInShortcutEnabled (bb::cascades::SystemShortcuts::Type type, bool enabled)![]() |
Q_SLOT void | setBuiltInShortcutsEnabled (bool enabled)![]() |
Q_SLOT void | setChecked (bool checked)![]() |
void | setContextMenuHandler (bb::cascades::ContextMenuHandler *contextMenuHandler)![]() |
Q_SLOT void | setEnabled (bool enabled)![]() |
Q_SLOT void | setFocusAutoShow (const bb::cascades::FocusAutoShow::Type focusAutoShow)![]() |
Q_SLOT void | setFocusPolicy (const bb::cascades::FocusPolicy::Type focusPolicy)![]() |
Q_SLOT void | setFocusRetentionPolicyFlags (bb::cascades::FocusRetentionPolicy::Types policy)![]() |
Q_SLOT void | setHorizontalAlignment (bb::cascades::HorizontalAlignment::Type horizontalAlignment)![]() |
Q_SLOT void | setImplicitLayoutAnimationsEnabled (bool enable)![]() |
Q_SLOT void | setLayoutProperties (bb::cascades::LayoutProperties *layoutProperties)![]() |
Q_SLOT void | setLeftMargin (float leftMargin)![]() |
Q_SLOT void | setLeftPadding (float leftPadding)![]() |
Q_SLOT void | setLocallyFocused (bool locallyFocused)![]() |
Q_SLOT void | setMaxHeight (float maxHeight)![]() |
Q_SLOT void | setMaxWidth (float maxWidth)![]() |
Q_SLOT void | setMinHeight (float minHeight)![]() |
Q_SLOT void | setMinWidth (float minWidth)![]() |
void | setObjectName (const QString &name)![]() |
Q_SLOT void | setOpacity (float opacity)![]() |
Q_SLOT void | setOverlapTouchPolicy (bb::cascades::OverlapTouchPolicy::Type policy)![]() |
Q_SLOT void | setPivot (float pivotX, float pivotY)![]() |
Q_SLOT void | setPivotX (float pivotX)![]() |
Q_SLOT void | setPivotY (float pivotY)![]() |
Q_SLOT void | setPreferredHeight (float preferredHeight)![]() |
Q_SLOT void | setPreferredSize (float preferredWidth, float preferredHeight)![]() |
Q_SLOT void | setPreferredWidth (float preferredWidth)![]() |
Q_SLOT void | setRightMargin (float rightMargin)![]() |
Q_SLOT void | setRightPadding (float rightPadding)![]() |
Q_SLOT void | setRotationZ (float rotationZ)![]() |
Q_SLOT void | setScale (float scaleX, float scaleY)![]() |
Q_SLOT void | setScale (float scaleXY)![]() |
Q_SLOT void | setScaleX (float scaleX)![]() |
Q_SLOT void | setScaleY (float scaleY)![]() |
Q_SLOT void | setTopMargin (float topMargin)![]() |
Q_SLOT void | setTopPadding (float topPadding)![]() |
Q_SLOT void | setTouchPropagationMode (bb::cascades::TouchPropagationMode::Type mode)![]() |
Q_SLOT void | setTranslation (float translationX, float translationY)![]() |
Q_SLOT void | setTranslationX (float translationX)![]() |
Q_SLOT void | setTranslationY (float translationY)![]() |
Q_SLOT void | setVerticalAlignment (bb::cascades::VerticalAlignment::Type verticalAlignment)![]() |
Q_SLOT void | setVisible (bool visible)![]() |
Q_INVOKABLE bb::cascades::AbstractShortcut * | shortcutAt (int index) const ![]() |
Q_INVOKABLE int | shortcutCount () const ![]() |
virtual Q_INVOKABLE QString | toDebugString () const ![]() |
float | topMargin () const ![]() |
float | topPadding () const ![]() |
TouchPropagationMode::Type | touchPropagationMode () const ![]() |
float | translationX () const ![]() |
float | translationY () const ![]() |
Q_INVOKABLE bb::cascades::UIConfig * | ui () const ![]() |
bb::cascades::VerticalAlignment::Type | verticalAlignment () const ![]() |
Protected Functions Index
Only has inherited protected functions
BaseObject (QObject *parent=0)![]() | |
virtual void | connectNotify (const char *signal)![]() |
virtual void | disconnectNotify (const char *signal)![]() |
Signals Index
void | textChanged (QString text) |
void | accessibilityModeChanged (bb::cascades::A11yMode::Type newAccessibilityMode)![]() |
void | actionSetAdded (bb::cascades::ActionSet *actionSet)![]() |
void | actionSetRemoved (bb::cascades::ActionSet *actionSet)![]() |
void | bottomMarginChanged (float bottomMargin)![]() |
void | bottomMarginSetChanged (bool isSet)![]() |
void | bottomPaddingChanged (float bottomPadding)![]() |
void | builtInShortcutsEnabledChanged (bool builtInShortcutsEnabled)![]() |
void | checkedChanged (bool checked)![]() |
void | contextMenuHandlerChanged (bb::cascades::ContextMenuHandler *contextMenuHandler)![]() |
void | creationCompleted ()![]() |
void | enabledChanged (bool enabled)![]() |
void | focusAutoShowChanged (bb::cascades::FocusAutoShow::Type newFocusAutoShow)![]() |
void | focusedChanged (bool focused)![]() |
void | focusPolicyChanged (bb::cascades::FocusPolicy::Type newFocusPolicy)![]() |
void | focusRetentionPolicyFlagsChanged (bb::cascades::FocusRetentionPolicy::Types policy)![]() |
void | horizontalAlignmentChanged (bb::cascades::HorizontalAlignment::Type newHorizontalAlignment)![]() |
void | implicitLayoutAnimationsEnabledChanged (bool implicitLayoutAnimationsEnabled)![]() |
void | layoutPropertiesChanged (bb::cascades::LayoutProperties *layoutProperties)![]() |
void | leftMarginChanged (float leftMargin)![]() |
void | leftMarginSetChanged (bool isSet)![]() |
void | leftPaddingChanged (float leftPadding)![]() |
void | locallyFocusedChanged (bool newLocallyFocused)![]() |
void | maxHeightChanged (float maxHeight)![]() |
void | maxWidthChanged (float maxWidth)![]() |
void | minHeightChanged (float minHeight)![]() |
void | minWidthChanged (float minWidth)![]() |
void | objectNameChanged (const QString &objectName)![]() |
void | opacityChanged (float opacity)![]() |
void | opacityChanging (float opacity)![]() |
void | overlapTouchPolicyChanged (bb::cascades::OverlapTouchPolicy::Type newOverlapTouchPolicy)![]() |
void | pivotXChanged (float pivotX)![]() |
void | pivotYChanged (float pivotY)![]() |
void | preferredHeightChanged (float preferredHeight)![]() |
void | preferredHeightSetChanged (bool isSet)![]() |
void | preferredWidthChanged (float preferredWidth)![]() |
void | preferredWidthSetChanged (bool isSet)![]() |
void | rightMarginChanged (float rightMargin)![]() |
void | rightMarginSetChanged (bool isSet)![]() |
void | rightPaddingChanged (float rightPadding)![]() |
void | rotationZChanged (float rotationZ)![]() |
void | rotationZChanging (float rotationZ)![]() |
void | scaleXChanged (float scaleX)![]() |
void | scaleXChanging (float scaleX)![]() |
void | scaleYChanged (float scaleY)![]() |
void | scaleYChanging (float scaleY)![]() |
void | topMarginChanged (float topMargin)![]() |
void | topMarginSetChanged (bool isSet)![]() |
void | topPaddingChanged (float topPadding)![]() |
void | touch (bb::cascades::TouchEvent *event)![]() |
void | touchCapture (bb::cascades::TouchEvent *event)![]() |
void | touchEnter (bb::cascades::TouchEnterEvent *event)![]() |
void | touchExit (bb::cascades::TouchExitEvent *event)![]() |
void | touchPropagationModeChanged (bb::cascades::TouchPropagationMode::Type newTouchPropagationMode)![]() |
void | translationXChanged (float translationX)![]() |
void | translationXChanging (float translationX)![]() |
void | translationYChanged (float translationY)![]() |
void | translationYChanging (float translationY)![]() |
void | verticalAlignmentChanged (bb::cascades::VerticalAlignment::Type newVerticalAlignment)![]() |
void | visibleChanged (bool visible)![]() |
Properties
bb::cascades::AbstractA11yObject
Defines the control's accessibility object.
BlackBerry 10.2.0
bb::cascades::A11yMode::Type
The accessibility mode for the control.
This property defines how the control and its subtree will be exposed to assistive technologies. The default value is Default which means that the framework automates accessibility mode based on accessible information and context. Typically accessibility information is assumed to be available, unless any parent is configured with accessibilityMode = Collapsed.
When accessibility information is available, the accessibility property will be used to define the accessibility properties.
BlackBerry 10.2.0
QDeclarativeListProperty< QObject >
A hierarchical list of the UIObject's attached objects.
BlackBerry 10.0.0
QDeclarativeListProperty
A list of ActionSet object that are displayed in the control's context menu.
A list of key listeners attached to this control.
A list of shortcuts that can be triggered via user actions.
These action sets are displayed in the Context Menu for this control. When the context menu is opened, the first ActionSet object in the list is displayed initially, and the user can cycle through them in the order that they are added to the control.
BlackBerry 10.0.0
BlackBerry 10.1.0
BlackBerry 10.1.0
float
The bottom margin for the control.
Margins are positive values that specify the space around a control.
How the margin is actually used depends on how the control is laid out within it's parent container. When the control is laid out in a StackLayout, the margin is considered between the siblings in the layout direction. In that case the distance between two children in the layout direction will be the largest margin of the two adjacent margins in the layout direction.
BlackBerry 10.0.0
bool
Indicates whether the bottomMargin of a control is set.
If true the bottom Margin has been set on a control, if false the bottomMargin is not set. By default, bottomMargin is false, meaning that the control will use control-specific default
BlackBerry 10.0.0
float
The bottom padding for the control.
bool
Enables or disables all Control's built-in shortcuts.
This property is used when all Control's built-in shortcuts should be enabled or disabled. Cotrol's built-in shortcuts are shortcuts like Navigation shortcuts in ScrollView and ListView.
BlackBerry 10.2.0
bool
The state of this toggle control.
BlackBerry 10.0.0
bool
Indicates whether the control is enabled.
When a control is disabled, it does not respond to user input. The disabled control continues to receive events, but does not process them. Changing the enabled state may also affect the appearance of the control.
If true the control is enabled, if false it's disabled.
BlackBerry 10.0.0
bb::cascades::FocusAutoShow::Type
Indicates whether a control should automatically be made visible when it receives focus.
The default focusAutoShow value is Default.
BlackBerry 10.0.0
bool
Indicates whether the control is focused.
If true the control is focused, if false it's not focused.
BlackBerry 10.0.0
bb::cascades::FocusPolicy::Type
Indicates whether this control is focusable or not and what kind of user input focus can be received (touch and/or key).
The default focusPolicy value is None. A disabled Control can not have focus.
BlackBerry 10.0.0
bb::cascades::FocusRetentionPolicy::Types
The focus retention policy that determines the conditions under which a control loses focus.
Normally, a control loses focus whenever a user touches outside of the control or on another control, or when scrolling a ListView (may differ from device to device). However, it may be convenient at times to retain focus. This property makes it possible to specify the conditions under which the control should lose focus and when it shouldn't. The property only affects focus changes initiated by user interaction, not when programmatically changing focus (i.e. by calling requestFocus() on a control).
Here's an example of how to set the focus retention policy in QML:
TextArea { focusRetentionPolicyFlags: FocusRetentionPolicy.LoseToNonFocusable | FocusRetentionPolicy.LoseOnScroll text: "Loses Focus" }
BlackBerry 10.0.0
bb::cascades::HorizontalAlignment::Type
Specifies the HorizontalAlignment for the control.
The default alignment is HorizontalAlignment::Left.
BlackBerry 10.0.0
bool
Enables or disables implicit animations when layout-related properties for a Control are changed.
This property affects implicit animations on the following properties for a control.
positioning in a layout, including x and y coordinates and horizontal and vertical alignment
preferred height and width
maximum and minimum height and width
margins and padding
The default is true meaning that implicit animations are enabled.
For VisualNode properties, you can customize implicit animations by using ImplicitAnimationController. These properties include translation, rotation, scaling, pivoting, and opacity.
BlackBerry 10.0.0
bb::cascades::InputRouteProperties
Defines this control's role in the propagation of input events.
Container { inputRoute.primaryKeyTarget: true Label { id: myLabel text: "Press a" } shortcuts: [ Shortcut { key: "a" onTriggered: { myLabel.text = "Shortcut triggered!" } } ] }C++ usage:
Container *pContainer = new Container(); pContainer->inputRoute()->setPrimaryKeyTarget(true); // Shortcuts on pContainer can now trigger.C++ usage (with builder):
Container *pContainer = Container::create() .primaryKeyTarget(true) .add(Label::create() .text("My container will get key events!"));
BlackBerry 10.1.0
bb::cascades::LayoutProperties
The layout properties for the control.
The layoutProperties property specifies how the parent container should position and size the control. The layoutProperties object must match the Layout type of the container. For example, if the parent container uses a stack layout, the layoutProperties should be a StackLayoutProperties object.
By default, a control's layoutProperties is 0. If the layoutProperties for a control is not explicitly set, the parent container uses the default layout properties for the type of layout that it's using.
BlackBerry 10.0.0
float
The left margin for the control.
Margins are positive values that specify the space around a control.
How the margin is actually used depends on how the control is laid out within its parent container. When the control is laid out in a StackLayout, the margin is considered between the siblings in the layout direction. In that case the distance between two children in the layout direction will be the largest margin of the two adjacent margins in the layout direction.
The default value depends on the actual control. For the Container class the value is 0.0.
BlackBerry 10.0.0
bool
Indicates whether the leftMargin of a control is set.
If true the left margin has been set on a control, if false the leftMargin is not set. By default, leftMargin is false, meaning that the control will use control-specific default
BlackBerry 10.0.0
float
The left padding for the control.
The default left padding is 0.
Negative padding values are supported in the ListView control, for all other controls negative padding is undefined.
BlackBerry 10.0.0
bool
Indicates whether the control has local focus.
Each focus scope keeps track of a local focus. The local focus can be used to set which control should get focus when navigating to the focus scope. If the focus scope contains the actual focus when setting local focus to true, actual will be requested by this control.
BlackBerry 10.3.1
bb::cascades::Spacings
Full margins for the control.
Margins are positive values that specify the space around a control.
How the margin is actually used depends on how the control is laid out within its parent, both Containers, ListViews and ScrollViews (and other controls that have children) can use the information to position their children.
For example when the control is laid out in a StackLayout, the margin is considered both for the distance from the side of the parent and between the siblings in the layout direction. In such a case the distance between two children in the layout direction will be the largest margin of the two adjacent children in the layout direction.
For DockLayout the margin values will affect only the position from the side of the parent to the child.
The Margin group property is not created until it's needed, default value for the margins of a control are undefined which means that the containing parent will decide. In the margins group property this is specified by the float values defaulting to NAN.
This is a new API that will replace the current version using topMargin et.c. but until the support is fully implemented in all Containing Controls, the old way is not deprecated. I the current version the difference between using the margin group property and separate margin properties (topMargin et.c.) is that the group property can be used both for the space between siblings in a StackLayout and StackListLayout but that the Layouts in a container also use it to position the children from the inside of the container. Lessening the need for extra layers of containers with padding.
BlackBerry 10.3.0
float
The maximum height for the control.
The max height is a positive value used by the layout system to position the control.
The default maxHeight is infinitely large (no limit). The control can determine the effective maxHeight of a control by combining the maxHeight with the size of contents of the control.
BlackBerry 10.0.0
float
The maximum width for the control.
The max width is a positive value used by the layout system to position the control.
The default maxWidth is infinitely large (no limit). The control can determine the effective maxWidth of a control by combining the maxWidth with the size of contents of the control.
BlackBerry 10.0.0
float
The minimum height for the control.
The min height is a positive value used by the layout system to position the control.
The default minHeight for a control is 0.0. The control can determine the effective minHeight of a control by combining the minHeight with the size of contents of the control.
BlackBerry 10.0.0
float
The minimum width for the control.
The min width is a positive value used by the layout system to position the control.
The default minWidth for a control is 0.0. The control can determine the effective minWidth of a control by combining the minWidth with the size of contents of the control.
BlackBerry 10.0.0
QString
This property is overridden from QObject.
QObject::objectName().
BlackBerry 10.0.0
float
The opacity of the visual node.
A value between 0.0 (transparent) and 1.0 (opaque). This is the local opacity of the visual node, i.e. not taking the ancestor opacities into account. The default opacity is 1.0 (opaque).
BlackBerry 10.0.0
bb::cascades::OverlapTouchPolicy::Type
Determines whether the visual node will prevent underlying (spatially overlapped) nodes from partaking in touch event propagation.
If overlap touch policy is OverlapTouchPolicy::Deny, overlapped nodes will be excluded from touch propagation at an early stage during the processing of touch input. This means a scene with many layers of visual nodes with overlap touch policy set to OverlapTouchPolicy::Allow, may affect touch performance negatively.
The policy has no effect if propagation mode is TouchPropagationMode::None for the same visual node.
BlackBerry 10.0.0
QObject
A read-only property that represents this object's parent.
The parent of an object is specified using QObject::setParent(QObject*). The purpose of the property is to expose the object's parent to QML.
This property is read-only to prevent modifications from QML, where typically the parent is declaratively set. In C++ code, the parent can be explicitly set using QObject::setParent(QObject*), or implicitly set by adding it to a visual container.
The default value of this property is 0.
BlackBerry 10.0.0
float
The position of pivot point of the visual node along the x-axis.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
float
The position of pivot point of the visual node along the y-axis.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
float
The preferred height of the control.
The preferred height is a positive value used by the Layout of the parent Container to position the control. If the preferred height for a control is not set, the parent container ignores this value and uses the control-specific default height. See the API reference for a specific control for more details about its default height. You can check whether the preferredHeight of a control is set by calling isPreferredHeightSet().
However, just because the preferred height has been set on a control, does not mean it is being used. The preferred height is ignored by the parent container if it is smaller than the minimum size allowed for that control.
BlackBerry 10.0.0
bool
Indicates whether the preferredHeight of a control is set.
If true the preferred height has been set on a control, if false the preferred height is not set. By default, preferredHeightSet is false, meaning that the parent container ignores the preferred height and uses the control-specific default instead.
BlackBerry 10.0.0
float
The preferred width of the control.
The preferred width is a positive value used by the Layout of the parent Container to position the control. If the preferred width for a control is not set (or was set but has since been reset), the parent container ignores this value and uses the control-specific default width. See the API reference for a specific control for more details about its default width. You can check whether the preferredWidth of a control is set by calling isPreferredWidthSet().
However, just because the preferred width has been set on a control, does not mean it is being used. The preferred width is ignored by the parent container if it is smaller than the minimum size allowed for that control.
BlackBerry 10.0.0
bool
Indicates whether the preferredWidth of a control is set.
If true the preferred width has been set on a control, if false the preferred width is not set. By default, preferredWidthSet is false, meaning that the parent container ignores the preferred width and uses the control-specific default instead.
BlackBerry 10.0.0
float
The right margin for the control.
Margins are positive values that specify the space around a control.
How the margin is actually used depends on how the control is laid out within it's parent container. When the control is laid out in a StackLayout, the margin is considered between the siblings in the layout direction. In that case the distance between two children in the layout direction will be the largest margin of the two adjacent margins in the layout direction.
The default value depends on the actual control. For the Container class the value is 0.0.
BlackBerry 10.0.0
bool
Indicates whether the rightMargin of a control is set.
If true the right margin has been set on a control, if false the rightMargin is not set. By default, rightMargin is false, meaning that the control will use control-specific default
BlackBerry 10.0.0
float
The right padding for the control.
The default right padding is 0.
Negative padding values are supported in the ListView control, for all other controls negative padding is undefined.
BlackBerry 10.0.0
float
The rotation of the visual node around the z-axis in degrees.
The visual node is rotated around the z-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default rotation is 0.0 degrees.
BlackBerry 10.0.0
float
The scale factor of the visual node along the x-axis.
The visual node is scaled along the x-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
float
The scale factor of the visual node along the y-axis.
The visual node is scaled along the y-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
float
The top margin for the control.
Margins are positive values that specify the space around a control.
How the margin is actually used depends on how the control is laid out within it's parent container. When the control is laid out in a StackLayout, the margin is considered between the siblings in the layout direction. In that case the distance between two children in the layout direction will be the largest margin of the two adjacent margins in the layout direction.
The default value depends on the actual control. For the Container class the value is 0.0.
BlackBerry 10.0.0
bool
Indicates whether the topMargin of a control is set.
If true the top Margin has been set on a control, if false the topMargin is not set. By default, topMargin is false, meaning that the control will use control-specific default
BlackBerry 10.0.0
float
The top padding for the control.
bb::cascades::TouchPropagationMode::Type
The touch propagation mode for the visual node.
This property controls how the visual node and its subtree partakes in touch event propagation. There are three possible modes, as defined by TouchPropagationMode::Type:
TouchPropagationMode::Full means that touch events will be fully propagated to the visual node and it's subtree.
TouchPropagationMode::None means no touch events will be propagated to the visual node or its subtree. The subtree is practically invisible to the touch system.
TouchPropagationMode::PassThrough means touch events will not be handled by the visual node itself, but its subtree will get touch events as usual.
The default propagation mode is TouchPropagationMode::Full.
BlackBerry 10.0.0
float
The translation of the visual node along the x-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
float
The translation of the visual node along the y-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
bb::cascades::UIConfig
An object that gives access to unit conversion routines.
// Size using design units Container { preferredWidth: ui.du(12) preferredHeight: ui.du(5) } // Size using design units, snap to whole pixels Container { preferredWidth: ui.sdu(13.5) preferredHeight: ui.sdu(7.5) } // Size using absolute pixel values Container { preferredWidth: ui.px(150) preferredHeight: ui.px(50) }C++ use:
Container *container1 = Container::create().background(Color::Red); UIConfig *ui = container1->ui(); container1->setPreferredWidth(ui->du(12)); container1->setPreferredHeight(ui->du(5)); Container *container2 = Container::create().background(Color::Green); container2->setPreferredWidth(ui->sdu(13.5)); container2->setPreferredHeight(ui->sdu(7.5)); Container *container3 = Container::create().background(Color::Blue); container3->setPreferredWidth(ui->px(150)); container3->setPreferredHeight(ui->sdu(50));
Blackberry 10.3.0
bb::cascades::VerticalAlignment::Type
Specifies the VerticalAlignment for the control.
The default alignment is VerticalAlignment::Top.
BlackBerry 10.0.0
bool
Whether the visual node is laid out or not.
If the visible property is set to false, the visual node is neither laid out nor rendered. The default visible value is true.
Important: Setting the visible value to false is not the same as setting opacity to 0.0f (transparent). While a transparent node is still laid out taking up room in the scene, a node that is not visible, will neither be rendered nor laid out inside the scene. It will behave as if it was removed from the scene without actually been unlinked from the scene graph. No touch events will be sent to the node if the visible value is false. This a convenient way of removing nodes to optimize the performance of the scene without is actually unlinking them. It is highly recommended to use this property to hide visual nodes whenever possible.
BlackBerry 10.0.0
Public Functions
Constructs a CheckBox with the specified parent container.
If the specified parent is not 0, the ownership of the constructed checkbox is transferred to the parent.
Parameters | |
---|---|
parent |
The parent container, or 0. This parameter is optional. The default is 0 if you don't specify a parent. |
BlackBerry 10.0.0
virtual
Destructor.
BlackBerry 10.0.0
Q_SLOT void
Sets the text to display beside this CheckBox.
When the text is set, the CheckBox resizes itself to fill the width of the parent. The text is left-aligned, and as the checkbox visual is right-aligned this might introduce empty space between the text and the checkbox visual itself, as it will always fill out as much space at it gets.
The width also has a device-dependent minimum limit to ensure that at least a small portion of text along with the checkbox is shown when layout space is limited.
Parameters | |
---|---|
text |
A text string to set as the checkbox text, or QString::Null to display no text. |
BlackBerry 10.0.0
QString
Returns the text that is displayed beside this CheckBox.
A string that represents the checkbox text, or QString::Null if no text is set.
BlackBerry 10.0.0
bb::cascades::AbstractA11yObject * 
Returns the accessibility object.
The accessibility object.
bb::cascades::A11yMode::Type 
Return the current value of the accessibilityMode property.
The A11yMode of the control.
BlackBerry 10.2.0
ActionSet * 
Returns an ActionSet at a specified index.
Ownership of the ActionSet object remains with the control.
Control::contextActions
Parameters | |
---|---|
index |
The index of the ActionSet. |
The requested ActionSet if the index was valid, 0 otherwise.
BlackBerry 10.0.0
int 
Returns the number of ActionSet objects.
Control::contextActions
The number of ActionSet objects.
BlackBerry 10.0.0
void 
Adds an ActionSet to the control.
The control takes ownership of the ActionSet object, since ActionSet objects should not typically be shared. If the ActionSet is 0 or it already belongs to the control, the action set is not added. Once completed, the actionSetAdded() signal is emitted.
Control::contextActions
Parameters | |
---|---|
actionSet |
The ActionSet to add to the Control. |
BlackBerry 10.0.0
void 
Adds an animation to the visual node.
Parameters | |
---|---|
animation |
The animation to add. The ownership of the added animation will be transferred to the visual node. If the added animation was previously added to another visual node, it will be removed from that node and added to (and owned by) this node. |
removeAnimation(), removeAllAnimation(), animationCount(), animationAt()
BlackBerry 10.0.0
Q_INVOKABLE void 
Adds an effect to the visual node.
Parameters | |
---|---|
effect |
The effect to add. The ownership of the added effect will be transferred to the visual node. If the effect was previously assigned to a different node, ownership is transferred to the new node. |
BlackBerry 10.3.1
void 
Adds an event handler to the visual node.
Parameters | |
---|---|
eventHandler |
The event handler to add. The ownership of the added event handler will be transferred to the visual node. If the added event handler was previously added to another visual node, it will be removed from that node and added to (and owned by) this node. |
removeEventHandler(), removeAllEventHandlers(), bb::cascades::EventHandler
BlackBerry 10.3.0
void 
Adds a gesture handler to the visual node.
For example usage, refer to documentation of bb::cascades::GestureHandler.
Parameters | |
---|---|
gestureHandler |
The gesture handler to add. The ownership of the added gesture handler will be transferred to the visual node. If the added gesture handler was previously added to another visual node, it will be removed from that node and added to (and owned by) this node. |
BlackBerry 10.0.0
Q_INVOKABLE void 
Adds a key listener to the Control.
The Control will always take ownership as a key listener should never be shared. If the key listener already belongs to the Control or the key listener is 0, nothing will happen.
Parameters | |
---|---|
keyListener |
The KeyListener to add to the Control. |
BlackBerry 10.1.0
Q_INVOKABLE void 
Adds a shortcut to the Control.
The Control will always take ownership as shortcuts should never be shared. If the shortcut already belongs to the Control or the shortcut is 0, nothing will happen. The order in which shortcuts are added will determine which shortcut will be triggered in case of an overlap.
Parameters | |
---|---|
shortcut |
The AbstractShortcut to add to the Control. |
BlackBerry 10.1.0
void 
Adds a touch behavior to the visual node.
Multiple behaviors can be added, they will get evaluated in parallel.
For example usage, refer to documentation of bb::cascades::TouchBehavior.
Parameters | |
---|---|
touchBehavior |
The touch behavior to add. The ownership of the added touch behavior will be transferred to the visual node. If the added touch behavior was previously added to another visual node, it will be removed from that node and added to (and owned by) this node. |
removeTochBehavior(), removeAllTouchBehaviors(), bb::cascades::TouchBehavior
BlackBerry 10.0.0
AbstractAnimation * 
Returns an animation added at a specified index.
for (int i = 0; i < animationCount(); ++i) { AbstractAnimation* animation = animationAt(i); ... }
Parameters | |
---|---|
index |
The index of the animation to retrieve. It must in the range of [ 0, animationCount() [, otherwise the function will return 0; |
The animation at the specified index; 0 if the index was out of range. The ownership is not changed by this call.
BlackBerry 10.0.0
int 
Returns the number of animations added to the visual node.
for (int i = 0; i < animationCount(); ++i) { AbstractAnimation* animation = animationAt(i); ... }
The number of animations added to the visual node.
BlackBerry 10.0.0
float 
Returns the bottomMargin for the control.
The bottom margin for the control.
BlackBerry 10.0.0
float 
Returns the bottom padding on the control.
The bottom padding.
BlackBerry 10.0.0
Q_INVOKABLE bool 
Returns an builtInShortcutsEnabled property value.
true if builtInShortcutsEnabled property is set to true and false otherwise
BlackBerry 10.2.0
Q_INVOKABLE void 
Disables all shortcuts attached to the Control.
Shortcuts that are attached afterward will use the default enabled state.
BlackBerry 10.1.0
Q_INVOKABLE void 
Enables all shortcuts attached to the Control.
BlackBerry 10.1.0
virtual bool 
Overloaded to implement the event mechanism in Cascades.
If this function is overridden, it must be called by the derived class for events to work properly in Cascades.
Parameters | |
---|---|
event |
The received event. |
True if the received event was recognized and processed, false otherwise.
BlackBerry 10.0.0
bb::cascades::FocusAutoShow::Type 
Returns the focusAutoShow property of the control.
The focusAutoShow state of the control
BlackBerry 10.0.0
bb::cascades::FocusPolicy::Type 
Returns the focusPolicy property of the control.
The focusPolicy state of the control as a FocusPolicy
BlackBerry 10.0.0
bb::cascades::FocusRetentionPolicy::Types 
Gets the focus retention policy.
The policy describes under which condtions the control will lose focus
The focus retention policy for this control.
BlackBerry 10.0.0
bb::cascades::HorizontalAlignment::Type 
Returns the horizontal alignment for the control.
The horizontal alignment for the control.
BlackBerry 10.0.0
bool 
Return the current value of the implicitLayoutAnimationsEnabled property.
If true layout changes will implicitely trigger animations, if false the animations are disabled.
BlackBerry 10.0.0
bb::cascades::InputRouteProperties * 
Returns the input route properties object.
The input route properties object.
BlackBerry 10.1.0
bool 
Indicates whether the bottomMargin of the control is set.
true if the bottom margin is set, false otherwise.
BlackBerry 10.0.0
bool 
Returns the state of this toggle control.
true if this toggle control is checked, false if this toggle control is unchecked.
BlackBerry 10.0.0
bool 
Returns the enabled state of the control.
true if the control is enabled, false otherwise.
BlackBerry 10.0.0
bool 
Returns the focused state of the control.
true if the control is focused, false otherwise.
BlackBerry 10.0.0
bool 
Indicates whether the leftMargin of the control is set.
true if the left margin is set, false otherwise.
BlackBerry 10.0.0
bool 
Returns the locallyFocused state of the control.
true if the controls locallyFocused property is set, false otherwise.
BlackBerry 10.3.1
bool 
Indicates whether the preferredHeight of the control is set.
true if the preferred height is set, false otherwise.
BlackBerry 10.0.0
bool 
Indicates whether the preferredWidth of the control is set.
true if the preferred width is set, false otherwise.
BlackBerry 10.0.0
bool 
Indicates whether the rightMargin of the control is set.
true if the right margin is set, false otherwise.
BlackBerry 10.0.0
bool 
Indicates whether the topMargin of the control is set.
true if the top margin is set, false otherwise.
BlackBerry 10.0.0
bool 
Checks whether the visual node is visible or not.
If the visible property is set to false, the visual node is neither laid out nor rendered. The default visible value is true.
Important: Setting the visible value to false is not the same as setting opacity to 0.0f (transparent). While a transparent node is still laid out taking up room in the scene, a node that is not visible, will neither be rendered nor laid out inside the scene. It will behave as if it was removed from the scene without actually been unlinked from the scene graph. No touch events will be sent to the node if the visible value is false. This a convenient way of removing nodes to optimize the performance of the scene without is actually unlinking them. It is highly recommended to use this property to hide visual nodes whenever possible.
BlackBerry 10.0.0
true if the visual node is visible, false otherwise.
BlackBerry 10.0.0
Q_INVOKABLE bb::cascades::KeyListener * 
Returns a key listener at the specified index.
Ownership of the key listener remains with the Control.
Parameters | |
---|---|
index |
The index of the key listener. |
The requested key listener if the index was valid, 0 otherwise.
BlackBerry 10.1.0
Q_INVOKABLE int 
Returns the number of key listeners.
The number of key listeners.
BlackBerry 10.1.0
bb::cascades::LayoutProperties * 
Returns the LayoutProperties object for the control.
Ownership of the LayoutProperties object remains unchanged.
The layout properties for the control.
BlackBerry 10.0.0
float 
Returns the leftMargin for the control.
The left margin for the control.
BlackBerry 10.0.0
float 
Returns the left padding on the control.
The left padding.
BlackBerry 10.0.0
Q_SLOT void 
Called when the control should lose its focus.
If succeeded, the focusedChanged() signal is emitted with false as its parameter.
BlackBerry 10.0.0
bb::cascades::Spacings * 
Returns the margin group property for the control.
The margin property for the control.
BlackBerry 10.3.0
float 
Returns the maxHeight of the control.
The maximum height of the control.
BlackBerry 10.0.0
float 
Returns the maxWidth of the control.
The maximum width of the control.
BlackBerry 10.0.0
float 
Returns the minHeight of the control.
The minimum height of the control.
BlackBerry 10.0.0
float 
Returns the minWidth of the control.
The minimum width of the control.
BlackBerry 10.0.0
float 
Returns the opacity of the visual node.
A value between 0.0 (transparent) and 1.0 (opaque). This is the local opacity of the visual node, i.e. not taking the ancestor opacities into account. The default opacity is 1.0 (opaque).
BlackBerry 10.0.0
A value between between 0.0 (transparent) and 1.0 (opaque).
BlackBerry 10.0.0
bb::cascades::OverlapTouchPolicy::Type 
Returns the overlap touch policy for the visual node.
If overlap touch policy is OverlapTouchPolicy::Deny, overlapped nodes will be excluded from touch propagation at an early stage during the processing of touch input. This means a scene with many layers of visual nodes with overlap touch policy set to OverlapTouchPolicy::Allow, may affect touch performance negatively.
The policy has no effect if propagation mode is TouchPropagationMode::None for the same visual node.
BlackBerry 10.0.0
The overlap touch policy for the visual node.
BlackBerry 10.0.0
float 
Returns the position of pivot point of the visual node along the x-axis.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
The position of pivot point along the x-axis, relative to the center of the visual node.
BlackBerry 10.0.0
float 
Returns the position of pivot point of the visual node along the y-axis.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
The position of pivot point along the y-axis, relative to the center of the visual node.
BlackBerry 10.0.0
float 
Returns the preferredHeight of the control.
To check whether the preferred height is set for a control, call isPreferredHeightSet().
The preferred height of a control as a positive number, or 0 if the preferred width is not set.
BlackBerry 10.0.0
float 
Returns the preferredWidth of the control.
To check whether the preferred width is set for the control, call isPreferredWidthSet().
The preferred width of a control as a positive number, or 0 if the preferred width is not set.
BlackBerry 10.0.0
bool 
Removes an ActionSet from the control.
Once the ActionSet is removed, the control no longer references it, but it is still owned by the control. It is up to the application to either delete the removed ActionSet, transfer its ownership (by setting its parent) to another object or leave it as a child of the control (in which case it will be deleted with the control).
Once completed, the actionSetRemoved() signal is emitted.
Control::contextActions
Parameters | |
---|---|
actionSet |
The actionSet to remove. |
true if the ActionSet was owned by the Control, false otherwise.
BlackBerry 10.0.0
void 
Removes all ActionSet objects from the control and deletes them.
Once completed, the actionSetRemoved() signal is emitted with 0 as its parameter.
Control::contextActions
BlackBerry 10.0.0
void 
Convenience function for removing and deleting all animations added to the visual node.
All animations added to the visual node will be removed and deleted.
removeAnimation(), animationCount(), animationAt(), addAnimation()
BlackBerry 10.0.0
void 
Removes and deletes all event handlers currently added to this visual node.
BlackBerry 10.3.0
void 
Removes and deletes all gesture handlers currently added to this visual node.
BlackBerry 10.0.0
Q_INVOKABLE void 
Removes all of a Control's key listeners and frees up their memory.
BlackBerry 10.1.0
Q_INVOKABLE void 
Removes all of a control's shortcuts and frees up their memory.
BlackBerry 10.1.0
void 
Removes and deletes all touch behaviors currently added to this visual node.
BlackBerry 10.0.0
bool 
Removes an animation from the visual node.
Once the animation is removed, the visual node no longer references it, but it is still owned by the visual node. It is up to the application to either delete the removed animation, transfer its ownership (by setting its parent) to another object or leave it as a child of the visual node (in which case it will be deleted with the visual node).
for (int i = 0; i < animationCount(); ++i) { AbstractAnimation* animation = animationAt(i); removeAnimation(animation); delete animation; }
removeAllAnimation(), animationCount(), animationAt(), addAnimation()
Parameters | |
---|---|
animation |
The animation to remove. |
Returns False of the animation to remove wasn't added to the visual node or if the animation was 0, true otherwise.
BlackBerry 10.0.0
Q_INVOKABLE void 
Removes an effect from the visual node.
Parameters | |
---|---|
effect |
The effect to remove. The ownership of the effect will remain with the node until the effect is either deleted or set as an effect on another node. |
BlackBerry 10.3.1
bool 
Removes a event handler from the visual node.
Once the event handler is removed, the visual node no longer references it, but it is still owned by the visual node. It is up to the application to either delete the removed event handler, transfer its ownership (by setting its parent) to another object or leave it as a child of the visual node (in which case it will be deleted with the visual node).
Parameters | |
---|---|
eventHandler |
The event handler to remove. |
false if the event handler to remove wasn't removed from the visual node or if the event handler was 0, true otherwise.
BlackBerry 10.3.0
bool 
Removes a gesture handler from the visual node.
Once the gesture handler is removed, the visual node no longer references it, but it is still owned by the visual node. It is up to the application to either delete the removed gesture handler, transfer its ownership (by setting its parent) to another object or leave it as a child of the visual node (in which case it will be deleted with the visual node).
Parameters | |
---|---|
gestureHandler |
The gesture handler to remove. |
false if the gesture handler to remove wasn't removed from the visual node or if the gesture handler was 0, true otherwise.
BlackBerry 10.0.0
Q_INVOKABLE bool 
Removes a key listener from the Control.
Once the key listener is removed, the Control no longer references it, but it is still owned by the Control. It is up to the application to either delete the removed key listener, transfer its ownership (by setting its parent) to another object, or leave it as a child of the Control (in which case it will be deleted with the Control).
Parameters | |
---|---|
keyListener |
The KeyListener to remove. |
true if the key listener was owned by the Control, false otherwise.
BlackBerry 10.1.0
Q_INVOKABLE bool 
Removes a shortcut from the Control.
Once the shortcut is removed, the Control no longer references it, but it is still owned by the Control. It is up to the application to either delete the removed shortcut, transfer its ownership (by setting its parent) to another object, or leave it as a child of the Control (in which case it will be deleted with the Control).
Parameters | |
---|---|
shortcut |
The AbstractShortcut to remove. |
true if the shortcut was owned by the Control, false otherwise.
BlackBerry 10.1.0
bool 
Removes a touch behavior from the visual node.
Once the touch behavior is removed, the visual node no longer references it, but it is still owned by the visual node. It is up to the application to either delete the removed touch behavior, transfer its ownership (by setting its parent) to another object or leave it as a child of the visual node (in which case it will be deleted with the visual node).
Parameters | |
---|---|
touchBehavior |
The touch behavior to remove. |
Returns False if the touch behavior to remove wasn't removed from the visual node or if the touch behavior was 0, true otherwise.
BlackBerry 10.0.0
Q_SLOT void 
Requests focus to this control.
When requesting focus for a control, you must ensure that the control is currently a part of the scene.
A common use case for requesting focus is when a new Page is loaded into the scene. For example, on a page that requires text input from the user, you might want to request focus on a TextField as soon as the page loads so that the keyboard is automatically displayed. In this scenario, the natural assumption might be to request focus within the page's BaseObject::creationCompleted() signal, which is emitted once the object's construction is complete. However, this approach is incorrect. Even though the object has been created, it has not yet been added to the UI tree, so the call would fail.
Here are two different methods that you can use for requesting focus. The first method involves listening for changes to the Application::scene property. Here's a .qml file called RequestFocusPage.qml, which contains a TextField that you want to request focus for as soon as the page loads. The page contains a variant property that is bound to the application's scene property. When you declare a variable in QML, a value-change signal is implicitly created as well. So, whenever this page gets added to the scene, the onAppSceneChanged() signal handler is called where it's safe to request focus for the control.
import bb.cascades 1.2 Page { property variant appScene: Application.scene Container { TextArea { id: theTextArea text: "Give me focus!" } } onAppSceneChanged: { // This triggers focus if the application scene is set to // this QML Page. theTextArea.requestFocus(); } }The second method involves using a ComponentDefinition to load the pages. Here's another version called RequestFocusPage2.qml. It contains a Boolean property called readyForFocus which is initialized to false. When the value changes, the onreadyForFocusChanged() signal handler is called and focus is requested.
import bb.cascades 1.2 Page { property bool readyForFocus: false Container { TextArea { id: theTextArea text: "I want some focus too!" } } onReadyForFocusChanged: { if (readyForFocus) { // This triggers focus if the Page is created using a // ComponentDefinition. theTextArea.requestFocus(); } } }Here's how you can create the Page and set the readyForFocus property from a ComponentDefinition in a NavigationPane:
import bb.cascades 1.2 NavigationPane { id: nav RequestFocusPage { actions: ActionItem { ActionBar.placement: ActionBarPlacement.OnBar title: "Navigate" onTriggered: { var page = refocusPage.createObject(); nav.push(page); // Here it is ok to trigger the focus request since the page is added to // the UI tree as it is pushed to the NavigationPane. page.readyForFocus = true; } } } attachedObjects: ComponentDefinition { id: refocusPage source: "RequestFocusPage2.qml" } onPopTransitionEnded: { page.destroy() } }If succeeded, the focusedChanged() signal is emitted with true as its parameter.
BlackBerry 10.0.0
Q_SLOT void 
Resets the accessibilityMode property to its default value of Default.
BlackBerry 10.2.0
Q_SLOT void 
Resets the bottom padding to its default.
The default bottom padding is 0.
After the padding is reset, the bottomPaddingChanged() signal is emitted.
BlackBerry 10.0.0
Q_INVOKABLE void 
Resets an builtInShortcutsEnabled property to default value.
Default value is true.
BlackBerry 10.2.0
Q_SLOT void 
Resets the toggle button to its default state (unchecked).
BlackBerry 10.0.0
Q_SLOT void 
Resets the focusPolicy to its default value of FOCUSPOLICY_NONE.
BlackBerry 10.0.0
Q_SLOT void 
Reset the focus retention policy to default value.
BlackBerry 10.0.0
Q_SLOT void 
Resets the horizontal alignment to its default.
The default alignment is HorizontalAlignment::Left.
After the horizontal alignment is reset, the horizontalAlignmentChanged() signal is emitted.
BlackBerry 10.0.0
Q_SLOT void 
Resets the implicitLayoutAnimationsEnabled property to its default value.
BlackBerry 10.0.0
Q_SLOT void 
Resets the layoutProperties for the control to 0 (automatic selection of LayoutProperties).
BlackBerry 10.0.0
Q_SLOT void 
Resets the left padding to its default.
The default left padding is 0.
After the padding is reset, the leftPaddingChanged() signal is emitted.
BlackBerry 10.0.0
Q_SLOT void 
Resets the opacity of the visual node to 1.0 (opaque).
A value between 0.0 (transparent) and 1.0 (opaque). This is the local opacity of the visual node, i.e. not taking the ancestor opacities into account. The default opacity is 1.0 (opaque).
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the overlap touch policy for the visual node to OverlapTouchPolicy::Deny.
If overlap touch policy is OverlapTouchPolicy::Deny, overlapped nodes will be excluded from touch propagation at an early stage during the processing of touch input. This means a scene with many layers of visual nodes with overlap touch policy set to OverlapTouchPolicy::Allow, may affect touch performance negatively.
The policy has no effect if propagation mode is TouchPropagationMode::None for the same visual node.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Convenience function for resetting the position of pivot point to 0.0 (center of node) along all axes.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the position of pivot point of the visual node along the x-axis to 0.0 (center of node).
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the position of pivot point of the visual node along the y-axis to 0.0 (center of node).
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the preferredHeight to its default value of 0.
BlackBerry 10.0.0
Q_SLOT void 
Resets the preferred width and height of the control.
A convenience function for resetting both the preferred width and height. It is equivalent to calling both resetPreferredWidth() and resetPreferredHeight().
BlackBerry 10.0.0
Q_SLOT void 
Resets the right padding to its default.
The default right padding is 0.
After the padding is reset, the rightPaddingChanged() signal is emitted.
BlackBerry 10.0.0
Q_SLOT void 
Resets the rotation of the visual node around the z-axis to 0.0 degrees.
The visual node is rotated around the z-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default rotation is 0.0 degrees.
BlackBerry 10.0.0
resetRotation()
BlackBerry 10.0.0
Q_SLOT void 
Resets the scale factor for all axis to 1.0 (no scaling).
BlackBerry 10.0.0
Q_SLOT void 
Resets the scale factor of the visual node along the x-axis to 1.0 (no scaling).
The visual node is scaled along the x-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the scale factor of the visual node along the y-axis to 1.0 (no scaling).
The visual node is scaled along the y-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the top padding to its default.
The default top padding is 0.
After the padding is reset, the topPaddingChanged() signal is emitted.
BlackBerry 10.0.0
Q_SLOT void 
Resets the touch propagation mode for the visual node to TouchPropagationMode::Full.
This property controls how the visual node and its subtree partakes in touch event propagation. There are three possible modes, as defined by TouchPropagationMode::Type:
TouchPropagationMode::Full means that touch events will be fully propagated to the visual node and it's subtree.
TouchPropagationMode::None means no touch events will be propagated to the visual node or its subtree. The subtree is practically invisible to the touch system.
TouchPropagationMode::PassThrough means touch events will not be handled by the visual node itself, but its subtree will get touch events as usual.
The default propagation mode is TouchPropagationMode::Full.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Convenience function for resetting the translation along all axes.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the translation of the visual node to 0.0 along the x-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the translation of the visual node to 0.0 along the y-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
BlackBerry 10.0.0
Q_SLOT void 
Resets the vertical alignment to its default.
The default alignment is VerticalAlignment::Top.
After the vertical alignment is reset, the verticalAlignmentChanged() signal is emitted.
BlackBerry 10.0.0
Q_SLOT void 
Resets the visual node to be visible.
If the visible property is set to false, the visual node is neither laid out nor rendered. The default visible value is true.
Important: Setting the visible value to false is not the same as setting opacity to 0.0f (transparent). While a transparent node is still laid out taking up room in the scene, a node that is not visible, will neither be rendered nor laid out inside the scene. It will behave as if it was removed from the scene without actually been unlinked from the scene graph. No touch events will be sent to the node if the visible value is false. This a convenient way of removing nodes to optimize the performance of the scene without is actually unlinking them. It is highly recommended to use this property to hide visual nodes whenever possible.
BlackBerry 10.0.0
BlackBerry 10.0.0
float 
Returns the rightMargin for the control.
The right margin for the control.
BlackBerry 10.0.0
float 
Returns the right padding on the control.
The right padding.
BlackBerry 10.0.0
float 
Returns the rotation of the visual node around the z-axis.
The visual node is rotated around the z-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default rotation is 0.0 degrees.
BlackBerry 10.0.0
The rotation around the z-axis in degrees.
BlackBerry 10.0.0
float 
Returns the scale factor of the visual node along the x-axis.
The visual node is scaled along the x-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
The scale factor along the x-axis.
BlackBerry 10.0.0
float 
Returns the scale factor of the visual node along the y-axis.
The visual node is scaled along the y-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
The scale factor along the y-axis.
BlackBerry 10.0.0
Q_SLOT void 
Controls how the control is exposed to assistive technologies.
Parameters | |
---|---|
accessibilityMode |
The A11yMode to set on the control |
BlackBerry 10.2.0
Q_SLOT void 
Sets the bottomMargin for the control.
Parameters | |
---|---|
bottomMargin |
The bottom margin for control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the bottom padding for the control.
After the padding is set, the bottomPaddingChanged() signal is emitted.
Parameters | |
---|---|
bottomPadding |
The new left padding. |
BlackBerry 10.0.0
Q_INVOKABLE void 
Sets the enabled state of the built-in shortcut attached to the Control at a system level.
Built-in Shortcuts that are attached afterward will use the specified enabled state.
Selected Built-In shortcut can be enabled or disabled only if Control::builtInShortcutsEnabled property is set to true.
Parameters | |
---|---|
type |
The system shortcut type |
enabled |
If true the shortcut is enabled, and if false the shortcut is disabled. |
BlackBerry 10.2.0
Q_SLOT void 
Sets the enabled state of all built-in shortcuts attached to the Control at a system level.
Built-in Shortcuts that are attached afterward will use the specified enabled state.
Parameters | |
---|---|
enabled |
If true all built-in shortcuts are enabled, and if false all built-in shortcut are disabled. |
BlackBerry 10.2.0
Q_SLOT void 
Sets the state of this toggle control.
Parameters | |
---|---|
checked |
If true this toggle control is checked, if false this toggle control is unchecked. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the enabled state of the control.
Parameters | |
---|---|
enabled |
If true the control is enabled and if false the control is disabled. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the focusAutoShow of the control.
Parameters | |
---|---|
focusAutoShow |
The focusAutoShow state of the Control. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the focusPolicy of the control.
Parameters | |
---|---|
focusPolicy |
The focusPolicy state of the Control as a FocusPolicy. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the focus retention policy.
The policy describes under which condtions the control will lose focus.
Parameters | |
---|---|
policy |
The new policy. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the horizontal alignment for the control.
After the horizontal alignment is set, the horizontalAlignmentChanged() signal is emitted.
Parameters | |
---|---|
horizontalAlignment |
The horizontal alignment for the control. |
BlackBerry 10.0.0
Q_SLOT void 
Controls whether layout changes trigger automatic animations or not.
Parameters | |
---|---|
enable |
If true trigger animations, if false do not |
BlackBerry 10.0.0
Q_SLOT void 
Sets the layoutProperties for the control.
The control takes ownership of the LayoutProperties object if no other control owns it already. If the LayoutProperties object already has an owner, the properties are applied to the control, but ownership of the LayoutProperties object remains unchanged. If the control already owns a LayoutProperties object, the existing settings are replaced by the specified LayoutProperties object and the container retains ownership of both.
Parameters | |
---|---|
layoutProperties |
The new layout properties for the control. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the leftMargin for the control.
Parameters | |
---|---|
leftMargin |
The left margin for control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the left padding for the control.
After the padding is set, the leftPaddingChanged() signal is emitted.
Parameters | |
---|---|
leftPadding |
The new left padding. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the locallyFocused of the control.
Parameters | |
---|---|
locallyFocused |
The locallyFocused state of the Control. |
BlackBerry 10.3.1
Q_SLOT void 
Sets the maxHeight of the control.
Parameters | |
---|---|
maxHeight |
The new maximum height of the control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the maxWidth of the control.
Parameters | |
---|---|
maxWidth |
The new maximum width of the control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the minHeight of the control.
Parameters | |
---|---|
minHeight |
The new minimum height of the control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the minWidth of the control.
Parameters | |
---|---|
minWidth |
The new minimum width of the control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
void 
Sets the objectName property.
Parameters | |
---|---|
name |
The new name for the object. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the opacity of the visual node.
A value between 0.0 (transparent) and 1.0 (opaque). This is the local opacity of the visual node, i.e. not taking the ancestor opacities into account. The default opacity is 1.0 (opaque).
BlackBerry 10.0.0
Parameters | |
---|---|
opacity |
A value between between 0.0 (transparent) and 1.0 (opaque). If the value is outside the range it will be clamped to [0.0, 1.0]. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the overlap touch policy for the visual node.
If overlap touch policy is OverlapTouchPolicy::Deny, overlapped nodes will be excluded from touch propagation at an early stage during the processing of touch input. This means a scene with many layers of visual nodes with overlap touch policy set to OverlapTouchPolicy::Allow, may affect touch performance negatively.
The policy has no effect if propagation mode is TouchPropagationMode::None for the same visual node.
BlackBerry 10.0.0
Parameters | |
---|---|
policy |
The new overlap touch policy for the visual node. |
BlackBerry 10.0.0
Q_SLOT void 
Convenience function for setting the position of pivot point of the visual node along the x- and y-axes.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
Parameters | |
---|---|
pivotX |
The position of pivot point along the x-axis, relative to the center of the visual node. |
pivotY |
The position of pivot point along the y-axis, relative to the center of the visual node. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the position of pivot point of the visual node along the x-axis.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
setPivot(float, float), setPivot(float, float, float)
Parameters | |
---|---|
pivotX |
The position of pivot point along the x-axis, relative to the center of the visual node. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the position of pivot point of the visual node along the y-axis.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
setPivot(float, float), setPivot(float, float, float)
Parameters | |
---|---|
pivotY |
The position of pivot point along the y-axis, relative to the center of the visual node. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the preferredHeight of the control.
Parameters | |
---|---|
preferredHeight |
The preferred height of the control as a positive, non-zero number. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the preferred width and height of the control.
A convenience function for setting both preferred width and height. It is equivalent to calling both setPreferredWidth() and setPreferredHeight().
Parameters | |
---|---|
preferredWidth |
The preferred width of the control as a positive, non-zero number. |
preferredHeight |
The preferred height of the control as a positive, non-zero number. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the preferredWidth of the control.
Parameters | |
---|---|
preferredWidth |
The preferred width of the control as a positive, non-zero number. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the rightMargin for the control.
Parameters | |
---|---|
rightMargin |
The right margin for control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the right padding for the control.
After the padding is set, the rightPaddingChanged() signal is emitted.
Parameters | |
---|---|
rightPadding |
The new left padding. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the rotation of the visual node around the z-axis.
The visual node is rotated around the z-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default rotation is 0.0 degrees.
BlackBerry 10.0.0
Parameters | |
---|---|
rotationZ |
The rotation around the z-axis in degrees, anchored at (pivotX and pivotY). |
BlackBerry 10.0.0
Q_SLOT void 
Convenience function for setting the scale factor for each axes.
Parameters | |
---|---|
scaleX |
The scale factor along the x-axis, anchored at pivotX. |
scaleY |
The scale factor along the y-axis, anchored at pivotY. |
BlackBerry 10.0.0
Q_SLOT void 
Convenience function for setting the same scale factor for all axes.
Parameters | |
---|---|
scaleXY |
The scale factor to set for all axes. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the scale factor of the visual node along the x-axis.
The visual node is scaled along the x-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
Parameters | |
---|---|
scaleX |
The scale factor along the x-axis, anchored at pivotX. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the scale factor of the visual node along the y-axis.
The visual node is scaled along the y-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
Parameters | |
---|---|
scaleY |
The scale factor along the y-axis, anchored at pivotY. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the topMargin for the control.
Parameters | |
---|---|
topMargin |
The top margin for control; must be greater than or equal to 0.0. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the top padding for the control.
After the padding is set, the topPaddingChanged() signal is emitted.
Parameters | |
---|---|
topPadding |
The new left padding. |
BlackBerry 10.0.0
Q_SLOT void 
Sets the touch propagation mode for the visual node.
This property controls how the visual node and its subtree partakes in touch event propagation. There are three possible modes, as defined by TouchPropagationMode::Type:
TouchPropagationMode::Full means that touch events will be fully propagated to the visual node and it's subtree.
TouchPropagationMode::None means no touch events will be propagated to the visual node or its subtree. The subtree is practically invisible to the touch system.
TouchPropagationMode::PassThrough means touch events will not be handled by the visual node itself, but its subtree will get touch events as usual.
The default propagation mode is TouchPropagationMode::Full.
BlackBerry 10.0.0
Parameters | |
---|---|
mode |
The new touch propagation mode for the visual node. |
BlackBerry 10.0.0
Q_SLOT void 
Convenience function for setting the translation along all axes.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
Parameters | |
---|---|
translationX |
The translation along the the x-axis (pointing towards right). |
translationY |
The translation along the the y-axis (pointing downwards). |
BlackBerry 10.0.0
Q_SLOT void 
Sets the translation of the visual node along the x-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
setTranslation(float, float), setTranslation(float, float, float)
Parameters | |
---|---|
translationX |
The translation along the the x-axis (pointing towards right). |
BlackBerry 10.0.0
Q_SLOT void 
Sets the translation of the visual node along the y-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
setTranslation(float, float), setTranslation(float, float, float)
Parameters | |
---|---|
translationY |
The translation along the the y-axis (pointing downwards). |
BlackBerry 10.0.0
Q_SLOT void 
Sets the vertical alignment for the control.
After the vertical alignment is set, the verticalAlignmentChanged() signal is emitted.
Parameters | |
---|---|
verticalAlignment |
The vertical alignment for the control. |
BlackBerry 10.0.0
Q_SLOT void 
Sets whether the visual should be visible or not.
If the visible property is set to false, the visual node is neither laid out nor rendered. The default visible value is true.
Important: Setting the visible value to false is not the same as setting opacity to 0.0f (transparent). While a transparent node is still laid out taking up room in the scene, a node that is not visible, will neither be rendered nor laid out inside the scene. It will behave as if it was removed from the scene without actually been unlinked from the scene graph. No touch events will be sent to the node if the visible value is false. This a convenient way of removing nodes to optimize the performance of the scene without is actually unlinking them. It is highly recommended to use this property to hide visual nodes whenever possible.
BlackBerry 10.0.0
Parameters | |
---|---|
visible |
True to make the visual node visible, false otherwise. |
BlackBerry 10.0.0
Q_INVOKABLE bb::cascades::AbstractShortcut * 
Returns a shortcut at the specified index.
Ownership of the shortcut remains with the Control.
Parameters | |
---|---|
index |
The index of the shortcut. |
The requested shortcut if the index was valid, 0 otherwise.
BlackBerry 10.1.0
Q_INVOKABLE int 
Returns the number of shortcuts.
The number of shortcuts.
BlackBerry 10.1.0
virtual Q_INVOKABLE QString 
Returns a debug string representing this object.
A debug string for the object.
BlackBerry 10.0.0
float 
Returns the topMargin for the control.
The top margin for the control.
BlackBerry 10.0.0
float 
Returns the top padding on the control.
The top padding.
BlackBerry 10.0.0
TouchPropagationMode::Type 
Returns the touch propagation mode for the visual node.
This property controls how the visual node and its subtree partakes in touch event propagation. There are three possible modes, as defined by TouchPropagationMode::Type:
TouchPropagationMode::Full means that touch events will be fully propagated to the visual node and it's subtree.
TouchPropagationMode::None means no touch events will be propagated to the visual node or its subtree. The subtree is practically invisible to the touch system.
TouchPropagationMode::PassThrough means touch events will not be handled by the visual node itself, but its subtree will get touch events as usual.
The default propagation mode is TouchPropagationMode::Full.
BlackBerry 10.0.0
The touch propagation mode for the visual node.
BlackBerry 10.0.0
float 
Returns the translation of the visual node along the x-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
The translation along the the x-axis (pointing towards right).
BlackBerry 10.0.0
float 
Returns the translation of the visual node along the y-axis.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
The translation along the the y-axis (pointing downwards).
BlackBerry 10.0.0
Q_INVOKABLE bb::cascades::UIConfig * 
Returns the UIConfig for this ui object.
The UIConfig can be used to perform unit conversions from design units (du) and snapped design units (sdu) to pixels.
Ownership remains with Cascades.
Container *container1 = Container::create().background(Color::Red); UIConfig *ui = container1->ui(); container1->setPreferredWidth(ui->du(12)); container1->setPreferredHeight(ui->du(5)); Container *container2 = Container::create().background(Color::Green); container2->setPreferredWidth(ui->sdu(13.5)); container2->setPreferredHeight(ui->sdu(7.5)); Container *container3 = Container::create().background(Color::Blue); container3->setPreferredWidth(ui->px(150)); container3->setPreferredHeight(ui->sdu(50));
The UIConfig for this ui object.
BlackBerry 10.3.0
bb::cascades::VerticalAlignment::Type 
Returns the vertical alignment for the control.
The vertical alignment for the control.
BlackBerry 10.0.0
Static Public Functions
Builder
Creates and returns a builder for constructing a CheckBox.
CheckBox *checkbox2 = CheckBox::create() .text("Simple check box");
A builder for constructing a CheckBox.
BlackBerry 10.0.0
Builder
Creates and returns a builder for constructing a CheckBox with text.
Using the builder to create a CheckBox:
CheckBox *checkbox3 = CheckBox::create("Simple check box");This builder is a convenience constructor for creating a CheckBox with text. This is equivalent to the following:
CheckBox *checkbox2 = CheckBox::create() .text("Simple check box");
Parameters | |
---|---|
text |
A text string that represents the text to display beside the checkbox, or QString::Null to display no text on the checkbox. |
A Builder used to create a checkbox with text.
BlackBerry 10.0.0
Protected Functions
(Only has inherited protected functions)
Constructs an instance of BaseObject's subclass.
Parameters | |
---|---|
parent |
An optional parent, defaults to 0. |
BlackBerry 10.0.0
virtual void 
Overloaded to implement the event mechanism in Cascades.
If this function is overridden, it must be called by the derived class for events to work properly in Cascades.
Parameters | |
---|---|
signal |
The connected signal. |
BlackBerry 10.0.0
virtual void 
Overloaded to implement the event mechanism in Cascades.
If this function is overridden, it must be called by the derived class for events to work properly in Cascades.
Parameters | |
---|---|
signal |
The disconnected signal. |
BlackBerry 10.0.0
Signals
void
Emitted when the text beside this CheckBox changes.
Parameters | |
---|---|
text |
The new text string for this CheckBox, or QString::Null if no text is set. |
BlackBerry 10.0.0
void 
Emitted when the accessibilityMode property on the control changes.
Due to a work around for a Qt Core issue with accessing enums from QML, the argument of this signal doesn't follow naming convention for signals in which the signal arguments are typically named to match the associated property's name. Use the object's accessibilityMode property to access the current property value instead of the signal argument to avoid runtime errors.
Parameters | |
---|---|
newAccessibilityMode |
The new value. |
BlackBerry 10.2.0
void 
Parameters | |
---|---|
actionSet |
The ActionSet that has been added. |
BlackBerry 10.0.0
void 
Emitted when an ActionSet has been removed from the control.
Parameters | |
---|---|
actionSet |
The ActionSet that has been removed. 0 if emitted by removeAllActionSets(). |
BlackBerry 10.0.0
void 
Emitted when the bottomMargin of the control changes.
Parameters | |
---|---|
bottomMargin |
The new bottom margin for the control. |
BlackBerry 10.0.0
void 
Emitted when the bottomMarginSet of the control changes.
Parameters | |
---|---|
isSet |
information whether the preferred Width is now set. |
BlackBerry 10.0.0
void 
Emitted when the bottomPadding property changes.
Parameters | |
---|---|
bottomPadding |
The new bottom padding. |
BlackBerry 10.0.0
void 
Emitted when the builtInShortcutsEnabled property changes.
Parameters | |
---|---|
builtInShortcutsEnabled |
The new value. |
BlackBerry 10.2.0
void 
Emitted when the state of this toggle control changes.
Parameters | |
---|---|
checked |
The new state of this toggle control. If true this toggle control is checked, if false this toggle control is unchecked. |
BlackBerry 10.0.0
void 
Emitted when this object is instantiated as a result of loading a QML document and creating the root node (only after the root component that caused this instantiation has completed construction), or when the object is being constructed from its builder class.
This signal indicates that the construction and initialization of the object has been completed, the properties are initialized, and any QML binding values have been assigned to the object.
This signal is not emitted when the object is constructed from C++ using the constructor. If the object is constructed using its builder class, the signal is emitted when the the builder class returns the fully constructed object.
This signal can be used when there is an activity that needs to be performed, such as a property state integrity verification after the object is instantiated from a QML document or a builder, but before control is returned to the application.
BlackBerry 10.0.0
void 
Emitted when the enabled property on the control changes.
Parameters | |
---|---|
enabled |
If true the control is enabled, if false the control is disabled. |
BlackBerry 10.0.0
void 
Emitted when the focusAutoShow of the control changes.
Parameters | |
---|---|
newFocusAutoShow |
The new focusAutoShow state of the control. |
BlackBerry 10.0.0
void 
Emitted when the focused property on the control changes.
Parameters | |
---|---|
focused |
If true the control is focused, if false the control is not focused. |
BlackBerry 10.0.0
void 
Emitted when the focusPolicy of the control changes.
Parameters | |
---|---|
newFocusPolicy |
The new focusPolicy state of the control. |
BlackBerry 10.0.0
void 
Emitted when the focusRetentionPolicyFlags property on the control changes.
Parameters | |
---|---|
policy |
The new focusRetentionPolicy. |
BlackBerry 10.0.0
void 
Emitted when the horizontalAlignment property changes.
Due to a work around for a Qt Core issue with accessing enums from QML the argument of this signal doesn't follow naming convention for signals in which the signal arguments are typically named to match the associated property's name. Use the object's property to access current property value instead of the signal argument to avoid runtime errors (i.e. use horizontalAlignment instead of newHorizontalAlignment).
Parameters | |
---|---|
newHorizontalAlignment |
The new horizontal alignment for the control. |
BlackBerry 10.0.0
void 
Emitted when the implicitLayoutAnimationsEnabled property on the control changes.
Parameters | |
---|---|
implicitLayoutAnimationsEnabled |
The new value. |
BlackBerry 10.0.0
void 
Emitted when the layoutProperties of the control changes.
Parameters | |
---|---|
layoutProperties |
The new layout properties for the control. |
BlackBerry 10.0.0
void 
Emitted when the leftMargin of the control changes.
Parameters | |
---|---|
leftMargin |
The new left margin for the control. |
BlackBerry 10.0.0
void 
Emitted when the leftMarginSet of the control changes.
Parameters | |
---|---|
isSet |
information whether the preferred Width is now set. |
BlackBerry 10.0.0
void 
Emitted when the leftPadding property changes.
Parameters | |
---|---|
leftPadding |
The new left padding. |
BlackBerry 10.0.0
void 
Emitted when the locallyFocused of the control changes.
Parameters | |
---|---|
newLocallyFocused |
The new locallyFocused state of the control. |
BlackBerry 10.3.1
void 
Emitted when the maxHeight of the control changes.
Parameters | |
---|---|
maxHeight |
The new maximum height for the control. |
BlackBerry 10.0.0
void 
Emitted when the maxWidth of the control changes.
Parameters | |
---|---|
maxWidth |
The new maximum width for the control. |
BlackBerry 10.0.0
void 
Emitted when the minHeight of the control changes.
Parameters | |
---|---|
minHeight |
The new minimum height for the control. |
BlackBerry 10.0.0
void 
Emitted when the minWidth of the control changes.
Parameters | |
---|---|
minWidth |
The new minimum width for the control. |
BlackBerry 10.0.0
void 
This signal is emitted when the objectName property is changed.
BlackBerry 10.0.0
void 
Emitted after the opacity of the visual node has changed.
A value between 0.0 (transparent) and 1.0 (opaque). This is the local opacity of the visual node, i.e. not taking the ancestor opacities into account. The default opacity is 1.0 (opaque).
BlackBerry 10.0.0
Parameters | |
---|---|
opacity |
The new opacity set on the visual node. |
BlackBerry 10.0.0
void 
Emitted while the opacity of the visual node is changing.
A value between 0.0 (transparent) and 1.0 (opaque). This is the local opacity of the visual node, i.e. not taking the ancestor opacities into account. The default opacity is 1.0 (opaque).
BlackBerry 10.0.0
Parameters | |
---|---|
opacity |
The new opacity set on the visual node. |
BlackBerry 10.0.0
void 
Emitted when the overlap touch policy of the visual node is changed.
If overlap touch policy is OverlapTouchPolicy::Deny, overlapped nodes will be excluded from touch propagation at an early stage during the processing of touch input. This means a scene with many layers of visual nodes with overlap touch policy set to OverlapTouchPolicy::Allow, may affect touch performance negatively.
The policy has no effect if propagation mode is TouchPropagationMode::None for the same visual node.
BlackBerry 10.0.0
Parameters | |
---|---|
newOverlapTouchPolicy |
The new overlap touch policy. |
Due to a work around for a Qt Core issue with accessing enums from QML the argument of this signal doesn't follow naming convention for signals in which the signal arguments are typically named to match the associated property's name. Use the object's property to access current property value instead of the signal argument to avoid runtime errors (i.e. use overlapTouchPolicy instead of newOverlapTouchPolicy).
BlackBerry 10.0.0
void 
Emitted after pivotX of the visual node has changed.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
Parameters | |
---|---|
pivotX |
The new position of pivot point along the x-axis, relative to the center of the visual node. |
BlackBerry 10.0.0
void 
Emitted after pivotY of the visual node has changed.
The pivot is used as the anchoring point when rotating and scaling the visual node. It is defined by the components pivotX, pivotY and pivotZ and is relative to the center of the visual node. The default position of the pivot point is (0.0, 0.0, 0.0), which means it is at the center of the visual node.
BlackBerry 10.0.0
Parameters | |
---|---|
pivotY |
The new position of pivot point along the y-axis, relative to the center of the visual node. |
BlackBerry 10.0.0
void 
Emitted when the preferredHeight of the control changes.
Parameters | |
---|---|
preferredHeight |
The new preferred height; will always be positive. |
BlackBerry 10.0.0
void 
Emitted when the preferredHeightSet of the control changes.
Parameters | |
---|---|
isSet |
information whether the preferred height is now set. |
BlackBerry 10.0.0
void 
Emitted when the preferredWidth of the control changes.
Parameters | |
---|---|
preferredWidth |
The new preferred width; will always be positive. |
BlackBerry 10.0.0
void 
Emitted when the preferredWidthSet of the control changes.
Parameters | |
---|---|
isSet |
information whether the preferred width is now set. |
BlackBerry 10.0.0
void 
Emitted when the rightMargin of the control changes.
Parameters | |
---|---|
rightMargin |
The new right margin for the control. |
BlackBerry 10.0.0
void 
Emitted when the rightMarginSet of the control changes.
Parameters | |
---|---|
isSet |
information whether the preferred Width is now set. |
BlackBerry 10.0.0
void 
Emitted when the rightPadding property changes.
Parameters | |
---|---|
rightPadding |
The new right padding. |
BlackBerry 10.0.0
void 
Emitted after rotationZ of the visual node has changed.
The visual node is rotated around the z-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default rotation is 0.0 degrees.
BlackBerry 10.0.0
Parameters | |
---|---|
rotationZ |
The new rotation around the z-axis in degrees. |
BlackBerry 10.0.0
void 
Emitted while rotationZ of the visual node is changing.
The visual node is rotated around the z-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default rotation is 0.0 degrees.
BlackBerry 10.0.0
Parameters | |
---|---|
rotationZ |
The new rotation around the z-axis in degrees. |
BlackBerry 10.0.0
void 
Emitted after scaleX of the visual node has changed.
The visual node is scaled along the x-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
Parameters | |
---|---|
scaleX |
The new scale factor along the x-axis. |
BlackBerry 10.0.0
void 
Emitted while scaleX of the visual node is changing.
The visual node is scaled along the x-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
Parameters | |
---|---|
scaleX |
The new scale factor along the x-axis. |
BlackBerry 10.0.0
void 
Emitted after scaleY of the visual node has changed.
The visual node is scaled along the y-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
Parameters | |
---|---|
scaleY |
The new scale factor along the y-axis. |
BlackBerry 10.0.0
void 
Emitted while scaleY of the visual node is changing.
The visual node is scaled along the y-axis, centered around a pivot point defined by the components pivotX, pivotY and pivotZ. The default scale factor is 1.0 (not scaled).
BlackBerry 10.0.0
Parameters | |
---|---|
scaleY |
The new scale factor along the y-axis. |
BlackBerry 10.0.0
void 
Emitted when the topMargin of the control changes.
Parameters | |
---|---|
topMargin |
The new top margin for the control. |
BlackBerry 10.0.0
void 
Emitted when the topMarginSet of the control changes.
Parameters | |
---|---|
isSet |
information whether the preferred Width is now set. |
BlackBerry 10.0.0
void 
Emitted when the topPadding property changes.
Parameters | |
---|---|
topPadding |
The new top padding. |
BlackBerry 10.0.0
void 
Emitted when a touch event is received.
Adding touch behaviors is a way to influence under what circumstances the node receives events.
Parameters | |
---|---|
event |
Pointer to the touch event. |
BlackBerry 10.0.0
void 
Emitted when a touch event is directed towards a child of this node.
Adding touch behaviors is a way to influence under what circumstances the node receives events.
Parameters | |
---|---|
event |
- Pointer to the touch event. |
BlackBerry 10.0.0
void 
Emitted when touch enters the enter/exit area of this node.
touchEnter is not emitted when touch down happens on the enter/exit area, but only when touch moves into the area from outside.
Enter/exit areas
-
the node where the listener is connected,
-
its subtree and
-
overlapping nodes that are not part of the subtree
-
touchPropagationMode and
-
overlapTouchPolicy
touchPropagationMode
-
None means a node and its subtree does not count towards the enter/exit area.
-
PassThrough means a node does not count towards any enter/exit area, but its subtree does.
-
Full means a node and its subtree counts towards the enter/exit area.
overlapTouchPolicy
-
Deny means a node that overlaps an enter/exit area (and is not part of the enter/exit subtree) subtracts from the enter/exit area.
-
Allow means a node that overlaps an enter/exit area (and is not part of the enter/exit subtree) doesn't affect the enter/exit area.

void 
Emitted when touch leaves the enter/exit area of this node.
touchExit is not emitted when touch up happens on the enter/exit area, but only when touch moves out from the area.
See touchEnter for more information.
void 
Emitted when the touch propagation mode of the visual node is changed.
This property controls how the visual node and its subtree partakes in touch event propagation. There are three possible modes, as defined by TouchPropagationMode::Type:
TouchPropagationMode::Full means that touch events will be fully propagated to the visual node and it's subtree.
TouchPropagationMode::None means no touch events will be propagated to the visual node or its subtree. The subtree is practically invisible to the touch system.
TouchPropagationMode::PassThrough means touch events will not be handled by the visual node itself, but its subtree will get touch events as usual.
The default propagation mode is TouchPropagationMode::Full.
BlackBerry 10.0.0
Parameters | |
---|---|
newTouchPropagationMode |
The new touch propagation mode for the visual node. |
Due to a work around for a Qt Core issue with accessing enums from QML the argument of this signal doesn't follow naming convention for signals in which the signal arguments are typically named to match the associated property's name. Use the object's property to access current property value instead of the signal argument to avoid runtime errors (i.e. use touchPropagationMode instead of newTouchPropagationMode).
BlackBerry 10.0.0
void 
Emitted after translationX of the visual node has changed.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
Parameters | |
---|---|
translationX |
The translation along the the x-axis (pointing towards right) |
BlackBerry 10.0.0
void 
Emitted while translationX of the visual node is changing.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
Parameters | |
---|---|
translationX |
The new translation along the the x-axis (pointing towards right) |
BlackBerry 10.0.0
void 
Emitted after translationY of the visual node has changed.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
Parameters | |
---|---|
translationY |
The new translation along the the y-axis (pointing downwards). |
BlackBerry 10.0.0
void 
Emitted while translationY of the visual node is changing.
The translationX and translationY correspond to pixels as long as the translationZ is 0.0.
The translation is mostly useful for animations as it doesn't affect the actual laid out position of the visual node. This translation is added after the node has been laid out so it doesn't affect layout in any way.
Layout for more details.
BlackBerry 10.0.0
Parameters | |
---|---|
translationY |
The new translation along the the y-axis (pointing downwards). |
BlackBerry 10.0.0
void 
Emitted when the verticalAlignment property changes.
Due to a work around for a Qt Core issue with accessing enums from QML the argument of this signal doesn't follow naming convention for signals in which the signal arguments are typically named to match the associated property's name. Use the object's property to access current property value instead of the signal argument to avoid runtime errors (i.e. use verticalAlignment instead of newVerticalAlignment).
Parameters | |
---|---|
newVerticalAlignment |
The new vertical alignment for the control. |
BlackBerry 10.0.0
void 
Emitted when the visible property of the visual node is changed.
If the visible property is set to false, the visual node is neither laid out nor rendered. The default visible value is true.
Important: Setting the visible value to false is not the same as setting opacity to 0.0f (transparent). While a transparent node is still laid out taking up room in the scene, a node that is not visible, will neither be rendered nor laid out inside the scene. It will behave as if it was removed from the scene without actually been unlinked from the scene graph. No touch events will be sent to the node if the visible value is false. This a convenient way of removing nodes to optimize the performance of the scene without is actually unlinking them. It is highly recommended to use this property to hide visual nodes whenever possible.
BlackBerry 10.0.0
Parameters | |
---|---|
visible |
The new visible property set on the visual node. |
BlackBerry 10.0.0