FreeMindGroovyObjects: Difference between revisions
From FreeMind
Jump to navigationJump to search
Dan Polansky (talk | contribs) (+cat) |
|||
Line 123: | Line 123: | ||
== c == | == c == | ||
[[Category:Documentation]] |
Latest revision as of 19:28, 24 September 2009
This page is the starting point for a Groovy scripting reference. You will have to examine the FreeMind source code for operations on the interfaces. See the examples for a few operations such as setting the node text, node color and background color.
If you figure something out, document it here for the rest of us.
Objects
Available Operations
When the Groovy binding is created, two variables are set:
- "c" is set to the MindMapController
- "node" is set to the MindMapNode being evaluated
freemind.modes.MindMapNode
This is the generic object for a node, you navigate from node to node in a hierarchal manner.
childrenFolded()
- Returns
- java.util.ListIterator
childrenUnfolded()
- Returns
- java.util.ListIterator
getChildren()
- Returns
- java.util.List
Information Retrieval
getAdditionalInfo()
- Returns
- String
- Definition
- Return the Additional Information for a MindMapNode.
getAttribute(<String>)
- Returns
- String
- Definition
- Return the value of the specified MindMapNode Attribute.
- Parameters
- <String> : The name of the Attribute to return.
getAttributeKeyList()
- Returns
- java.util.List
- Definition
- Return a List containing the Attribute Keys for a MindMapNode.
getAttributePosition(<String>)
- Returns
- int
- Definition
- Return the position of the specified Attribute in the Attribute Table.
- Parameters
- <String> : The name of the Attribute to return the position of.
getAttributes()
- Returns
- NodeAttributeTableModel
- Definition
- Return the Attributes Table Model of a MindMapNode.
getAttributeTableLength()
- Returns
- int
- Definition
- Return the number of Attributes in the Attributes Table.
getBackgroundColor()
- Returns
- java.awt.Color
- Definition
- Return the background color of a MindMapNode.
getChildPosition(<freemind.modes.MindMapNode>)
- Returns
- int
- Definition
- Return the position of a specific child of a MindMapNode.
- Parameters
- <freemind.modes.MindMapNode> : The MindMapNode to return the position of.
getCloud()
- Definition
- Return the MindMapCloud instance belonging to a MindMapNode.
- Returns
- freemind.modes.MindMapCloud
getColor()
- Definition
- Return the Color of a MindMapNode.
- Returns
- java.awt.Color
getEdge()
- Definition
- Return the MindMapEdge instance belonging to a MindMapNode.
- Returns
- freemind.modes.MindMapEdge
getFont()
- Definition
- Return the Font of a MindMapNode.
- Returns
- java.awt.Font
getFontFamilyName()
- Definition
- Return the current Font Family Name of a MindMapNode.
- Returns
- String
getFontSize()
- Definition
- Return the current Font Size expressed as a String.
- Returns
- String
getNodeLevel()
- Returns
- int
- Definition
- Returns the current level of the node.
getText()
- Returns
- String
- Definition
- Returns the text of the node.
Assignment
createAttributeTableModel()
- Returns
- void
- Definition
- Create a new Attribute Table Model on a MindMapNode. This would be the equivalent of choosing "Edit Attributes" from within FreeMind.
setColor(<java.awt.Color>)
- Returns
- void
- Definition
- Sets the text color of the node.
- Parameters
- <java.awt.Color> : accepts values in the form of java.awt.Color.RED
setBackgroundColor(<java.awt.Color>)
- Returns
- void
- Definition
- Sets the background color of the node.
- Parameters
- <java.awt.Color> : accepts values in the form of java.awt.Color.BLUE
setText(<String>)
- Returns
- void
- Definition
- Sets the text of the node.
- Parameters
- <String> : Next text value of the node.