Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Disabled text color and x and y offset #6576

Open
Shadowblitz16 opened this issue Mar 27, 2023 · 4 comments
Open

Add Disabled text color and x and y offset #6576

Shadowblitz16 opened this issue Mar 27, 2023 · 4 comments

Comments

@Shadowblitz16
Copy link

Describe the project you are working on

Windows 95 like theme

Describe the problem or limitation you are having in your project

Windows 95 had a text shadow or you could say copy when the text was disabled
It is currently impossible to recreate in a godot theme without attaching a script to the control and redrawing the text

Describe the feature / enhancement and how it helps to overcome the problem or limitation

Add Disabled text color and x and y offset
Possibly add it for the normal, focused, pressed and hovered styles too for future customization..
Add it fro all controls that can display text

Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams

image

If this enhancement will not be used often, can it be worked around with a few lines of script?

No

Is there a reason why this should be core and not an add-on in the asset library?

It makes themes more customizable

@Shadowblitz16
Copy link
Author

Shadowblitz16 commented Mar 27, 2023

I just realized that icons and styles like line style have this issue too

@Calinou
Copy link
Member

Calinou commented Mar 27, 2023

#4909 is likely a cleaner solution to this (you can override the font shadow properties whenever the control is disabled manually).

@Shadowblitz16
Copy link
Author

@Calinou Will that be possible to have pixel perfect font shadowing?
As of now I don't think font shadows are pixel perfect. I think they are gradiants

@Calinou
Copy link
Member

Calinou commented Mar 28, 2023

Will that be possible to have pixel perfect font shadowing?
As of now I don't think font shadows are pixel perfect. I think they are gradiants

This should already be the case. Font shadow offset is specified as an integer in pixels, so the shadow always aligned to the pixel grid if the display scale is an integer factor (see #1666). (In fact, Godot doesn't have support for soft text shadows or soft outlines unless you use a custom shader to draw those.)

Also, if you disable antialiasing on the font, this will also affect its shadow (as the font shadow always renders the same font). This requires the font to be designed for a specific display size, and you must also display the font at that specified size (or an integer multiple of it).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants