Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
2.0
-
None
-
None
Description
Create a small TextArea filled with long text overflowing the TextArea, then use your mouse to drag-select text and try to select out of the TextArea, then IndexOutOfBoundsException is raised:
java.lang.IndexOutOfBoundsException: index 1 out of bounds.
at org.apache.pivot.collections.ArrayList.verifyIndexBounds(ArrayList.java:577)
at org.apache.pivot.collections.ArrayList.get(ArrayList.java:346)
at org.apache.pivot.wtk.skin.TextAreaSkinParagraphView.getRowInsertionPoint(TextAreaSkinParagraphView.java:313)
at org.apache.pivot.wtk.skin.TextAreaSkinParagraphView.getInsertionPoint(TextAreaSkinParagraphView.java:288)
at org.apache.pivot.wtk.skin.TextAreaSkin.getInsertionPoint(TextAreaSkin.java:322)
at org.apache.pivot.wtk.skin.TextAreaSkin.mouseMove(TextAreaSkin.java:715)
at org.apache.pivot.wtk.Component$ComponentMouseListenerList.mouseMove(Component.java:433)
at org.apache.pivot.wtk.Component.mouseMove(Component.java:2721)
at org.apache.pivot.wtk.ApplicationContext$DisplayHost.processMouseMotionEvent(ApplicationContext.java:1048)
at java.awt.Component.processEvent(Component.java:6032)
at org.apache.pivot.wtk.ApplicationContext$DisplayHost.processEvent(ApplicationContext.java:709)
at java.awt.Component.dispatchEventImpl(Component.java:4630)
at java.awt.Component.dispatchEvent(Component.java:4460)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4574)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4255)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)
at java.awt.Container.dispatchEventImpl(Container.java:2085)
at java.awt.Window.dispatchEventImpl(Window.java:2478)
at java.awt.Component.dispatchEvent(Component.java:4460)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
This also happens for a TextArea inside ScrollPane.
This exception seems to occur only for some fonts. For my case, exception didn't occur for my English font, but did occur for my Japanese font.