#18988: Greyed-out tab captions in wxAuiNotebook make no sense
--------------------------+-----------------------------------
Reporter: juliansmart | Owner:
Type: defect | Status: new
Priority: normal | Milestone:
Component: wxAui | Version: 3.0.5
Resolution: | Keywords: aui,tab,wxAuiNotebook
Blocked By: | Blocking:
Patch: 0 |
--------------------------+-----------------------------------
Old description:
> On Mac, captions of unselected wxAuiNotebook tabs are now greyed out and
> pretty hard to read. This doesn't make any sense to me, especially as the
> unselected captions on a wxNotebook are the same colour as selected
> captions. A greyed-out label would surely indicate that the tab can't be
> clicked - it's truly 'inactive' - not that it's not the selection. The
> selection is already indicated by a bold font.
>
> So I suggest for the sake of consistency and accessibility that we use
> the same colour for selected and unselected tabs. Failing that, that we
> make it a lot easier to change this aspect without hacking the source or
> having to reproduce 99% of the tab art class to change it.
>
> The relevant code is in src/aui/tabart.cpp:
>
> // draw tab text
> wxColor sys_color = wxSystemSettings::GetColour(
> page.active ? wxSYS_COLOUR_CAPTIONTEXT :
> wxSYS_COLOUR_INACTIVECAPTIONTEXT);
>
> which could just be:
>
> // draw tab text
> wxColor sys_color =
> wxSystemSettings::GetColour(wxSYS_COLOUR_CAPTIONTEXT);
>
> Thanks,
>
> Julian
New description:
On Mac, captions of unselected wxAuiNotebook tabs are now greyed out and
pretty hard to read. This doesn't make any sense to me, especially as the
unselected captions on a wxNotebook are the same colour as selected
captions. A greyed-out label would surely indicate that the tab can't be
clicked - it's truly 'inactive' - not that it's not the selection. The
selection is already indicated by a bold font.
So I suggest for the sake of consistency and accessibility that we use the
same colour for selected and unselected tabs. Failing that, that we make
it a lot easier to change this aspect without hacking the source or having
to reproduce 99% of the tab art class to change it.
The relevant code is in src/aui/tabart.cpp:
{{{
#!cpp
// draw tab text
wxColor sys_color = wxSystemSettings::GetColour(
page.active ? wxSYS_COLOUR_CAPTIONTEXT :
wxSYS_COLOUR_INACTIVECAPTIONTEXT);
}}}
which could just be:
{{{
#!cpp
// draw tab text
wxColor sys_color =
wxSystemSettings::GetColour(wxSYS_COLOUR_CAPTIONTEXT);
}}}
Thanks,
Julian
--
Comment (by vadz):
I think we need to find a better colour to use for inactive pages or
change the mapping of `wxSYS_COLOUR_INACTIVECAPTIONTEXT` in
`src/osx/cocoa/
settings.mm` to something else, but it doesn't look like a
good idea to not distinguish active from inactive pages at all.
BTW, for the reference, this was changed in e8b917e7a4 (Use system colours
if the contrast is sufficient in AUI tabs, 2019-12-05) which tried to fix
the problem with the text being unreadable with some themes, see #18601,
so we do want to keep this change in at least some form.
--
Ticket URL: <
https://trac.wxwidgets.org/ticket/18988#comment:1>