IMEDocument Class
- public class IMEDocument
extends PlainDocument
A Document implementation that can be used with input from IME
Fix for bugs 25338 & 24878
Swing's version of handleInsertString does not support IME's well
This class returns a document which overrides insertString
making a copy of the attribute set that doesn't mention
ComposedTextAttribute but stores whether it saw the
the ComposedTextAttribute on the way in and if so does not pass
on UndoableEditEvents
-
Hierarchy
-
Object
AbstractDocument
PlainDocument
IMEDocument
-
All Implemented Interfaces
-
Document
, Serializable
Methods from javax.swing.text.AbstractDocument |
addDocumentListener, addUndoableEditListener, createBranchElement, createLeafElement, createPosition, dump, fireChangedUpdate, fireInsertUpdate, fireRemoveUpdate, getAsynchronousLoadPriority, getAttributeContext, getBidiRootElement, getContent, getCurrentWriter, getDefaultRootElement, getDocumentFilter, getDocumentListeners, getDocumentProperties, getEndPosition, getLength, getListeners, getParagraphElement, getProperty, getRootElements, getStartPosition, getText, getText, getUndoableEditListeners, insertString, insertUpdate, postRemoveUpdate, putProperty, readLock, readUnlock, remove, removeDocumentListener, removeUndoableEditListener, removeUpdate, render, replace, setAsynchronousLoadPriority, setDocumentFilter, setDocumentProperties, writeLock, writeUnlock |
Methods from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods from interface javax.swing.text.Document |
addDocumentListener, addUndoableEditListener, createPosition, getDefaultRootElement, getEndPosition, getLength, getProperty, getRootElements, getStartPosition, getText, getText, insertString, putProperty, remove, removeDocumentListener, removeUndoableEditListener, render |
_isComposedText
protected boolean _isComposedText
IMEDocument
public IMEDocument()
fireUndoableEditUpdate(UndoableEditEvent) Method
public void fireUndoableEditUpdate(UndoableEditEvent
e)
-
Overrides
-
AbstractDocument.fireUndoableEditUpdate(UndoableEditEvent)
insertString(int, String, AttributeSet) Method
public void insertString(int offs,
String
str,
AttributeSet
a)
throws BadLocationException
-
Overrides
-
PlainDocument.insertString(int, String, AttributeSet)
Exceptions
-
BadLocationException
isComposedText(AttributeSet) Method
protected boolean isComposedText(AttributeSet
attr)