JavaFX: Bringing Rich Experiences To All the Screens Of Your Life

Profile: desktop, common

Overview

The Group class represents a list of Nodes objects. Example:

the code:

import javafx.scene.*;
import javafx.scene.paint.*;
import javafx.scene.geometry.*;
Group {
    content: for(x in [0..4]) {
        Rectangle {
            y: indexof x * 20
            width: 100 
            height: 10 
            fill:Color.RED
        }
    }
}

produces:

Profile: common

This comment needs review.

Attribute Summary

nametypedescription
Public
contentNode[]

Replaces the current array of Nodes with the specified array.

More: [+]

Replaces the current array of Nodes with the specified array.

Profile: common

impl_layoutfunction(:Group):Void More: [+]

This attribute should be treated as private

Protected

Inherited Attributes

javafx.scene.Node

nametypedescription
anchorXNumber

Defines the X coordinate of the rotation anchor point of this Node.

More: [+]

Defines the X coordinate of the rotation anchor point of this Node.

Default value: 0

Profile: common

anchorYNumber

Defines the Y coordinate of the rotation anchor point of this Node.

More: [+]

Defines the Y coordinate of the rotation anchor point of this Node.

Default value: 0

Profile: common

blocksMouseBoolean More: [+]

Profile: common conditional mouse

cacheBoolean

Defines if this node should be cached as a bitmap

More: [+]

Defines if this node should be cached as a bitmap

Profile: common

clipShape

Defines the clipping shape of this Node.

More: [+]

Defines the clipping shape of this Node.

Profile: common conditional clip

clipAntialiasedBoolean

Defines if the soft clipping is used by this Node.

More: [+]

Defines if the soft clipping is used by this Node.

Profile: common conditional clip

cursorCursor

Defines the mouse cursor for this Node.

More: [+]

Defines the mouse cursor for this Node.

Profile: common conditional cursor

effectEffect

Sets an effect on this node.

More: [+]

Sets an effect on this node.

horizontalAlignmentHorizontalAlignment

Defines the HorizontalAlignment of this Node.

More: [+]

Defines the HorizontalAlignment of this Node.

Default value: HorizontalAlignment.LEADING

Profile: common

idString

The id of this node.

More: [+]

The id of this node.

Default value: null

Profile: common

impl_cachedBoundsRectangle2D More: [+]

This attribute should be treated as private

impl_cachedXYWHRectangle2D More: [+]

This attribute should be treated as private

impl_layoutXNumber More: [+]

This attribute should be treated as private

impl_layoutYNumber More: [+]

This attribute should be treated as private

impl_needsLayoutBoolean More: [+]

This attribute should be treated as private

onKeyPressedfunction(:KeyEvent):Void

Defines a function to be notified when a key has been typed.

More: [+]

Defines a function to be notified when a key has been typed.

Profile: common conditional keyboard

onKeyReleasedfunction(:KeyEvent):Void

Defines a function to be notified when a key has been released.

More: [+]

Defines a function to be notified when a key has been released.

Profile: common conditional keyboard

onKeyTypedfunction(:KeyEvent):Void

Defines a function to be notified when a key has been typed.

More: [+]

Defines a function to be notified when a key has been typed.

Profile: common conditional keyboard

onMouseClickedfunction(:MouseEvent):Void

Defines a function to be notified when a mouse button has been clicked (pressed and released) on this Node.

More: [+]

Defines a function to be notified when a mouse button has been clicked (pressed and released) on this Node.

Profile: common conditional mouse

onMouseDraggedfunction(:MouseEvent):Void

Defines a function to be notified when a mouse button is pressed on this Node and then dragged.

More: [+]

Defines a function to be notified when a mouse button is pressed on this Node and then dragged.

Profile: common conditional mouse

onMouseEnteredfunction(:MouseEvent):Void

Defines a function to be notified when the mouse enters this Node.

More: [+]

Defines a function to be notified when the mouse enters this Node.

Profile: common conditional mouse

onMouseExitedfunction(:MouseEvent):Void

Defines a function to be notified when the mouse exits this Node.

More: [+]

Defines a function to be notified when the mouse exits this Node.

