From f53c7341152bbc4b642935953e317a2a29abc99c Mon Sep 17 00:00:00 2001 From: Leon Henrik Plickat Date: Fri, 25 Sep 2020 11:19:32 +0200 Subject: Change dimension model to ensure square center --- src/wlclock.h | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src/wlclock.h') diff --git a/src/wlclock.h b/src/wlclock.h index d051b7c..2799452 100644 --- a/src/wlclock.h +++ b/src/wlclock.h @@ -10,6 +10,17 @@ #include"colour.h" +struct Wlclock_dimensions +{ + /* Width and height of entire surface (size + borders). */ + int32_t w, h; + + /* Dimensions of center area (where the actual clock is). + * Center is always square. + */ + int32_t center_x, center_y, center_size; +}; + struct Wlclock { struct wl_display *display; @@ -29,7 +40,7 @@ struct Wlclock int ret; enum zwlr_layer_shell_v1_layer layer; - int32_t size; + struct Wlclock_dimensions dimensions; char *namespace; int32_t exclusive_zone; int32_t border_top, border_right, border_bottom, border_left; -- cgit v1.2.3