Or more precisely: What you can expect it to do, as the request is handled by the window manager.
When you use gtk_window_fullscreen_on_monitor(), the last parameter specifies the monitor index you want the window moved to. 0 does not have any special meaning, it means “the monitor with index 0”.
From what I understand it goes to fullscreen on the monitor on which the window currently is positioned.
This means that I can use Zero as the last argument like in the following demo:
This works fine, but how do I programmatically have to deal with the last argument (gint monitor) so that GTK does the work for me instead of using myself 0 (zero) as its last argument?
The API is mostly an X11-ism, and mostly for desktop components that can negotiate with the window manager/compositor their geometry and location; as it is, the API does not make sense on other platforms or windowing systems—ultimately, for applications, only the window manager can decide which monitor to use, or what kind of geometry the window can have.