ryukau / VSTPlugins

Uhhyou Plugins VST 3 repository.
https://ryukau.github.io/VSTPlugins/
GNU General Public License v3.0
327 stars 12 forks source link

Active tab label is uncolored. #6

Closed KottV closed 4 years ago

KottV commented 4 years ago

Greetings,

Thank for porting palette to VST version. I found that text on active tab is colored with foregroundInactive.

I fixed that by just adding in tabview.cpp:

 // Active tab.
+  pContext->setFontColor(pal.foreground());

And I'd like to add another one addition to palette for text label's strokes. Could you accept that?

ryukau commented 4 years ago

Thanks for the catch. Active tab color is fixed in latest commit.

I can't promise without looking concrete example (code or screenshot/screencast of improvement). But if it's only some addition to the palette, I'll probably merge that.

KottV commented 4 years ago

The idea is to add color config for lines near the text label. Currently it inherits color from border. So it will be possible to draw them with borderless theme:

Screenshot_20200616_122921

Will be:

Screenshot_20200616_122746

I've made it by add borderLabel color to palette and:

+++ label.hpp   2020-06-15 14:51:33.319926072 +1000
@@ -54,7 +54,7 @@
       beginPath();
       moveTo(0, height / 2);
       lineTo(width, height / 2);
-      strokeColor(pal.border());
+      strokeColor(pal.borderLabel());
       strokeWidth(borderWidth);
       stroke();

Surely it shouldn't break existing themes.

ryukau commented 4 years ago

Thanks for the explanation.

I'll merge it. Feel free to open PR when the patch is ready.