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 257185 - NullPointerException at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.mouseWheelMoved
Summary: NullPointerException at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.mous...
Alias: None
Product: editor
Classification: Unclassified
Component: Painting & Printing (show other bugs)
Version: 8.1
Hardware: All All
: P1 normal with 2 votes (vote)
Assignee: Miloslav Metelka
: 258215 262578 269591 (view as bug list)
Depends on:
Reported: 2015-12-16 23:44 UTC by _ hildo
Modified: 2018-05-04 15:56 UTC (History)
83 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 221015

stacktrace (2.55 KB, text/plain)
2015-12-16 23:44 UTC, _ hildo
stacktrace (2.83 KB, text/plain)
2016-08-03 14:25 UTC, skygo
Screen shot of editor marging - missing line numbers (83.82 KB, image/png)
2016-10-18 23:43 UTC, aplatypus
stacktrace (2.83 KB, text/plain)
2018-01-22 12:44 UTC, aquaglia
stacktrace (2.83 KB, text/plain)
2018-04-11 12:29 UTC, jyeary

Note You need to log in before you can comment on or make changes to this bug.
Description _ hildo 2015-12-16 23:44:21 UTC
Build: NetBeans IDE 8.1 (Build 201510222201)
VM: OpenJDK 64-Bit Server VM, 25.51-b03, OpenJDK Runtime Environment, 1.8.0_51-b16
OS: Windows 7

User Comments:
GUEST: scrolling suddenly stopped,
I was writing java application and alt-tabing and I got this error.

hildo: Just scrolling through my java source file, using my wheel mouse.

GUEST: no description

GUEST: no idea

GUEST: MouseWheel stops to work after some time using the new 8.1 version.

GUEST: Random

GUEST: ... (Third time submitting the same error) I have a .java code with lots of regex on them...

GUEST: After netbeans was idle in background and when the code panel was taking up the entire screen, the side panels (Projects, Services, Files) icon side changed... WINDOWS 10

GUEST: Brought netbeans up from background

GUEST: scrolling doesn't work often

GUEST: The mouse wheel stopped working

GUEST: Again, just editing.... wish I couold figure out exactly the steps that generate this

GUEST: Was scrolling my mouse after checking the same error submitted online... WINDOWS 10

GUEST: No idea, but after this the mouse right button stopped working inside source tab

   at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.mouseWheelMoved(
   at java.awt.AWTEventMulticaster.mouseWheelMoved(
   at java.awt.Component.processMouseWheelEvent(
   at java.awt.Component.processEvent(
   at java.awt.Container.processEvent(
   at java.awt.Component.dispatchEventImpl(
Comment 1 _ hildo 2015-12-16 23:44:23 UTC
Created attachment 157819 [details]
Comment 2 markiewb 2016-07-27 21:53:47 UTC
*** Bug 258215 has been marked as a duplicate of this bug. ***
Comment 3 markiewb 2016-07-27 21:53:57 UTC
*** Bug 262578 has been marked as a duplicate of this bug. ***
Comment 4 skygo 2016-08-03 14:25:23 UTC
Created attachment 161549 [details]

scrolling on java file
Comment 5 Exceptions Reporter 2016-10-18 10:02:33 UTC
This bug already has 200 duplicates 
Comment 6 aplatypus 2016-10-18 23:43:37 UTC
Created attachment 162547 [details]
Screen shot of editor marging - missing line numbers

Theis window is generating NullPointerExceptions when I click on it from another window.
Comment 7 Milutin Kristofic 2016-10-23 14:36:02 UTC
I was trying really hard to reproduce this bug in Windows system, but it didn't happen. I check the code and only reasonable fix was this:

If it doesn't help and do you have a time, so you can run netbeans with -J-Dorg.netbeans.modules.editor.lib2.view.DocumentViewOp.level=500 and then messages.log after NPE will be very helpful.
Comment 8 Quality Engineering 2016-10-25 01:56:54 UTC
Integrated into 'main-silver', will be available in build *201610250002* on (upload may still be in progress)

User: Milutin Kristofic <>
Log: #257185 - NullPointerException at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.mouseWheelMoved
Comment 9 terje7601 2017-02-08 10:31:12 UTC
This issue is still present in NetBeans 8.2. I'm reopening since NetBeans' Exception Reporter keeps adding the reports to this issue, but still hasn't created a new issue for it (even though there have been hundreds of reports since this was marked as fixed). I also filed issue 269591 for this a couple of weeks ago, but nothing happened to it since.

This issue causes:
* line numbers to disappear
* the editor to jump back to the top while scrolling
* Find (Ctrl+F) to stop working
* ...
Comment 10 Exceptions Reporter 2017-02-16 06:24:24 UTC
This bug already has 750 duplicates 
Comment 11 _ gtzabari 2017-02-24 15:41:54 UTC
The VERSION field corresponds to when this bug was first reported. Please do not alter its value.
Comment 12 Miloslav Metelka 2017-03-29 15:48:01 UTC
Hopefully fixed but I'm not able to reproduce the problem so please verify once the fix gets into dev builds. Thanks.
Comment 13 terje7601 2017-03-29 16:44:30 UTC
*** Bug 269591 has been marked as a duplicate of this bug. ***
Comment 14 Quality Engineering 2017-03-31 01:50:06 UTC
Integrated into 'main-silver', will be available in build *201703310002* on (upload may still be in progress)

User: Miloslav Metelka <>
Log: #257185 - NullPointerException at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.mouseWheelMoved.
Comment 15 _ gtzabari 2017-07-20 14:01:18 UTC
Please do not open issues that have been closed in past releases. If you are still experiencing this bug, please open a new bug report.
Comment 16 Rohaan427 2017-08-30 00:57:12 UTC
This is happening in NetBeans 8.2 (JDK 1.8.0_144 and 1.8.0_131) so it should be reopened (or opened for NetBeans 8.2). When I submitted the exceptions through NetBeans 8.2, it assigned the reports to this bug.
Comment 17 marw 2017-10-10 20:21:43 UTC
This was reopened automatically after submitting report. Here also in 8.2
Comment 18 Exceptions Reporter 2017-11-03 18:52:38 UTC
This bug already has 2100 duplicates 
Comment 19 aquaglia 2018-01-22 12:44:04 UTC
Created attachment 165616 [details]

Trying to run a JUnit test
Comment 20 jyeary 2018-04-11 12:29:49 UTC
Created attachment 165700 [details]

I was updating a Java file.