Package org.omegat.gui.editor
Class ViewParagraph
- java.lang.Object
-
- javax.swing.text.View
-
- javax.swing.text.CompositeView
-
- javax.swing.text.BoxView
-
- javax.swing.text.FlowView
-
- javax.swing.text.ParagraphView
-
- org.omegat.gui.editor.ViewParagraph
-
- All Implemented Interfaces:
javax.swing.SwingConstants
,javax.swing.text.TabExpander
public class ViewParagraph extends javax.swing.text.ParagraphView
Custom breakspots processing required only for word wrapping issue fix: on the editing line with wordwrap, add a new line at the beginning of the line and write something, the word wrapping behaves in a strange way. If you paste a long line (wrapped one), the word wrap disappears and the line gets looong. JDK bug 6539700(http://bugs.sun.com/view_bug.do?bug_id=6539700) : JTextPane line wrap radically different from previous versions in jre 1.5.0_10+. Fixed in Java 7b70.
-
-
Constructor Summary
Constructors Constructor Description ViewParagraph(javax.swing.text.Element elem)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
changedUpdate(javax.swing.event.DocumentEvent e, java.awt.Shape a, javax.swing.text.ViewFactory f)
void
insertUpdate(javax.swing.event.DocumentEvent e, java.awt.Shape a, javax.swing.text.ViewFactory f)
void
removeUpdate(javax.swing.event.DocumentEvent e, java.awt.Shape a, javax.swing.text.ViewFactory f)
-
Methods inherited from class javax.swing.text.ParagraphView
breakView, getAlignment, getBreakWeight, getFlowSpan, getFlowStart, nextTabStop, paint
-
Methods inherited from class javax.swing.text.BoxView
getAxis, getChildAllocation, getHeight, getMaximumSpan, getMinimumSpan, getPreferredSpan, getResizeWeight, getWidth, layoutChanged, modelToView, preferenceChanged, replace, setAxis, setSize, viewToModel
-
Methods inherited from class javax.swing.text.CompositeView
getNextVisualPositionFrom, getView, getViewCount, getViewIndex, modelToView
-
Methods inherited from class javax.swing.text.View
append, breakView, createFragment, getAttributes, getBreakWeight, getContainer, getDocument, getElement, getEndOffset, getGraphics, getParent, getStartOffset, getToolTipText, getViewFactory, getViewIndex, insert, isVisible, modelToView, remove, removeAll, viewToModel
-
-
-
-
Method Detail
-
removeUpdate
public void removeUpdate(javax.swing.event.DocumentEvent e, java.awt.Shape a, javax.swing.text.ViewFactory f)
- Overrides:
removeUpdate
in classjavax.swing.text.FlowView
-
insertUpdate
public void insertUpdate(javax.swing.event.DocumentEvent e, java.awt.Shape a, javax.swing.text.ViewFactory f)
- Overrides:
insertUpdate
in classjavax.swing.text.FlowView
-
changedUpdate
public void changedUpdate(javax.swing.event.DocumentEvent e, java.awt.Shape a, javax.swing.text.ViewFactory f)
- Overrides:
changedUpdate
in classjavax.swing.text.ParagraphView
-
-