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.35k stars 202 forks source link

Variable names color is not controlled while in highlight #2679

Closed kilitary closed 6 months ago

kilitary commented 7 months ago

Please check

Your programming languages

c, c++, c#, php, python, js

Expected Behavior

Variable name has two colors, one while it is read and second when it is written. These settings exists in color scheme.

Current Behavior

When block is highlited variable names is always white.

Possible Solution

  1. Load settings from color scheme
  2. make rainbowsix color selected for read & write states

Code snippet for reproduce (for bugs)

See the screenshot: https://kilitary.ru/sc.png

Your Environment

PyCharm 2023.1.4 (Professional Edition) Build #PY-231.9225.15, built on July 12, 2023 Licensed to bla dd Subscription expired on October 16, 2023. Evaluation purpose only. Runtime version: 17.0.7+10-b829.16 amd64 VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o. Windows 11.0 GC: G1 Young Generation, G1 Old Generation Memory: 6048M Cores: 16 Registry: ide.windowSystem.autoShowProcessPopup=true performance.watcher.sampling.interval.ms=5000 performance.watcher.unresponsive.interval.ms=15000 debugger.valueTooltipAutoShowOnSelection=true performance.watcher.unresponsive.max.attempts.before.log=13133 ide.new.editor.tabs.vertical.borders=true ide.balloon.shadow.size=0 editor.minimap.enabled=true ide.images.show.chessboard=true

Non-Bundled Plugins: com.andrey4623.rainbowcsv (2.0.2) tabs.id (1.13) dev.priporov.idea.notes (1.3.1) Pomodoro-tm (0.70) lermitage.intellij.extratci (1.27.0) dev.turingcomplete.intellijdevelopertoolsplugins (1.0.1) com.github.rougsig.duck-progress-bar (0.0.1) krasa.CpuUsageIndicator (1.15.0-IJ2020.1) TabSwitch (3.0.8) nb-mind-map-idea (1.6.4) com.nasller.CodeGlancePro (1.6.7) ee.carlrobert.chatgpt (2.1.6) com.chylex.intellij.coloredicons (1.4) com.mallowigi (90.0.0) izhangzhihao.rainbow.brackets (2023.3.6) cms.rendner.intellij.py-styled-dataframe-viewer (0.11.0)

izhangzhihao commented 7 months ago

Sorry, I don't understand, could you please provide some screenshots?

kilitary commented 7 months ago

Look here: https://kilitary.ru/sc2.png When i selectede variable pycharm automatically highlights reads and writes of this variable with red if write and cyan when it is written to. On screenshot the block FOR (where i point) is highlighted and variable name is aways white. no matter write or red operation is it.

izhangzhihao commented 7 months ago

Rainbow Brackets doesn't set variable colors for write and read actions. To test if the issue is related to Rainbow Brackets, you can try temporarily disabling it and see if the variable colors behave as expected.

Please follow these steps to disable Rainbow Brackets:

  1. Go to the settings/preferences in PyCharm.
  2. Navigate to the "Plugins" section.
  3. Locate Rainbow Brackets in the list of installed plugins.
  4. Uncheck the checkbox or toggle off the switch to disable Rainbow Brackets.
  5. Apply the changes and restart PyCharm.

After disabling Rainbow Brackets, check if the variable colors are displayed correctly for write and read actions.

kilitary commented 7 months ago

yes, after disabling rainbow the variable displayed in correct colors

izhangzhihao commented 6 months ago

I see, that the highlighting of "error" and other variables use the same technical implementation method, so rainbowify scope and rainbowify variables are conflict features. You can using Broder Highlighting as a replacement if you want to keep the variables highlighting.