Package org.fxmisc.richtext.model
Class RichTextChange<PS,SEG,S>
- java.lang.Object
-
- org.fxmisc.richtext.model.TextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
-
- org.fxmisc.richtext.model.RichTextChange<PS,SEG,S>
-
public class RichTextChange<PS,SEG,S> extends TextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
An object that specifies where a change occurred in aGenericStyledArea.
-
-
Field Summary
-
Fields inherited from class org.fxmisc.richtext.model.TextChange
inserted, position, removed
-
-
Constructor Summary
Constructors Constructor Description RichTextChange(int position, StyledDocument<PS,SEG,S> removed, StyledDocument<PS,SEG,S> inserted)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected StyledDocument<PS,SEG,S>concat(StyledDocument<PS,SEG,S> a, StyledDocument<PS,SEG,S> b)protected RichTextChange<PS,SEG,S>create(int position, StyledDocument<PS,SEG,S> removed, StyledDocument<PS,SEG,S> inserted)booleanequals(Object other)protected intinsertedLength()booleanisPlainTextIdentity()Equivalent torichChange.toPlainTextChange().isIdentity()but without the additional object creation viatoPlainTextChange().protected intremovedLength()static voidskipStyleComparison(boolean value)protected StyledDocument<PS,SEG,S>sub(StyledDocument<PS,SEG,S> doc, int from, int to)PlainTextChangetoPlainTextChange()-
Methods inherited from class org.fxmisc.richtext.model.TextChange
getInserted, getInsertionEnd, getNetLength, getPosition, getRemovalEnd, getRemoved, hashCode, invert, isIdentity, mergeWith, toString
-
-
-
-
Constructor Detail
-
RichTextChange
public RichTextChange(int position, StyledDocument<PS,SEG,S> removed, StyledDocument<PS,SEG,S> inserted)
-
-
Method Detail
-
removedLength
protected int removedLength()
- Specified by:
removedLengthin classTextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
-
insertedLength
protected int insertedLength()
- Specified by:
insertedLengthin classTextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
-
concat
protected final StyledDocument<PS,SEG,S> concat(StyledDocument<PS,SEG,S> a, StyledDocument<PS,SEG,S> b)
- Specified by:
concatin classTextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
-
sub
protected final StyledDocument<PS,SEG,S> sub(StyledDocument<PS,SEG,S> doc, int from, int to)
- Specified by:
subin classTextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
-
create
protected final RichTextChange<PS,SEG,S> create(int position, StyledDocument<PS,SEG,S> removed, StyledDocument<PS,SEG,S> inserted)
- Specified by:
createin classTextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
-
toPlainTextChange
public final PlainTextChange toPlainTextChange()
-
isPlainTextIdentity
public final boolean isPlainTextIdentity()
Equivalent torichChange.toPlainTextChange().isIdentity()but without the additional object creation viatoPlainTextChange().
-
skipStyleComparison
public static void skipStyleComparison(boolean value)
-
equals
public boolean equals(Object other)
- Overrides:
equalsin classTextChange<StyledDocument<PS,SEG,S>,RichTextChange<PS,SEG,S>>
-
-