logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

SDL_PenButtonEvent - Pressure-sensitive pen button event structure (event.pbutton.*)

Availability

       This struct is available since SDL 3.2.0.

Simple Directmedia Layer                           SDL 3.2.10                          SDL_PenButtonEvent(3type)

Description

       This  is  for  buttons  on the pen itself that the user might click. The pen itself pressing down to draw
       triggers a

       SDL_EVENT_PEN_DOWN
        event instead.

Header File

       Defined in SDL3/SDL_events.h

Name

       SDL_PenButtonEvent - Pressure-sensitive pen button event structure (event.pbutton.*)

Synopsis

#include"SDL3/SDL.h"typedefstructSDL_PenButtonEvent{SDL_EventTypetype;/**<SDL_EVENT_PEN_BUTTON_DOWNorSDL_EVENT_PEN_BUTTON_UP*/Uint32reserved;Uint64timestamp;/**<Innanoseconds,populatedusingSDL_GetTicksNS()*/SDL_WindowIDwindowID;/**<Thewindowwithmousefocus,ifany*/SDL_PenIDwhich;/**<Thepeninstanceid*/SDL_PenInputFlagspen_state;/**<Completepeninputstateattimeofevent*/floatx;/**<Xcoordinate,relativetowindow*/floaty;/**<Ycoordinate,relativetowindow*/Uint8button;/**<Thepenbuttonindex(firstbuttonis1).*/booldown;/**<trueifthebuttonispressed*/}SDL_PenButtonEvent;

See Also