TICKIT_WIN...T_GEOMETRY(3)
β¨ TICKIT_WIN...T_GEOMETRY β¨
okay bestie, so this is a page from the Library Functions Manual and it's literally all about moving your windows around and resizing them π come sit with me
πΈ NAME πΈ
tickit_window_set_geometry β set the size and position of a window πͺβ¨
π SYNOPSIS π
#include <tickit.h>
void tickit_window_set_geometry(TickitWindow *win, TickitRect geom);
void tickit_window_resize(TickitWindow *win, int lines, int cols);
void tickit_window_reposition(TickitWindow * win, int top, int left);
Link with -ltickit.
fr fr do not forget that -ltickit, she's the whole personality π
π DESCRIPTION π
so tickit_window_set_geometry() sets the size and the position of the window you hand it, using all the deets in that rectangle struct. and the way that the position works? it's relative to the window's immediate parent. that's the vibe. no cap.
and here's the thing β your window does NOT have to be fully inside the parent. it's allowed to overlap any of the four edges, or literally just sit entirely outside of the parent. main character energy, it goes wherever it wants π¦.
but! content rendering and input events get clipped to the bounds of its parent anyway (and therefore to any ancestors all the way up to the root). so like, sure, go off, but you're still getting trimmed to the family's edges π.
calling this function makes a TICKIT_EV_GEOMCHANGE event happen at the next tick β but only if the geometry actually changed. if none of the four fields are modified, no event, nada, silence π€«. which is why it's totally safe to call it optimistically, just to update the required size in case it changed. lowkey iconic behaviour tbh.
tickit_window_resize() and tickit_window_reposition() are the shortcut girlies β they just take two integer arguments directly, for changing only the size, or only the origin position of the window. β¨
π«Ά RETURN VALUE π«Ά
these functions return no value. nothing. empty. they simply did the thing and moved on π
π₯ SEE ALSO π₯
tickit_window_new(3)tickit_window_get_geometry(3)tickit_window_bind_event(3)tickit_window(7)tickit(7)
and that's the whole page bestie!! π it came from the Library Functions Manual, it's the TICKIT_WIN...T_GEOMETRY(3) page, and uhh the footer is literally just that same name again β TICKIT_WIN...T_GEOMETRY(3) β so yeah, no date, no version, just the title staring back at us like ποΈπποΈ. go forth and reposition, you've got this π¦πβ¨
π¦ where this page comes from
- alpine 3.24: libtickit-doc 0.4.6-r0 Β· MIT
- debian bookworm: libtickit-dev 0.4.3-1 Β· MIT
- debian trixie: libtickit-dev 0.4.3-2 Β· MIT
- fedora 43: libtickit-devel 0.4.5-2.fc43 Β· MIT
- fedora 43: libtickit-devel 0.4.5-2.fc43 Β· MIT
- fedora 44: libtickit-devel 0.4.5-3.fc44 Β· MIT
- fedora 44: libtickit-devel 0.4.5-3.fc44 Β· MIT
- nixos 26.05: libtickit 0.4.5
- nixpkgs unstable: libtickit 0.4.6
- ubuntu jammy: libtickit-dev 0.4.1-1 Β· MIT
- ubuntu noble: libtickit-dev 0.4.3-1.1build1 Β· MIT
- ubuntu questing: libtickit-dev 0.4.3-2
- ubuntu resolute: libtickit-dev 0.4.3-2build1 Β· MIT
- ubuntu stonking: libtickit-dev 0.4.3-2build1 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms