Missing or mispositioned text when setting TextAlignment on a label
Open
Nobody has claimed this yet.
bug
widget
- Dominant language
- Rust
- Stars
- 9.7k
- Forks
- 565
- PR merge metrics
- No merged PRs in 30d
Description
reported in zulip by @Majora320
The following code paints no label on windows, and in the top-left on mac:
use druid::widget::Label;
use druid::{AppLauncher, TextAlignment, WindowDesc};
fn main() {
AppLauncher::with_window(WindowDesc::new(
Label::new("Test").with_text_alignment(TextAlignment::End),
)).launch(()).unwrap();
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the provided minimal example using Label::new("Test").with_text_alignment(TextAlignment::End), reproducing it on Windows and macOS. Trace the Label text-alignment path from with_text_alignment and verify that the label is visible and positioned at the end rather than missing or appearing in the top-left.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100