This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 3273 - Insert string to EMPTY StyledDocument throws Exception from org.openide.text.LineStruct.
Summary: Insert string to EMPTY StyledDocument throws Exception from org.openide.text....
Status: CLOSED FIXED
Alias: None
Product: ide
Classification: Unclassified
Component: Code (show other bugs)
Version: 3.x
Hardware: All All
: P3 normal (vote)
Assignee: _ lkramolis
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 1999-08-10 21:59 UTC by _ lkramolis
Modified: 2003-07-02 16:01 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ lkramolis 1999-08-10 21:59:14 UTC
Code:
    EditorSupport es = (EditorSupport)getCookie (EditorSupport.class);
    StyledDocument sdoc = es.getDocument();
>>  sdoc.remove (0, sdoc.getLength()); <<
>>  sdoc.insertString (0, some_string, null); <<

Exception:
java.util.NoSuchElementException

        at java.util.LinkedList$ListItr.previous(LinkedList.java:492)
        at org.openide.text.LineStruct$Info.insert(LineStruct.java:108)
        at org.openide.text.LineStruct.insertLinesImpl(LineStruct.java:353)
        at org.openide.text.LineStruct.access$1(LineStruct.java:347)
        at org.openide.text.LineStruct$1.run(LineStruct.java:306)
        at org.openide.util.Task.run(Task.java:127)
        at org.openide.util.RequestProcessor$ProcessorThread.run(RequestProcessor.java:408)
Comment 1 Quality Engineering 2003-07-02 15:57:05 UTC
Resolved for 3.4.x or earlier, no new info since then -> verify.
Comment 2 Quality Engineering 2003-07-02 16:01:55 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.