Skip to content

Commit

Permalink
Update grid example based on feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredoconnell committed Sep 11, 2024
1 parent dec9ff7 commit cb8e984
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions masonry/examples/grid_masonry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ use masonry::app_driver::{AppDriver, DriverCtx};
use masonry::dpi::LogicalSize;
use masonry::widget::{Button, Grid, GridParams, Prose, RootWidget, SizedBox};
use masonry::{Action, Color, PointerButton, WidgetId};
use parley::layout::Alignment;
use winit::window::Window;

struct Driver {
Expand Down Expand Up @@ -44,10 +45,11 @@ fn grid_button(params: GridParams) -> Button {
pub fn main() {
let label = SizedBox::new(
Prose::new(
"Change spacing by right and\n\
"Change spacing by right and \
left clicking on the buttons",
)
.with_text_size(14.0),
.with_text_size(14.0)
.with_text_alignment(Alignment::Middle),
)
.border(Color::rgb8(40, 40, 80), 1.0);
let button_inputs = vec![
Expand Down

0 comments on commit cb8e984

Please sign in to comment.