todo-tree icon indicating copy to clipboard operation
todo-tree copied to clipboard

Support border color, width and style in default and custom highlights

Open 3noix opened this issue 1 year ago • 1 comments

This PR resolves #582 by adding support of:

  • border color
  • border width
  • border style for default and custom highlights.

I treated the border color similarly to foreground and background colors:

Default values:

  • border color: the background color
  • border width: 0
  • border style: solid

Here is the result of a test: test

With these settings in todo-tree.highlights.customHighlight and no foreground and background set in todo-tree.highlights.defaultHighlight: settings1

3noix avatar Apr 13 '24 23:04 3noix

I had a problem with the VSCode API: I only wanted to add a horizontal line above my comment, without applying a background or a foreground change, and I had a foreground in the todo-tree.highlights.defaultHighlight... and in this case it is impossible to reference the color of comments of the theme:

  • editor.tokenColorCustomizations.comments:
    • shows a warning when settings.json is saved (because invalid)
    • same result as if "editor.foreground" was used
  • editor.foreground:
    • no warning
    • not the color of comments
  • hard coded hex value: works obviouslybut will not change with the theme
  • null:
    • shows a warning when settings.json is saved (because invalid)
    • has the expected effect

And this is some weird behavior that 2 different invalid values (as said by the warning) have different results.

settings

3noix avatar Apr 13 '24 23:04 3noix