Top Description Constructors Methods
org.controlsfx.control.tableview2.actions

public Class RowFixAction

extends Action
Class Inheritance
Annotations
@ActionCheck
Imports
javafx.beans.Observable, javafx.scene.Node, org.controlsfx.control.action.Action, .ActionCheck, .ActionUtils, org.controlsfx.control.tableview2.TableView2

A custom action that can be added to the ContextMenu of any row in the row header, allowing the user to fix or unfix the row. This action has to be bound to a javafx.scene.control.CheckMenuItem node.

Sample

The following code snippet provides a ContextMenu that contains the fix action for each row in the row header:

TableView2<Person> table = new TableView2<Person>();
table.setRowHeaderVisible(true);
table.setRowHeaderContextMenuFactory((i, person) -> 
    ActionUtils.createContextMenu(Arrays.asList(new RowFixAction(this, i))));
See Also
ActionUtils#createContextMenu(java.util.Collection)

Constructor Summary

AccessConstructor and Description
public
RowFixAction(TableView2<S>
The TableView2 to which the action is applied to
tableView
,
Integer
The number of row
row
)

Creates a fix action for a given column.

public
RowFixAction(TableView2<S>
The TableView2 to which the action is applied to
tableView
,
Integer
The number of row
row
,
String
the string to display in the text property of controls such as MenuItem.
name
)

Creates a fix action for a given column.

public
RowFixAction(TableView2<S>
The TableView2 to which the action is applied to
tableView
,
Integer
The number of row
row
,
String
the string to display in the text property of controls such as MenuItem.
name
,
Node
the node to display in the graphic property of controls such as CheckMenuItem.
image
)

Creates a fix action for a given column.

Method Summary

Modifier and TypeMethod and Description
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from org.controlsfx.control.action.Action:
acceleratorPropertydisabledPropertygetAcceleratorgetEventHandlergetGraphicgetLongTextgetPropertiesgetStylegetStyleClassgetTextgraphicPropertyhandleisDisabledisSelectedlocklongTextPropertyselectedPropertysetAcceleratorsetDisabledsetEventHandlersetGraphicsetLongTextsetSelectedsetStylesetTextstylePropertytextProperty

Constructor Detail

RowFixActionback to summary
public RowFixAction(TableView2<S> tableView, Integer row)

Creates a fix action for a given column. When fired, the action will fix the column if is allowed and the column wasn't fixed yet, or unfix a fixed column. The action can be attached for instance to the javafx.scene.control.ContextMenu of the column.

Parameters
tableView:TableView2<S>

The TableView2 to which the action is applied to

row:Integer

The number of row

RowFixActionback to summary
public RowFixAction(TableView2<S> tableView, Integer row, String name)

Creates a fix action for a given column. When fired, the action will fix the column if is allowed and the column wasn't fixed yet, or unfix a fixed column. The action can be attached for instance to the javafx.scene.control.ContextMenu of the column.

Parameters
tableView:TableView2<S>

The TableView2 to which the action is applied to

row:Integer

The number of row

name:String

the string to display in the text property of controls such as MenuItem.

RowFixActionback to summary
public RowFixAction(TableView2<S> tableView, Integer row, String name, Node image)

Creates a fix action for a given column. When fired, the action will fix the column if is allowed and the column wasn't fixed yet, or unfix a fixed column. The action can be attached for instance to the javafx.scene.control.ContextMenu of the column.

Parameters
tableView:TableView2<S>

The TableView2 to which the action is applied to

row:Integer

The number of row

name:String

the string to display in the text property of controls such as MenuItem.

image:Node

the node to display in the graphic property of controls such as CheckMenuItem.

Method Detail

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Annotations
@Override