Add highlight_color, highlight_textcolor style props, and tooltip styling via style_type in formspecs.#17041
Closed
sofar wants to merge 2 commits intoluanti-org:masterfrom
Closed
Add highlight_color, highlight_textcolor style props, and tooltip styling via style_type in formspecs.#17041sofar wants to merge 2 commits intoluanti-org:masterfrom
sofar wants to merge 2 commits intoluanti-org:masterfrom
Conversation
…pecs Allow games to control the selection/highlight colors in formspec elements via style[] and style_type[] properties. Previously these were hardcoded to skin defaults (green highlight, white text) with no way to override them to match a custom UI theme. Supported elements: field, textarea, textlist, table, dropdown. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Allow games to customize tooltip appearance through the style system: - bgcolor/textcolor: override default tooltip colors - bgimg/bgimg_middle: 9-slice background image - border: enable/disable the 3D sunken border - bordercolor/borderwidths: flat colored border with custom thickness The tooltip element is drawn once explicitly in drawMenu() with custom background and borders, then hidden so the GUI tree's second draw pass doesn't overwrite the custom rendering. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
Author
Contributor
|
This is great! It will be very nice for games. |
Contributor
Author
|
Just some background: I've been heavily re-styling my game for Inside the Box and these are some of the last few remaining items where I can't style things the way I'd like to see it. So it definitely closes a big gap. |
Contributor
Author
|
Closing for now. This is better suited after a new layout engine is merged that implements - #14263 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.







Allow games to customize tooltip appearance through the style system:
The tooltip element is drawn once explicitly in drawMenu() with custom
background and borders, then hidden so the GUI tree's second draw pass
doesn't overwrite the custom rendering.
Allow games to control the selection/highlight colors in formspec elements
via style[] and style_type[] properties. Previously these were hardcoded
to skin defaults (green highlight, white text) with no way to override
them to match a custom UI theme.
Supported elements: field, textarea, textlist, table, dropdown.