Bug 161278 - IllegalArgumentException thrown by StyledText.getLineAtOffset
Summary: IllegalArgumentException thrown by StyledText.getLineAtOffset
Status: RESOLVED INVALID
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Text (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-Text-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2006-10-17 12:09 EDT by Simon Archer CLA
Modified: 2007-06-22 10:04 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Archer CLA 2006-10-17 12:09:58 EDT
I'm sorry, but there is not much to tell, apart from the fact that I was typing in a StyledText widget.  Having searched for related bugs, this could very well be a duplicate, but everything I saw looked to be resolved.  This sort of bug is rather tricky to report, and likely even trickier to fix.

!ENTRY org.eclipse.ui 4 0 2006-10-17 12:03:44.081
!MESSAGE Index out of bounds
!STACK 0
java.lang.IllegalArgumentException: Index out of bounds
	at org.eclipse.swt.SWT.error(SWT.java:3358)
	at org.eclipse.swt.SWT.error(SWT.java:3297)
	at org.eclipse.swt.SWT.error(SWT.java:3268)
	at org.eclipse.swt.custom.StyledText.getLineAtOffset(StyledText.java:3334)
	at org.eclipse.jface.text.source.OverviewRuler.doPaint1(OverviewRuler.java:653)
	at org.eclipse.jface.text.source.OverviewRuler.doubleBufferPaint(OverviewRuler.java:479)
	at org.eclipse.jface.text.source.OverviewRuler.access$6(OverviewRuler.java:456)
	at org.eclipse.jface.text.source.OverviewRuler$1.paintControl(OverviewRuler.java:390)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:83)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:952)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:937)
	at org.eclipse.swt.widgets.Composite.WM_PAINT(Composite.java:1285)
	at org.eclipse.swt.widgets.Control.windowProc(Control.java:3299)
	at org.eclipse.swt.widgets.Display.windowProc(Display.java:4025)
	at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method)
	at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java:1923)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2966)
	at org.eclipse.jface.window.Window.runEventLoop(Window.java:820)
	at org.eclipse.jface.window.Window.open(Window.java:796)
	at org.eclipse.ui.internal.dialogs.AboutDialog$1.run(AboutDialog.java:122)
	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:67)
	at org.eclipse.ui.internal.dialogs.AboutDialog.buttonPressed(AboutDialog.java:120)
	at org.eclipse.jface.dialogs.Dialog$3.widgetSelected(Dialog.java:660)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:90)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968)
	at org.eclipse.jface.window.Window.runEventLoop(Window.java:820)
	at org.eclipse.jface.window.Window.open(Window.java:796)
	at org.eclipse.ui.internal.about.AboutAction.run(AboutAction.java:70)
	at org.eclipse.jface.action.Action.runWithEvent(Action.java:499)
	at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:539)
	at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488)
	at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1914)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1878)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:419)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:95)
	at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
	at org.eclipse.core.launcher.Main.run(Main.java:977)
	at org.eclipse.core.launcher.Main.main(Main.java:952)
Comment 1 Felipe Heidrich CLA 2006-10-17 12:49:27 EDT
JFace text is calling StyledText with a invalid offset.
What version of Eclipse are you running ?
Comment 2 Simon Archer CLA 2006-10-17 12:53:02 EDT
Version: 3.2.0
Build id: M20060629-1905
Comment 3 Dani Megert CLA 2006-10-18 02:40:15 EDT
Sorry nothing I can do here. I need at least
- component (editor, dialog, wizard, etc) in which it happened
- build id

See also:
http://www.eclipse.org/eclipse/platform-text/development/bug-incomplete.htm

Note that we have fixed bug 134227 for 3.2 so if this happened < 3.2 it might be fixed already.
Comment 4 Dani Megert CLA 2006-10-18 03:11:13 EDT
I attached comment 3 before I read comment 2. So, we have the build ID but not yet where the StyledText and the ruler are used.
Comment 5 Dani Megert CLA 2007-06-22 09:59:35 EDT
Get rid of deprecated state.
Comment 6 Dani Megert CLA 2007-06-22 10:04:47 EDT
.