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 216906 - javax.swing.text.BadLocationException: Wrong remove position -1 < 0
Summary: javax.swing.text.BadLocationException: Wrong remove position -1 < 0
Status: RESOLVED FIXED
Alias: None
Product: web
Classification: Unclassified
Component: HTML Editor (show other bugs)
Version: 7.3
Hardware: All All
: P3 normal (vote)
Assignee: Marek Fukala
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-15 09:13 UTC by Vladimir Riha
Modified: 2012-10-08 13:29 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 191557


Attachments
stacktrace (7.65 KB, text/plain)
2012-08-15 09:13 UTC, Vladimir Riha
Details
stacktrace (7.55 KB, text/plain)
2012-09-04 13:53 UTC, Kenneth Ganfield
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Riha 2012-08-15 09:13:23 UTC
This issue was reported manually by vriha.
It already has 1 duplicates 


Build: NetBeans IDE Dev (Build EaselCSS-497-on-20120814)
VM: Java HotSpot(TM) Client VM, 23.2-b09, Java(TM) SE Runtime Environment, 1.7.0_06-b24
OS: Linux

User Comments:
vriha: Caused by:
- have following snippet:  <li class="todo">
- put cursor inside the "todo"
- in Rule Editor window press Add Property and add some property




Stacktrace: 
javax.swing.text.BadLocationException: Wrong remove position -1 < 0
   at org.netbeans.editor.BaseDocument.handleRemove(BaseDocument.java:918)
   at org.netbeans.editor.BaseDocument$FilterBypassImpl.remove(BaseDocument.java:2404)
   at javax.swing.text.DocumentFilter.remove(DocumentFilter.java:79)
   at org.openide.text.CloneableEditorSupport$DocFilter.remove(CloneableEditorSupport.java:3031)
   at org.netbeans.editor.BaseDocument.remove(BaseDocument.java:901)
   at org.netbeans.modules.css.model.api.Model.applyChanges(Model.java:373)
Comment 1 Vladimir Riha 2012-08-15 09:13:25 UTC
Created attachment 123138 [details]
stacktrace
Comment 2 Vladimir Riha 2012-08-15 09:14:23 UTC
similar case happens with following code:

<li style="font:12px;">
Comment 3 Kenneth Ganfield 2012-09-04 13:53:01 UTC
Created attachment 123882 [details]
stacktrace

using new rule dialob
Comment 4 Marek Fukala 2012-10-08 13:29:42 UTC
fixed as the rule editor shows nothing when the class or id attribute in html code is selected.