Monnoroch / ColorHighlighter

ColorHighlighter - is a plugin for the Sublime text 2 and 3, which underlays selected hexadecimal colorcodes (like "#FFFFFF", "rgb(255,255,255)", "white", etc.) with their real color. Also, plugin adds color picker to easily modify colors. Documentation: https://monnoroch.github.io/ColorHighlighter.
https://sublime.wbond.net/packages/Color%20Highlighter
1.31k stars 130 forks source link

Color conversion breaks on multiple selection #401

Closed gerardroche closed 2 years ago

gerardroche commented 6 years ago

This is easiest to illustrate with an example.

Where the cursor is | or anywhere on the lines.

#|272822  
#|3e3d32  
#|f8f8f2  
#|cfcfc2  
#|75715e  
#|e6db74  
#|fd971f  
#|f92672  
#|fd5ff0  
#|ae81ff  
#|66d9ef  
#|a1efe4  
#|a6e22e  

Press Ctrl+Shift+,.

Expected

All colors to converted to next format.

Actual

First time:

#272822ff  
#3e3d32ff  
#f8f8f2  
#cfcfc2  
#75715e  
#e6db74  
#fd971fff  
#f92672  
#fd5ff0  
#ae81ff  
#66d9ef  
#a1efe4  
#a6e22e

Second time:

hsl(70, 8%, 15%)  
#3e3d32ff  
#f8f8f2ff  
#cfcfc2  
#75715e  
#e6db74  
#fd971fff  
#f92672  
#fd5ff0  
#ae81ff  
#66d9ef  
#a1efe4  
#a6e22e

And so on.