aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2024-07-25 14:56:49 +0200
committerdec05eba <dec05eba@protonmail.com>2024-07-25 14:56:49 +0200
commitb4799373f7fb9c8faec813e78a955438301cb9d1 (patch)
tree580b177912b3922b34681122099d742a57fd853b /include
parent05da9076d3d1b0d770c13572368f974786edcd92 (diff)
Add sprite set size/height functions, option to hide window decorations in create window
Diffstat (limited to 'include')
-rw-r--r--include/mgl/graphics/sprite.h4
-rw-r--r--include/mgl/window/window.h1
2 files changed, 5 insertions, 0 deletions
diff --git a/include/mgl/graphics/sprite.h b/include/mgl/graphics/sprite.h
index 64d9c03..0193c4c 100644
--- a/include/mgl/graphics/sprite.h
+++ b/include/mgl/graphics/sprite.h
@@ -25,6 +25,10 @@ void mgl_sprite_set_position(mgl_sprite *self, mgl_vec2f position);
void mgl_sprite_set_color(mgl_sprite *self, mgl_color color);
void mgl_sprite_set_rotation(mgl_sprite *self, float degrees);
void mgl_sprite_set_origin(mgl_sprite *self, mgl_vec2f origin);
+/* This only has an effect if the sprite has a texture set */
+void mgl_sprite_set_size(mgl_sprite *self, mgl_vec2f size);
+/* This only has an effect if the sprite has a texture set. Scales width in proportion */
+void mgl_sprite_set_height(mgl_sprite *self, float height);
void mgl_sprite_draw(mgl_context *context, mgl_sprite *sprite);
#endif /* MGL_SPRITE_H */
diff --git a/include/mgl/window/window.h b/include/mgl/window/window.h
index 90bbd3d..eb7f587 100644
--- a/include/mgl/window/window.h
+++ b/include/mgl/window/window.h
@@ -75,6 +75,7 @@ typedef struct {
bool hidden; /* false by default */
bool override_redirect; /* false by default */
bool support_alpha; /* support alpha for the window, false by default */
+ bool hide_decorations; /* this is a hint, it may be ignored by the window manager, false by default */
mgl_color background_color; /* default: black */
const char *class_name;
mgl_window_type window_type; /* default: normal */