public class TextDocument extends BaseDocument<TextDocumentLayout> implements Save, HasUnsavedContent
BaseDocument.OnClosed, BaseDocument.OnFocusGain, BaseDocument.OnFocusLost| Modifier and Type | Field and Description |
|---|---|
protected String |
caretLocationAsText |
protected Charset |
charset |
protected EndLine |
endLine |
protected File |
file |
protected Date |
lastSaved |
protected Date |
lastTextChanged |
protected bibliothek.gui.dock.common.action.CButton |
refreshTitleButton
Кнопка j,yjdbnm
|
protected boolean |
renameTitleOnFileChanged |
protected org.fife.ui.rtextarea.RTextScrollPane |
scrollPane |
protected String |
themeName |
docListeners, eventQueue, focusGainMethods, focusLostMethods, onClosedMethods, psupport, saveTitleButton, uiFinalizers| Constructor and Description |
|---|
TextDocument(TextDocument sample) |
TextDocument(TextDocumentFactory factory) |
TextDocument(TextDocumentFactory factory,
TextDocumentLayout layout) |
| Modifier and Type | Method and Description |
|---|---|
void |
applyTheme(String name) |
void |
clearMarkAllHighlights() |
TextDocument |
clone() |
String |
endLineStatusBar(EndLine endline) |
protected void |
finalize() |
String |
getCaretLocationAsText() |
Charset |
getCharset() |
Long |
getDocumentId() |
EndLine |
getEndLine() |
File |
getFile() |
Date |
getLastSaved() |
Date |
getLastTextChanged() |
TextDocumentLayout |
getLayout()
Создание объекта для сохранения состояния документа
|
org.fife.ui.rtextarea.RTextScrollPane |
getScrollPane() |
String |
getSyntaxEditingStyle() |
org.fife.ui.rsyntaxtextarea.RSyntaxTextArea |
getTextComponent() |
TextService |
getTextService()
Возвращает ссылку на текстовый сервис
|
String |
getThemeName() |
int |
getXCaret() |
int |
getYCaret() |
boolean |
hasFileBackgroundChanges()
Проверяет наличие изменений в файле (по дате).
|
boolean |
hasUnsavedContent()
Проверяет на наличие не сохраненного контента
|
protected void |
initUi() |
boolean |
isRenameTitleOnFileChanged() |
void |
notifyDocumentFocusGained(bibliothek.gui.dock.common.intern.CDockable dockable) |
void |
notifyDocumentFocusLost(bibliothek.gui.dock.common.intern.CDockable dockable) |
void |
onBackgroundFileChanged()
Уведомление о измении файла фоновым процессом
|
void |
open(File file,
Charset cs) |
void |
open(File file,
Charset cs,
boolean fireEvent) |
void |
refresh()
Обновление документа
|
void |
refresh(boolean waitForRefreshed)
Обновление документа
|
void |
renameTitle()
отображает диалог переименование заголовка
|
void |
restore(Reciver<TextDocument> textdoc) |
void |
restore(Reciver<TextDocument> textdoc,
boolean fireEvent) |
protected void |
restore(TextDocumentLayout layout) |
void |
save() |
void |
save(File file,
Charset cs) |
protected void |
save(File file,
Charset cs,
boolean fireEvent) |
void |
saveAs() |
protected void |
selectSyntax(Component statusLabel,
MouseEvent mevent) |
void |
setCaretLocationAsText(String txt) |
void |
setCharset(Charset cs) |
protected void |
setCharset(Charset cs,
boolean fireEvent) |
protected void |
setDocumentId(Long id) |
void |
setEndLine(EndLine endLine) |
protected void |
setEndLine(EndLine endLine,
boolean fireEvent) |
void |
setFile(File file) |
protected void |
setFile(File file,
boolean fireEvent) |
void |
setLastSaved(Date lastSaved) |
protected void |
setLastSaved(Date lastSaved,
boolean fireEvent) |
void |
setLastTextChanged(Date lastTextChanged) |
protected void |
setLastTextChanged(Date lastTextChanged,
boolean fireEvent) |
void |
setRenameTitleOnFileChanged(boolean renameTitleOnFileChanged) |
void |
setSyntaxEditingStyle(String style) |
void |
setThemeName(String themeName) |
addDocumentEvent, addDocumentListener, addDocumentListener, addEvent, addPropertyChange, addPropertyChangeListener, addPropertyChangeListener, close, closed, closing, createDocumentErrorNotifier, createSaveButton, deinstallStatusbar, findOwnCControl, findOwnConsole, findOwnDockingService, findStatusBarService, fireDocumentEvent, fireDocumentEvents, fireEvents, firePropertyChange, focusGained, focusLost, getDocumentListeners, getPropertyChangeListeners, getPropertyChangeListeners, hasDocumentListener, hasListeners, installStatusbar, instances, listenDocumentErrorUI, onClosed, onClosed, removeAllDocumentListeners, removeDocumentListener, removePropertyChangeListener, removePropertyChangeListenergetFactory, isRemoveOnClose, setControlAccess, setRemoveOnCloseadd, add, addAction, addSeparator, asStation, createCommonDockable, getAction, getActionCount, getContentPane, getTitleIcon, getTitleIconHandling, getTitleText, getTitleToolTip, insertAction, insertSeparator, intern, isCloseable, isExternalizable, isMaximizable, isMinimizable, isStackable, remove, removeAction, removeAction, setCloseable, setExternalizable, setLayout, setMaximizable, setMinimizable, setStackable, setTitleIcon, setTitleIconHandling, setTitleText, setTitleToolTipaddCDockableLocationListener, addCDockablePropertyListener, addCDockableStateListener, addDoubleClickListener, addFocusListener, addKeyboardListener, addVetoClosingListener, control, getAction, getAndClearResizeRequest, getAutoBaseLocation, getBaseLocation, getClose, getColors, getControl, getControlAccess, getDefaultLocation, getDockableUniqueId, getExtendedMode, getFocusComponent, getFonts, getGrouping, getMinimizedSize, getParentStation, getWorkingArea, hasParent, init, isDockableVisible, isEnabled, isNormalizeable, isResizeLocked, isResizeLockedHorizontally, isResizeLockedVertically, isShowing, isSingleTabShown, isSticky, isStickySwitchable, isTitleShown, isVisible, propertyListeners, putAction, removeCDockableLocationListener, removeCDockablePropertyListener, removeCDockableStateListener, removeDoubleClickListener, removeFocusListener, removeKeyboardListener, removeVetoClosingListener, setDefaultLocation, setEnabled, setExtendedMode, setFocusComponent, setGrouping, setLocation, setLocationsAside, setLocationsAside, setLocationsAsideFocused, setMinimizedSize, setResizeLocked, setResizeLockedHorizontally, setResizeLockedVertically, setResizeRequest, setResizeRequest, setSingleTabShown, setSticky, setStickySwitchable, setTitleShown, setVisible, setWorkingArea, stateListeners, toFront, toFront, toStringequals, getClass, hashCode, notify, notifyAll, wait, wait, waitaddCDockableLocationListener, addCDockablePropertyListener, addCDockableStateListener, addDoubleClickListener, addFocusListener, addKeyboardListener, addVetoClosingListener, asStation, getAction, getAndClearResizeRequest, getAutoBaseLocation, getBaseLocation, getColors, getControl, getControlAccess, getExtendedMode, getFocusComponent, getFonts, getGrouping, getMinimizedSize, getParentStation, getWorkingArea, hasParent, intern, isCloseable, isDockableVisible, isEnabled, isExternalizable, isMaximizable, isMinimizable, isNormalizeable, isResizeLockedHorizontally, isResizeLockedVertically, isShowing, isSingleTabShown, isStackable, isSticky, isStickySwitchable, isTitleShown, isVisible, removeCDockableLocationListener, removeCDockablePropertyListener, removeCDockableStateListener, removeDoubleClickListener, removeFocusListener, removeKeyboardListener, removeVetoClosingListener, setExtendedMode, setLocation, setLocationsAside, setLocationsAside, setLocationsAsideFocused, setMinimizedSize, setSticky, setStickySwitchable, setVisible, setWorkingAreaprotected String themeName
protected volatile org.fife.ui.rtextarea.RTextScrollPane scrollPane
protected String caretLocationAsText
protected boolean renameTitleOnFileChanged
protected volatile File file
protected volatile Charset charset
protected EndLine endLine
protected Date lastTextChanged
protected Date lastSaved
protected bibliothek.gui.dock.common.action.CButton refreshTitleButton
public TextDocument(TextDocumentFactory factory)
public TextDocument(TextDocumentFactory factory, TextDocumentLayout layout)
public TextDocument(TextDocument sample)
public TextService getTextService()
public Long getDocumentId()
protected void setDocumentId(Long id)
public TextDocument clone()
protected void finalize()
throws Throwable
protected void initUi()
public String getThemeName()
public void setThemeName(String themeName)
public void applyTheme(String name)
public void notifyDocumentFocusGained(bibliothek.gui.dock.common.intern.CDockable dockable)
public void notifyDocumentFocusLost(bibliothek.gui.dock.common.intern.CDockable dockable)
protected void restore(TextDocumentLayout layout)
public TextDocumentLayout getLayout()
BaseDocumentgetLayout in class BaseDocument<TextDocumentLayout>public org.fife.ui.rtextarea.RTextScrollPane getScrollPane()
public org.fife.ui.rsyntaxtextarea.RSyntaxTextArea getTextComponent()
public String getSyntaxEditingStyle()
public void setSyntaxEditingStyle(String style)
protected void selectSyntax(Component statusLabel, MouseEvent mevent)
public int getYCaret()
public int getXCaret()
public String getCaretLocationAsText()
public void setCaretLocationAsText(String txt)
public boolean isRenameTitleOnFileChanged()
public void setRenameTitleOnFileChanged(boolean renameTitleOnFileChanged)
public File getFile()
public void setFile(File file)
protected void setFile(File file, boolean fireEvent)
public Charset getCharset()
public void setCharset(Charset cs)
protected void setCharset(Charset cs, boolean fireEvent)
public EndLine getEndLine()
public void setEndLine(EndLine endLine)
protected void setEndLine(EndLine endLine, boolean fireEvent)
public Date getLastTextChanged()
public void setLastTextChanged(Date lastTextChanged)
protected void setLastTextChanged(Date lastTextChanged, boolean fireEvent)
public Date getLastSaved()
public void setLastSaved(Date lastSaved)
protected void setLastSaved(Date lastSaved, boolean fireEvent)
public boolean hasUnsavedContent()
HasUnsavedContenthasUnsavedContent in interface HasUnsavedContentpublic void restore(Reciver<TextDocument> textdoc, boolean fireEvent)
public void restore(Reciver<TextDocument> textdoc)
public void saveAs()
public void onBackgroundFileChanged()
public void refresh()
public void refresh(boolean waitForRefreshed)
waitForRefreshed - Параметр актуален для не AWT треда. public boolean hasFileBackgroundChanges()
public void clearMarkAllHighlights()
public void renameTitle()
Copyright © 2018. All rights reserved.