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

Stack widget layout issue #2431

Closed
2 tasks done
njust opened this issue May 8, 2024 · 3 comments
Closed
2 tasks done

Stack widget layout issue #2431

njust opened this issue May 8, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@njust
Copy link

njust commented May 8, 2024

Is there an existing issue for this?

  • I have searched the existing issues.

Is this issue related to iced?

  • My hardware is compatible and my graphics drivers are up-to-date.

What happened?

Using the stack widget with two views with buttons won't render the above button properly:

The last element is a stack with two "card_views":
image

Example repository is here:
https://github.com/njust/iced_layout_issue/tree/stack_widget_issue

What is the expected behavior?

Properly render the most recent widget in the stack.

Version

master

Operating System

Windows

Do you have any log output?

No response

@njust njust added the bug Something isn't working label May 8, 2024
@WailAbou
Copy link

WailAbou commented Jul 25, 2024

I've done some debugging and found that the issue occurs with certain text sizes like 18, while sizes like 16 or 20 work fine. If you remove the text size function or set it to 16 or 20, the button renders correctly. I'm currently looking for a fix but I can't make any promises as I'm new to this framework and not a maintainer.

@WailAbou
Copy link

After looking into it further, I found that the issue has been resolved in a later commit than the one you were using in your Cargo.lock file. To fix this, you should delete your Cargo.lock and let it regenerate, then make some small syntax changes to match the updates. I've created a pull request for you that implements these changes: njust/iced_layout_issue#2.

If a maintainer reviews this, you can most likely close this issue.

@njust
Copy link
Author

njust commented Jul 28, 2024

Hi, thanks for looking into this. I can confirm this works now as expected on the latest master branch.

@njust njust closed this as completed Jul 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants