From b189f1def7c57c5f98f0a17bc5217950d91da8d2 Mon Sep 17 00:00:00 2001 From: 2211567 Date: Mon, 16 Jun 2025 21:13:31 +0200 Subject: [PATCH] Styled that shit --- src/visualization.jl | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/visualization.jl b/src/visualization.jl index 0a34a3e..3deea86 100644 --- a/src/visualization.jl +++ b/src/visualization.jl @@ -70,7 +70,7 @@ end function build_ui(U, V, param_obs_map::NamedTuple, params_obs, heat_obs) reset!(U, V, heat_obs) - fig = Figure(size=(1200, 800)) + fig = Figure(size=(1200, 950)) gh = GridLayout(fig[1, 1]) dropdown = Menu(fig, options=collect(zip(["Gray-Scott", "FHN"], [:gray_scott, :fhn]))) @@ -91,7 +91,7 @@ function build_ui(U, V, param_obs_map::NamedTuple, params_obs, heat_obs) btn_step = Button(buttongrid[1, 1], width=50, label="Step") btn_start = Button(buttongrid[1, 2], width=50, label=run_label) btn_reset = Button(buttongrid[1, 3], width=50, label="Reset") - slidergrid = SliderGrid(fig[3, 1], (label="Speed", range=1:1:50, format="{}x", width=350, startvalue=stepsize[])) + slidergrid = SliderGrid(fig[3, 1], (label="Speed", range=1:1:50, format="{}x", width=750, startvalue=stepsize[], tellwidth=false)) speed_slider = slidergrid.sliders[1].value @@ -115,12 +115,11 @@ function build_ui(U, V, param_obs_map::NamedTuple, params_obs, heat_obs) param_box!(textboxgrid, 4, "a", param_obs_map.a, col=2) param_box!(textboxgrid, 5, "b", param_obs_map.b, col=2) - rowsize!(gh, 1, 50) # small row for the menu - rowsize!(gh, 2, Relative(1.0)) + rowsize!(gh, 1, Relative(0.2)) # small row for the menu + rowsize!(gh, 2, Relative(0.8)) for c in 1:4 - colsize!(textboxgrid, c, Relative(1.0 / 6.0)) + colsize!(textboxgrid, c, Relative(0.1)) end - #rowsize!(fig, 1, Relative(0.8)) # Events ############################################################## # Timer and state for animation