harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mark Hindess (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-2744) [classlib][swing] j.s.text.Utilities.getNextWord throws IllegalArgumentException rather than BadLocationException
Date Tue, 16 Jan 2007 15:59:27 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-2744?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465186
] 

Mark Hindess commented on HARMONY-2744:
---------------------------------------

Ignore me.  I know what I did wrong now.  Testing and hopefully committing shortly.


> [classlib][swing] j.s.text.Utilities.getNextWord throws IllegalArgumentException rather
than BadLocationException
> -----------------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-2744
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2744
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Alexey A. Ivanov
>         Attachments: H2744-j.s.text.UtilitiesTest.patch, H2744-o.a.h.awt.text.TextUtils.patch
>
>
> javax.swing.text.Utilities.getNextWord(JTextComponent, int) throws IllegalArgumentException
where RI throws BadLocationException.
> To reproduce, use the following code:
> Utilities.getNextWord(new JEditorPane("text/plain", ""), 0);
> ------- Harmony -------
> java.lang.IllegalArgumentException
> 	at java.text.RuleBasedBreakIterator.validateOffset(RuleBasedBreakIterator.java:71)
> 	at java.text.RuleBasedBreakIterator.following(RuleBasedBreakIterator.java:61)
> 	at org.apache.harmony.awt.text.TextUtils.getNextWord(TextUtils.java:144)
> 	at javax.swing.text.Utilities.getNextWord(Utilities.java:49)
> ------- end -------
> ------- RI -------
> javax.swing.text.BadLocationException: No more words
> 	at javax.swing.text.Utilities.getNextWordInParagraph(Utilities.java:524)
> 	at javax.swing.text.Utilities.getNextWord(Utilities.java:498)
> ------- end -------

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message