Package snap.text
Class TextDoc
java.lang.Object
snap.props.PropObject
snap.text.TextBlock
snap.text.TextDoc
- All Implemented Interfaces:
CharSequence
,Cloneable
,PropChange.DoChange
,CharSequenceX
,XMLArchiver.Archivable
This class is the basic text storage class, holding a list of TextLine.
-
Field Summary
Fields inherited from class snap.text.TextBlock
_defaultLineStyle, _defaultTextStyle, _length, _lines, _mouseY, _prefW, _propChangeEnabled, Chars_Prop, DefaultTextStyle_Prop, LineStyle_Prop, Style_Prop, TextModified_Prop
Fields inherited from class snap.props.PropObject
_pcs, EMPTY_OBJECT
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the source file.Returns the source URL.void
readFromSourceURL
(WebURL aURL) Load TextDoc from source URL.void
setSourceURL
(WebURL aURL) Sets the Source URL.void
Write TextDoc text to source file.Methods inherited from class snap.text.TextBlock
activateUndo, addChars, addChars, addCharsToLine, addCharsWithStyle, addCharsWithStyle, addLine, addTextBlock, charAt, clear, clone, copyForRange, createLine, createTokensForTextLine, firePropChange, fromXML, getAlignedY, getAlignX, getBounds, getCharIndexForXY, getDefaultFont, getDefaultLineStyle, getDefaultTextColor, getDefaultTextStyle, getEndCharIndex, getFontForCharIndex, getHeight, getLastLine, getLine, getLineCount, getLineForCharIndex, getLineForY, getLineLongest, getLines, getLineStyleForCharIndex, getMaxX, getMaxY, getPathForCharRange, getPrefHeight, getPrefWidth, getPrefWidthForStartCharIndex, getRunForCharIndex, getRunForCharRange, getRunIterForCharRange, getSourceText, getStartCharIndex, getString, getTextStyleForCharIndex, getTextStyleForCharRange, getTokenForCharIndex, getUnderlineRuns, getUndoer, getWidth, getX, getY, indexOf, isPropChangeEnabled, isRichText, isTextModified, isUnderlined, joinLineWithNextLine, length, moveLineCharsToNextLine, paint, paintLine, redo, removeChars, removeCharsFromLine, removeLine, replaceChars, replaceChars, resetLineYForLinesAfterIndex, scaleFonts, setAlignX, setBounds, setBounds, setDefaultFont, setDefaultLineStyle, setDefaultTextColor, setDefaultTextStyle, setHeight, setLineStyle, setLineStyleValue, setPropChangeEnabled, setRichText, setString, setStyleValue, setStyleValue, setStyleValue, setTextModified, setTextStyle, setUnderlined, setWidth, setX, setY, splitLineAtIndex, subSequence, toStringProps, toXML, undo, undoerAddPropChange, updateLine, updateLines
Methods inherited from class snap.props.PropObject
addDeepChangeListener, addPropChangeListener, addPropChangeListener, firePropChange, firePropChange, getPropDefault, getPropForName, getPropParent, getPropSet, getPropsForArchival, getPropsForArchivalExtra, getPropsString, getPropValue, initProps, isPropDefault, processPropChange, removeDeepChangeListener, removePropChangeListener, removePropChangeListener, setPropsString, setPropValue, setPropValues, toString
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.CharSequence
chars, codePoints, isEmpty, toString
Methods inherited from interface snap.util.CharSequenceX
getIndentLength, getIndentString, getLastChar, indexAfterNewline, indexAfterNewlineOrEnd, indexOfNewline, isAfterLineEnd, isLastCharNewline, isLineEnd, isLineEndChar, isWhiteSpace, lastIndexAfterNewline, lastIndexOfNewline, startsWith
-
Constructor Details
-
TextDoc
public TextDoc()Constructor.
-
-
Method Details
-
getSourceURL
Returns the source URL. -
setSourceURL
Sets the Source URL. -
getSourceFile
Returns the source file. -
readFromSourceURL
Load TextDoc from source URL. -
writeToSourceFile
public void writeToSourceFile()Write TextDoc text to source file.
-