TICKIT_TERM_INPUT_WAIT_MSEC(3)
π TICKIT_TERM_INPUT_WAIT_MSEC π
okay bestie, gather round, because this is one of those pages from the Library Functions Manual (section 3, as the header is screaming at us) and it's actually so chill once you get it. no cap.
β¨ NAME β¨
tickit_term_input_wait_* β read more data from the terminal
like... it waits. for input. from the terminal. that's the whole vibe. π¦
πΈ SYNOPSIS πΈ
#include <tickit.h>
void tickit_term_input_wait_msec(TickitTerm *tt, long msec);
void tickit_term_input_wait_tv(TickitTerm *tt, const struct timeval *timeout);
and when you link it, you link it like this, exactly:
-ltickit
periodt. π
π DESCRIPTION π
so the tickit_term_input_wait_*() family of functions β literally all of them β wait for at least one input event to be received, and they keep waiting up until the maximum time given. that's the whole job. that's the assignment. and they ate. π₯
quick heads up though: calling these functions may block if the underlying file descriptor is in blocking mode. yes bestie, block. as in your whole program just sits there vibing until something happens. if that's not the energy you want, you know what to do about it (set nonblocking, iykyk).
they may also result in TICKIT_EV_KEY or TICKIT_EV_MOUSE events being invoked. so like, your key and mouse handlers get called. surprise! π
and the extra cute part: these functions also invoke deferred TICKIT_EV_RESIZE events if enabled by tickit_term_observe_sigwinch(3). so if someone drags their terminal window around, you get notified. iconic behaviour honestly.
now, the two functions differ in how the timeout is specified. that's the only difference. everything else? same girl, different font:
tickit_term_input_wait_msec()β takes a time as an integer in milliseconds, or-1to wait indefinitely. so-1= wait forever, no thoughts, head empty, just vibes. πtickit_term_input_wait_tv()β takes a time as astruct timeval, orNULLto wait indefinitely. same energy, fancier time format. π
π RETURN VALUE π
tickit_term_input_wait_msec() and tickit_term_input_wait_tv() return no value.
they're void, bestie. nothing comes back. don't go assigning them to anything, don't go checking them for errors, there's literally nothing there. π
π«Ά SEE ALSO π«Ά
tickit_term_build(3)tickit_term_input_readable(3)tickit_term_bind_event(3)tickit_term(7)tickit(7)
go read those too, they're all part of the same friend group. β¨
and that's the page, bestie!! we made it. this one came straight out of the Library Functions Manual, TICKIT_TER...T_WAIT_MSEC(3), and yeah, the footer is just that same name again β TICKIT_TER...T_WAIT_MSEC(3) β giving main character energy twice because it can. π
π¦π
π¦ 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