TICKIT_TERM_GOTO(3)

πŸ’– TICKIT_TERM_GOTO β€” the manual page, bestie edition πŸ’–

okay so you found yourself in the TICKIT_TERM_GOTO(3) page of the Library Functions Manual and honestly? iconic. this is the one that teaches you how to scoot the terminal output cursor around like it's a little guy you're dragging across the screen. no cap. πŸ¦‹


✨ NAME ✨

tickit_term_goto, tickit_term_move β€” move the terminal output cursor. that's it, that's the job. πŸ’…


🌸 SYNOPSIS 🌸

#include <tickit.h>

bool tickit_term_goto(TickitTerm *tt, int line, int col);
void tickit_term_move(TickitTerm *tt, int downward, int rightward);

Link with -ltickit. yes, you literally have to, don't skip it, the linker will be so dramatic about it. 🫢


πŸŽ€ DESCRIPTION πŸŽ€

so tickit_term_goto() moves the terminal output cursor to the absolute position you specified. absolute, like, "i have decided exactly where i want to be in life" energy. ✨

here's the lil catch though, and it's giving plot twist: on some terminals, either line or col can be passed as -1 to move within the line or column it is currently in. so like, "stay in this lane, just wiggle a bit." πŸ›

⚠️ not all terminals support this partial move ability! so you must check the return value of tickit_term_goto() after attempting a goto within the line or column, to see if it actually worked. if it didn't? the application has to reset the position using a fully-specified goto. no shortcuts, bestie, we go again. 😭

and then tickit_term_move() moves the terminal output cursor relative to its current position. like a lil hop instead of a teleport. 🧚

  • downward can be 0 if you don't want to move in that direction at all
  • rightward can be 0 for the same reason β€” stay put, queen πŸ‘‘

🌈 RETURN VALUE 🌈

  • tickit_term_goto() returns a boolean value indicating whether it was able to support the requested movement. so true = slay, false = the terminal said "not today." πŸ’€
  • tickit_term_move() returns no value. it's a void. it gives nothing and that's by design. πŸ•³οΈ

πŸ”₯ SEE ALSO πŸ”₯

go read those next, iykyk. πŸ‘‘


and that's the whole page, bestie β€” this was TICKIT_TERM_GOTO(3) from the Library Functions Manual, and the footer agrees with me: TICKIT_TERM_GOTO(3). mwah, periodt. πŸ’œπŸŽ€βœ¨