CodeGlancePro
CodeGlancePro copied to clipboard
[BUG] Laggy scrolling when NOT using CodeGlance Pro
Which Glance version and IDEA version?
PHPStorm 2022.1.3 build 221.5921.28 CodeGlance Pro 1.4.1
What steps will reproduce the issue?
- Start a fresh installation of PHPStorm (or similar).
- Scroll a long file - scrolling is smooth.
- Install CodeGlance Pro and enable it - scrolling is smooth.
- Disable CodeGlance Pro - scrolling is laggy/janky.
- Disable the CodeGlance Pro plugin - restart IDE - scrolling is laggy/janky.
- Uninstall CodeGlance Pro plugin - restart IDE - scrolling is STILL laggy/janky.
It seems like CodeGlance Pro changes the IDE settings in some way that affects scrolling performance, even when CodeGlance Pro is disabled or uninstalled.
Furthermore, scrolling large files with CodeGlance Pro enabled is a bit laggy. On a fresh IDE it's very smooth even for large files. In my opinion this is not an issue as long as I can temporarily disable CodeGlance Pro for large files to make scrolling smooth, like the default. But instead scrolling is always laggy/janky when CodeGlance Pro is disabled.
https://user-images.githubusercontent.com/2036475/176000120-d0e5de3d-26fe-469c-b03d-8eaca29e42e1.mp4
Actually I managed to fix my issue with scroll lagging on large files with CodeGlance Pro ON. My GPU was in power-save mode which was affecting performance.
But the main issue still remains. When I turn CodeGlance Pro OFF, scrolling is noticeably more laggy. And it remains so even after uninstalling CodeGlance Pro.
With this bug I'm stuck using your plugin. Luckily it's a great plugin! 😂
OK, I'll try this mode later
Did you check this?
I don't use Power Save Mode. It looks like smooth scrolling is disabled completely when it's enabled.
yes,it is. Is your system macos?
No, I use Linux. I have a very decent desktop PC. I use PHPStorm on my main 144hz monitor, and I have a second 75hz monitor.
The bug is a lot easier to see on my 144hz monitor because it's very smooth when ON, and not smooth at all when OFF. On my 75hz monitor the difference is harder to see because it's not as smooth to begin with.
But if you scroll up and down with the mouse wheel really fast you can see the difference. Sometimes I had to turn CodeGlance OFF/ON a few times before the scrolling started lagging.
It's so strange that I can't reproduce your problem.😂I checked the IDE code and found that only Power Save Mode will not smooth when the opening.
It's not turning off smooth scrolling, it's more like the FPS performance of smooth scrolling drops when CodeGlance is OFF.
I only know that when the CodeGlance will renaint when the scrolling occurs.
I added a judgment in the repaint
fun shouldNotUpdate() = isDisabled || project.isDisposed || (!config.hoveringToShowScrollBar && !isVisible)
if i remove the (!config.hoveringToShowScrollBar && !isVisible)
then you try the scrolling?(use the hide and show button)
CodeGlance Pro-1.4.1.zip
No change unfortunately.
Here's another video actually showing the FPS drop. Notice that FPS stays around 120 with CodeGlance open, and it drops to ~30 FPS with CodeGlance closed.
https://user-images.githubusercontent.com/2036475/176224108-a7930c70-acf3-4f14-a936-0f1fb349925f.mp4
Note that FPS is slightly more reduced due to recording.
It also seems like performance is affected the more complex the editor content is, i.e. long file with lots of syntax highlighting and warnings/errors.
Okay, I see. Probably the fps will be reduced when there is only an editor. This should be asked the official. I guess jbr judged that there are graphics, so it uses high fps?
The problem is, on a new installation of PhpStorm (or other IDE), there is no FPS issue. It's 100% smooth.
After you install and use CodeGlance Pro, the issue begins. When you disable or uninstall CodeGlance Pro, the issue persists.
So there's no issue until CodeGlance Pro is installed, and you can't fix it even by uninstalling CodeGlance Pro.
In any case, this is not an urgent issue for me because I love CodeGlance Pro and will continue to use it.
It's only a problem if I ever decide to stop using CodeGlance Pro 😆
At this point I'm just reporting it for you to be aware of. Please don't worry about trying to fix it urgently on my account.
ok,thanks. Emmm, has this problem appeared in previous versions?
I tested older version of PhpStorm yesterday, back to 2019 versions, and the same issue happens.
I also tested the other CodeGlance2 and CodeGlance3 plugins, and the same issue happens.
But I tested CodeGlance2 and CodeGlance3 after already using CodeGlance Pro, so I'm not sure. I didn't test them on a fresh install.
ok,thanks.i will check
I want to ask what FPS monitoring software you use?
I used MangoHud. It only works on Linux as far as I know.
On Windows I believe Fraps is a popular choice.
https://youtrack.jetbrains.com/issue/IDEA-267820 hi,check this.smooth scroll options.Whether it is useful
I guess this is a special situation, because my monitor is also a 144Hz display, and not happen this issues. I didn’t find the application that can open FPS on Windows,most of using in game,and FRAPS doesn’t work. Sorry cant help you
https://user-images.githubusercontent.com/26132153/176464622-a503fda3-8d11-459d-9804-90d23b2d89ea.mp4
Hmm I see. I guess it could be specific to Linux, or PhpStorm, or compatibility with another plugin.
It's just strange that it's smooth when CodeGlance is open, but drops FPS when CodeGlance is closed. I wonder what changes when this happens.
Anyway as I said before, it doesn't affect me much since I use CodeGlance all the time. Hopefully this only affects me and no one else.
Thanks for the quick response looking into this issue.
Sorry, I want to ask if you tried to delete the .idea
folder? i guess no need to install a fresh PHPStorm. The .idea
folder stored a lot of information, delete it project will become a new project, and the storage based on project will be new(You can move the .idea
folder to other places instead of deleting).if this work,i will see what is stored
Well I'm not sure what's changed since I posted this, but I don't seem to be having this issue anymore. Hooray!
ok,thanks