TS_GET_EVENTPATH(3)

πŸ’– TS_GET_EVENTPATH β€” bestie, where did that touchscreen even come from?? πŸ’–

okay so real talk, this is ts_get_eventpath, page 3 of the tslib manual, and she is exactly what she sounds like: the girl who tells you the path to the currently opened touchscreen device file. no cap. πŸŽ€


✨ NAME ✨

ts_get_eventpath β€” get the path to the currently opened touchscreen device file 🌸


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <tslib.h>

char *ts_get_eventpath(struct tsdev *tsdev);

πŸ‘‘ DESCRIPTION πŸ‘‘

okay so ts_get_eventpath() β€” this function returns the path to the touchscreen device file that was opened with ts_open(). πŸ’…

and here's the tea: if ts_setup() is used instead of calling ts_open() directly, it is often not known to the application in advance what that path even is. which is like. rude. so this function is your bestie who actually knows. 🫢


πŸ’€ RETURN VALUE πŸ’€

she returns the path to the touchscreen device file that was opened with ts_open(). ✨

and if it fails? it returns NULL. 😭 no path, no vibes, just NULL. dramatic but honest.


🌈 SEE ALSO 🌈


mwah πŸ’œ this has been TS_GET_EVENTPATH from the tslib manual, section 3, living her little life down there at the bottom of the page. go call ts_setup() and then ask her where she's been. she'll tell you. periodt. πŸŽ€βœ¨