| 
 | JGraph X 2.1.0.7 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.mxgraph.swing.view.mxCellEditor
public class mxCellEditor
To control this editor, use mxGraph.invokesStopCellEditing, mxGraph. enterStopsCellEditing and mxGraph.escapeEnabled.
| Field Summary | |
|---|---|
| protected  AbstractAction | cancelEditingAction | 
| static int | DEFAULT_MIN_HEIGHT | 
| static int | DEFAULT_MIN_WIDTH | 
| static double | DEFAULT_MINIMUM_EDITOR_SCALE | 
| protected  Object | editingCell | 
| protected  JEditorPane | editorPaneHolds the editor for HTML editing. | 
| protected  boolean | extractHtmlBodySpecifies if the text content of the HTML body should be extracted before and after editing for HTML markup. | 
| protected  mxGraphComponent | graphComponent | 
| protected  double | minimumEditorScaleDefines the minimum scale to be used for the editor. | 
| protected  int | minimumHeight | 
| protected  int | minimumWidth | 
| protected  boolean | replaceLinefeedsSpecifies if linefeeds should be replaced with BREAKS before editing, and BREAKS should be replaced with linefeeds after editing. | 
| protected  JScrollPane | scrollPane | 
| protected  boolean | shiftEnterSubmitsTextSpecifies if shift ENTER should submit text if enterStopsCellEditing is true. | 
| protected  JTextArea | textAreaHolds the editor for plain text editing. | 
| protected  AbstractAction | textSubmitAction | 
| protected  EventObject | trigger | 
| Constructor Summary | |
|---|---|
| mxCellEditor(mxGraphComponent graphComponent) | |
| Method Summary | |
|---|---|
| protected  void | configureActionMaps()Installs the keyListener in the textArea and editorPane for handling the enter keystroke and updating the modified state. | 
|  String | getCurrentValue()Returns the current editing value. | 
|  Object | getEditingCell()Returns the cell that is currently being edited. | 
|  Component | getEditor()Returns the current editor or null if no editing is in progress. | 
|  Rectangle | getEditorBounds(mxCellState state,
                double scale)Returns the bounds to be used for the editor. | 
| protected  String | getInitialValue(mxCellState state,
                EventObject trigger)Gets the initial editing value for the given cell. | 
|  double | getMinimumEditorScale() | 
|  int | getMinimumHeight() | 
|  int | getMinimumWidth() | 
|  boolean | isExtractHtmlBody()Returns replaceHtmlLinefeeds | 
| protected  boolean | isHideLabel(mxCellState state) | 
|  boolean | isReplaceHtmlLinefeeds()Returns replaceHtmlLinefeeds | 
|  boolean | isShiftEnterSubmitsText()Returns shiftEnterSubmitsText | 
|  void | setExtractHtmlBody(boolean value)Sets extractHtmlBody | 
|  void | setMinimumEditorScale(double minimumEditorScale) | 
|  void | setMinimumHeight(int minimumHeight) | 
|  void | setMinimumWidth(int minimumWidth) | 
|  void | setReplaceHtmlLinefeeds(boolean value)Sets replaceHtmlLinefeeds | 
|  void | setShiftEnterSubmitsText(boolean value)Sets shiftEnterSubmitsText | 
|  void | startEditing(Object cell,
             EventObject evt)Starts editing the given cell. | 
|  void | stopEditing(boolean cancel)Stops the current editing. | 
| protected  boolean | useLabelBounds(mxCellState state)Returns true if the label bounds of the state should be used for the editor. | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static int DEFAULT_MIN_WIDTH
public static int DEFAULT_MIN_HEIGHT
public static double DEFAULT_MINIMUM_EDITOR_SCALE
protected mxGraphComponent graphComponent
protected double minimumEditorScale
protected int minimumWidth
protected int minimumHeight
protected transient Object editingCell
protected transient EventObject trigger
protected transient JScrollPane scrollPane
protected transient JTextArea textArea
protected transient JEditorPane editorPane
protected boolean extractHtmlBody
protected boolean replaceLinefeeds
protected boolean shiftEnterSubmitsText
protected AbstractAction cancelEditingAction
protected AbstractAction textSubmitAction
| Constructor Detail | 
|---|
public mxCellEditor(mxGraphComponent graphComponent)
| Method Detail | 
|---|
public boolean isExtractHtmlBody()
public void setExtractHtmlBody(boolean value)
public boolean isReplaceHtmlLinefeeds()
public void setReplaceHtmlLinefeeds(boolean value)
public boolean isShiftEnterSubmitsText()
public void setShiftEnterSubmitsText(boolean value)
protected void configureActionMaps()
public Component getEditor()
protected boolean useLabelBounds(mxCellState state)
public Rectangle getEditorBounds(mxCellState state,
                                 double scale)
public void startEditing(Object cell,
                         EventObject evt)
mxICellEditor
startEditing in interface mxICellEditorprotected boolean isHideLabel(mxCellState state)
public void stopEditing(boolean cancel)
mxICellEditor
stopEditing in interface mxICellEditor
protected String getInitialValue(mxCellState state,
                                 EventObject trigger)
public String getCurrentValue()
public Object getEditingCell()
mxICellEditor
getEditingCell in interface mxICellEditorpublic double getMinimumEditorScale()
public void setMinimumEditorScale(double minimumEditorScale)
minimumEditorScale - the minimumEditorScale to setpublic int getMinimumWidth()
public void setMinimumWidth(int minimumWidth)
minimumWidth - the minimumWidth to setpublic int getMinimumHeight()
public void setMinimumHeight(int minimumHeight)
minimumHeight - the minimumHeight to set| 
 | JGraph X 2.1.0.7 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||