al_get_display_event_source(3alleg5)

πŸ“¦
version 5.2.11.3 Β· 4 versions
, in debian trixie, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– al_get_display_event_source β€” Allegro 5 API ✨

okay bestie, welcome to the alleg5 manual, the part where we go get an event source off a display πŸŽ€


🌸 NAME 🌸

al_get_display_event_source β€” it's the Allegro 5 API, and this one function is your little key to unlocking a display's event stream πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <allegro5/allegro.h>

ALLEGRO_EVENT_SOURCE *al_get_display_event_source(ALLEGRO_DISPLAY *display)

no cap, that's the whole signature, and yes you pass in your ALLEGRO_DISPLAY * and you get an ALLEGRO_EVENT_SOURCE * right back 🫢


✨ DESCRIPTION ✨

So basically: you hand it a display, and it retrieves the associated event source for you. That's the vibe. That's the whole job πŸŽ€

And if you're sitting there like "okay but what events even come out of a display??" β€” the answer lives in the docs on events, specifically ALLEGRO_EVENT_DISPLAY_EXPOSE(3alleg5), which has the full list of the events that displays will generate. go read it, it's giving informative πŸ‘‘

lowkey important: the source you get back is associated with the display you passed in β€” it's that display's event source, not a brand new one you invented πŸ’–

and that's the whole page, bestie, we ate and left no crumbs πŸ“

signing off with the official receipts: this was the Allegro reference manual, for Allegro 5 (the alleg5 manual, section 3), and the page header/footer tag along as al_get_display_event_source(3alleg5) on both ends. πŸ’œβœ¨

πŸ“¦ where this page comes from