JUCE
JUCE copied to clipboard
[Bug]: Low contrast on table header sort arrow
trafficstars
Detailed steps on how to reproduce the bug
- Set a
juce::TableListBox's header'sbackgroundColourIdto something dark likejuce::Colour( 0x29, 0x27, 0x2d ). - Populate the table with columns / contents
- Sort the table
What is the expected behaviour?
The sort arrow is clearly visible. Instead it has very low contrast because in juce_LookAndFeel_V2.cpp it uses a fixed Colour(0x99000000).
Personally i've had to change this to
auto bgColour = header.findColour (TableHeaderComponent::backgroundColourId);
if( bgColour.getLightness() < 0.5f )
g.setColour (Colour (0x99FFFFFF));
else
g.setColour (Colour (0x99000000));
Perhaps this can be done in the main codebase as well, or allow the sort arrow color to be customized.
Operating systems
Other
What versions of the operating systems?
N/A
Architectures
Other
Stacktrace
No response
Plug-in formats (if applicable)
No response
Plug-in host applications (DAWs) (if applicable)
No response
Testing on the develop branch
The bug is present on the develop branch
Code of Conduct
- [X] I agree to follow the Code of Conduct