-
-
Notifications
You must be signed in to change notification settings - Fork 70
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
input-field: improve dynamic width #647
base: main
Are you sure you want to change the base?
Conversation
- Instead of not rendering placeholder text, if it does not fit into the input-field width, render it up until the input field size. - Improve updateWidth.
will test this evening |
Looks nice. Also not sure if you changed it here or previously, but the resizing animation also seems smoother (that weird going back to small and growing from there seems fixed) I don't really like how the shadow disappears during resizing, is that a choice you made because of performance losses? Also, is it just my eyes tricking me or did the fade animation disappear during the change of the input-field border color? pretty sure it's just changing instantly Also, you're right, padding probably isn't needed, especially if we consider the default speed of that animation |
Yep, we need to do some low-hanging shadow optimizations (like not using the entire viewport for the shadow framebuffer) before considering enabling it again I think.
Actually I am a bit confused about that. When i increase the animation duration, it clearly fades, but on the default config it really looks instant. However it does fade a bit still. Not really sure if it's just perception or something is slightly off... |
Both things are not directly related to this pr. |
For reference this is how looks with increased width animation duration. hyprlock_dynamic_width.mp4 |
have you tried putting a video of the normal thing in slow motion? |
good idea. |
In #582 I changed it so the placeholder text is not rendered until the dynamic width resizes and the placeholder actually fits.
That however also looks off, especially with slow animation speeds.
This PR changes it so that it will render it right away, but cut it where the input field ends.
Alba and me also thought about fading in the placeholder text, but I think that is smth for a separate PR.
CC @alba4k you wanna test again? I did not include a pad to the input field like you suggested, cause if think it looks better like that.