#3663·SFML

Event documentation and tests

Author: JonnyPtnCreated Feb 9, 2026Updated May 7, 2026
Labelsfeaturem:sfml-windowm:doc

Prerequisite Checklist

Describe your feature request here

Currently the event documentation is basically non-existent, they almost all just say "X event subtype" which is useless. The docs on the members give you a bit more information about the data the event contains, but there's still no information about what triggers events and when users should expect them to be sent

This information would not only be very useful for SFML users but also SFML contributors to help ensure the events behave as expected across platforms.

Some recent examples:

  • Should FocusGained trigger on window creation?
  • Should MouseEntered trigger when a window is resized so that the mouse is over it?
  • Should Resized trigger when the window is resized programmatically?
  • Should MouseMoved trigger when the mosue is moved programatically?

There are also some platform specific differences that should be documented, like how the focus events are used to indicate backgrounding on mobile platforms

It seems like we could also add tests to verify much of the documented behaviour

I would imagine it might be a bit of a can of worms once this work starts so trying to cover them all in one PR may get out of hand and we should probably look to update them incrementally