A tool to edit existing figures that implement the TextHolderFigure
interface, such as TextAreaFigure.
To edit an existing text figure using the TextAreaEditingTool, the user does the
following mouse gesture on a DrawingView:
- Press the mouse button over a Figure on the DrawingView.
The TextAreaEditingTool then uses Figure.findFigureInside to find a Figure that
implements the TextHolderFigure interface and that is editable. Then it overlays
a text area over the drawing where the user can enter the text for the Figure.
Design Patterns
Framework
The text creation and editing tools and the
TextHolderFigureinterface define together the contracts of a smaller framework inside of the
JHotDraw framework for structured drawing editors.
Contract:
TextHolderFigure,
TextCreationTool,
TextAreaCreationTool,
TextEditingTool,
TextAreaEditingTool,
FloatingTextField,
FloatingTextArea.