izhangzhihao / intellij-rainbow-brackets

🌈Rainbow Brackets for IntelliJ based IDEs/Android Studio/HUAWEI DevEco Studio/Fleet
https://plugins.jetbrains.com/plugin/10080-rainbow-brackets
GNU General Public License v3.0
4.44k stars 212 forks source link

Some previous indent highlights remain, when indent highlighting mode is "Current indent" #2750

Open hogejo opened 3 months ago

hogejo commented 3 months ago

Have you checked the issues and discussions to ensure there are no duplicates?

Yes

Your programming languages

tested in Java and Dart

Free or paid?

Paid users

Expected Behavior

Moving the cursor (with mouse or keyboard), only the current indent is highlighted.

Current Behavior

The new indent is highlighted, but sometimes, some previous indent parts remain highlighted.

broken-highlights

In the above example, the current indent highlight is broken too :(

Code snippet for reproduce

bug is not code-dependant

Your Environment

IntelliJ IDEA 2024.1.4 (Ultimate Edition) Build #IU-241.18034.62, built on June 20, 2024 Licensed to [REDACTED] You have a perpetual fallback license for this version. Subscription is active until [REDACTED]. Runtime version: 17.0.11+1-b1207.24 amd64 VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o. Linux 6.9.3-1-default GC: G1 Young Generation, G1 Old Generation Memory: 3484M Cores: 16 Non-Bundled Plugins: manjaro.mpb (1.9) net.sjrx.intellij.plugins.systemdunitfiles (223.240703.177) Batch Scripts Support (1.0.13) com.jetbrains.space (241.18034.4) Dart (241.17890.8) com.github.jk1.ytplugin (2024.2.117) com.intellij.guice (241.14494.158) ru.artyushov (1.5.0) com.chylex.intellij.inspectionlens (1.4) izhangzhihao.rainbow.brackets (2024.2.4-241) com.jetbrains.packagesearch.intellij-plugin (241.0.11) org.jusecase.jte-intellij (2.1.2) org.jetbrains.android (241.17011.79) io.flutter (80.0.2) zielu.gittoolbox (500.2.10+233) Kotlin: 241.18034.62-IJ Current Desktop: XFCE

izhangzhihao commented 3 months ago

duplicate with #2540

hogejo commented 2 months ago

@izhangzhihao do you plan to close this too, or want to investigate? Your code looks a bit intimidating on the first look. But I played around with the behaviour, and:

  1. It also happens in the new UI
  2. It seems to be 100% deterministic

If you move up and down on the very end of each line, it works fine. If you start moving in, it breaks when you hit the first bracket.

https://github.com/izhangzhihao/intellij-rainbow-brackets/assets/79865589/2157e231-b03a-45f0-991c-ff2fa0099d60

izhangzhihao commented 2 months ago

I will investigate this issue later.

haolly commented 1 month ago

我也遇到这个问题了,怎么回退旧版本呢?

izhangzhihao commented 1 month ago

我也遇到这个问题了,怎么回退旧版本呢?

revert to an old version won't fix it.