mirror of
https://github.com/storytold/craft-libs.git
synced 2026-11-26 03:17:43 +00:00
ui-widgets: the long chord-button story gives its long text as the label, not as painted text
painted is the label as the face shows it (with its access letter) and the label stays the accessible name, so a cut painted text that is other words was in no name.
This commit is contained in:
@@ -406,10 +406,10 @@ fn button_chord(ui: &mut Ui, _: &mut StoryData) -> StoryOutput {
|
||||
Button::command(EditCommands::Copy).chord(ButtonChord::Trailing).show(ui).into()
|
||||
}
|
||||
|
||||
/// A long painted label with the chord: the chord shows while the whole label fits beside it.
|
||||
/// A long label with the chord: the chord shows while the whole label fits beside it.
|
||||
#[story(Button<'static>, covers = [], drive = Drive::Never, group = "Variants", title = "Chord, long text")]
|
||||
fn button_chord_long_text(ui: &mut Ui, _: &mut StoryData) -> StoryOutput {
|
||||
Button::command(EditCommands::Copy).chord(ButtonChord::Trailing).painted("Copy the selected objects to the clipboard").show(ui).into()
|
||||
Button::command(EditCommands::Copy).chord(ButtonChord::Trailing).label("Copy the selected objects to the clipboard").show(ui).into()
|
||||
}
|
||||
|
||||
/// A room too short for label and chord together: the chord is dropped and the label stays whole.
|
||||
|
||||
Reference in New Issue
Block a user