Profile: common conditional mouse

onMouseMovedfunction(:MouseEvent):Void

Defines a function to be notified when mouse cursor has been moved onto this Node but no buttons have been pushed.

More: [+]

Defines a function to be notified when mouse cursor has been moved onto this Node but no buttons have been pushed.

Profile: common conditional mouse

onMousePressedfunction(:MouseEvent):Void

Defines a function to be notified when a mouse button has been pressed on this Node.

More: [+]

Defines a function to be notified when a mouse button has been pressed on this Node.

Profile: common conditional mouse

onMouseReleasedfunction(:MouseEvent):Void

Defines a function to be notified when a mouse button has been released on this Node.

More: [+]

Defines a function to be notified when a mouse button has been released on this Node.

Profile: common conditional mouse

onMouseWheelMovedfunction(:MouseEvent):Void

Defines a function to be notified when the mouse scroll wheel has moved.

More: [+]

Defines a function to be notified when the mouse scroll wheel has moved.

Profile: common conditional mouse

opacityNumber More: [+]

Profile: common conditional groupOpacity In the common profile opacity is supported unconditionally on all nodes except Group, where on some platforms the implementation might try to deliver the result with best effort. The application should check groupOpacity feature value on the particular platform to see how group opacity works. Possible values are: <ul> <li><code>FULLY_SUPPORTED</code> - for full support of the group opacity</li> <li><code>BEST_EFFORT</code> - for a support which does not guarantee an exact appearance of the group opacity (e.g. overlapping graphics nodes might be visualized differently</li> </ul> On some platforms ImageView might not support opacity attribute.

rotateNumber

Defines the angle of rotation measured in degrees for this Node.

More: [+]

Defines the angle of rotation measured in degrees for this Node.

Profile: common

scaleXNumber

Defines the factor by which coordinates are scaled along the X axis direction of this Node.

More: [+]

Defines the factor by which coordinates are scaled along the X axis direction of this Node.

Default value: 1.0

Profile: common

scaleYNumber

Defines the factor by which coordinates are scaled along the Y axis direction of this Node.

More: [+]

Defines the factor by which coordinates are scaled along the Y axis direction of this Node.

Default value: 1.0

Profile: common

shearXNumber

Defines the multiplier by which coordinates are shifted in the direction of the positive X axis as a factor of their Y coordinate.

More: [+]

Defines the multiplier by which coordinates are shifted in the direction of the positive X axis as a factor of their Y coordinate.

Profile: common

shearYNumber

Defines the multiplier by which coordinates are shifted in the direction of the positive Y axis as a factor of their X coordinate

More: [+]

Defines the multiplier by which coordinates are shifted in the direction of the positive Y axis as a factor of their X coordinate

Profile: common

transformTransform[]

Defines the array of Transform objects to be applied when this Node is shown.

More: [+]

Defines the array of Transform objects to be applied when this Node is shown.

Profile: common

translateXNumber

Defines the distance by which coordinates are translated in the X axis direction of this Node.

More: [+]

Defines the distance by which coordinates are translated in the X axis direction of this Node.

Default value: 0

Profile: common

translateYNumber

Defines the distance by which coordinates are translated in the Y axis direction of this Node.

More: [+]

Defines the distance by which coordinates are translated in the Y axis direction of this Node.

Default value: 0

Profile: common

verticalAlignmentVerticalAlignment

Defines the VerticalAlignment of this Node.

More: [+]

Defines the VerticalAlignment of this Node.

Default value: VerticalAlignment.TOP

Profile: common

visibleBoolean

Defines if this Node is shown or hidden.

More: [+]

Defines if this Node is shown or hidden.

Default value: true

Profile: common

Function Summary

public impl_createSGNode() : com.sun.scenario.scenegraph.SGNode

More: [+]

Returns
SGNode

Inherited Functions

javafx.scene.Node

public contains(x: Number, y: Number) : Boolean

Returns true if the given point (specified in the local coordinate space of this Node) is contained within the visual bounds of this Node.

More: [+]

Returns true if the given point (specified in the local coordinate space of this Node) is contained within the visual bounds of this Node. Note that this method does not take visibility into account; the test is based on the geometry of this Node only.

Parameters
x
y
Returns
Boolean

Profile: common

public bound getBoundsHeight() : Number

Returns the current height of this Node.

More: [+]

Returns the current height of this Node. This value includes the node's transform.

Returns
Number

Profile: common

public bound getBoundsWidth() : Number

Returns the current width of this Node.

More: [+]

Returns the current width of this Node. This value includes the node's transform.

Returns
Number

Profile: common

public bound getBoundsX() : Number

Returns the current x coordinate of the Node origin.

More: [+]

Returns the current x coordinate of the Node origin. This value includes the node's transform.

Returns
Number

Profile: common

public bound getBoundsY() : Number

Returns the current y coordinate of the Node origin.

More: [+]

Returns the current y coordinate of the Node origin. This value includes the node's transform.

Returns
Number

Profile: common

public bound getHeight() : Number

Returns the current height of this Node.

More: [+]

Returns the current height of this Node. This value does not include the node's transform.

Returns
Number

Profile: common

public getParent() : Node

Returns the parent Node of this Node.

More: [+]

Returns the parent Node of this Node.

Returns
Node

Profile: common

public bound getWidth() : Number

Returns the current width of this Node.

More: [+]

Returns the current width of this Node. This value does not include the node's transform.

Returns
Number

Profile: common

public bound getX() : Number

Returns the current x coordinate of the Node origin.

More: [+]

Returns the current x coordinate of the Node origin. This value does not include the node's transform.

Returns
Number

Profile: common

public bound getY() : Number

Returns the current y coordinate of the Node origin.

More: [+]

Returns the current y coordinate of the Node origin. This value does not include the node's transform.

Returns
Number

Profile: common

public bound hasFocus() : Boolean

Returns true if this Node is the focus owner.

More: [+]

Returns true if this Node is the focus owner.

Returns
Boolean

Profile: common

public abstract impl_createSGNode() : com.sun.scenario.scenegraph.SGNode

More: [+]

Returns
SGNode
public impl_getFXNode() : com.sun.scenario.scenegraph.fx.FXNode

More: [+]

Returns
FXNode
public impl_getSGNode() : com.sun.scenario.scenegraph.SGNode

More: [+]

Returns
SGNode
protected impl_requestLayout() : Void

Set the impl_needsLayout attribute of every ancestor of this Node.

More: [+]

Set the impl_needsLayout attribute of every ancestor of this Node. If this Node is a Group/CustomNode then set its impl_needsLayout attribute as well. We short-circuit when we find a node who's impl_needsLayout bit is already set.

public impl_updateFXNodeTransform() : Void

More: [+]

public bound isFocusable() : Boolean

Defines whether this Node can be focused.

More: [+]

Defines whether this Node can be focused.

Returns
Boolean

Profile: common

public isMouseButtonDown(buttonNumber: Integer) : Boolean

Returns true if the specified mouse button is pressed.

More: [+]

Returns true if the specified mouse button is pressed.

Parameters
buttonNumber
nubmer of mouse button to be checked
Returns
Boolean

Profile: common conditional mouse

public bound isMouseOver() : Boolean

Returns true if the mouse is over this Node.

More: [+]

Returns true if the mouse is over this Node.

Returns
Boolean

Profile: common conditional mouse

public lookup(id: java.lang.String) : Node

Returns this Node if its id matches.

More: [+]

Returns this Node if its id matches. Otherwise, if this Node is a Group, then return the first descendant whose id matches.

Parameters
id
Returns
Node

Profile: common

public requestFocus() : Void

Requests that this Node get the input focus, and that this Node's top-level ancestor become the focused Window.

More: [+]

Requests that this Node get the input focus, and that this Node's top-level ancestor become the focused Window.

Profile: common

public toBack() : Void

Moves this node to the back of it's sibiling nodes

More: [+]

Moves this node to the back of it's sibiling nodes

Profile: common

public toFront() : Void

Moves this node to the front of it's sibiling nodes

More: [+]

Moves this node to the front of it's sibiling nodes

Profile: common