Serializable
, UndoableEdit
DefaultStyledDocument
public static class DefaultStyledDocument.AttributeUndoableEdit extends AbstractUndoableEdit
Modifier and Type | Field | Description |
---|---|---|
protected AttributeSet |
copy |
Copy of the AttributeSet the Element contained. |
protected Element |
element |
Affected Element. |
protected boolean |
isReplacing |
true if all the attributes in the element were removed first. |
protected AttributeSet |
newAttributes |
AttributeSet containing additional entries, must be non-mutable! |
RedoName, UndoName
Constructor | Description |
---|---|
AttributeUndoableEdit |
Constructs an AttributeUndoableEdit . |
addEdit, canRedo, canUndo, die, getPresentationName, getRedoPresentationName, getUndoPresentationName, isSignificant, replaceEdit, toString
protected AttributeSet newAttributes
protected AttributeSet copy
protected boolean isReplacing
protected Element element
public AttributeUndoableEdit(Element element, AttributeSet newAttributes, boolean isReplacing)
AttributeUndoableEdit
.element
- the elementnewAttributes
- the new attributesisReplacing
- true if all the attributes in the element were removed first.public void redo() throws CannotRedoException
redo
in interface UndoableEdit
redo
in class AbstractUndoableEdit
CannotRedoException
- if the change cannot be redonepublic void undo() throws CannotUndoException
undo
in interface UndoableEdit
undo
in class AbstractUndoableEdit
CannotUndoException
- if the change cannot be undone
© 1993, 2023, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from Debian's OpenJDK Development Kit package.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Various third party code in OpenJDK is licensed under different licenses (see Debian package).
Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
https://docs.oracle.com/en/java/javase/21/docs/api/java.desktop/javax/swing/text/DefaultStyledDocument.AttributeUndoableEdit.html