Skip to content

StringSelect: keep the theme's text color for entries without a color - #1916

Open
dayfine wants to merge 1 commit into
PokemonAutomation:mainfrom
dayfine:upstream/string-select-text-color
Open

dayfine wants to merge 1 commit into
PokemonAutomation:mainfrom
dayfine:upstream/string-select-text-color

Conversation

@dayfine

@dayfine dayfine commented Nov 16, 2026

Copy link
Copy Markdown
Contributor

The Probelm

A StringSelect dropdown drew its selected value in the entry's text_color, and an entry with no color has Color() == 0, which Qt draws as black, so in dark mode the selected value was unreadable

The Fix

The line edit now keeps the theme's palette unless the entry sets a color, the same rule the popup list already uses (if (item.text_color)). The three copies of the palette code become one helper.

Testing

Before

截圖 2026-11-15 下午4 14 49

After

截圖 2026-11-15 下午4 10 54

An entry with no text_color has Color() == 0, which Qt draws as black, so the selected value was unreadable in dark mode. The line edit now keeps the theme's palette unless the entry sets a color, the same rule the popup list uses. The three copies of the palette code become one helper.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant