[SDL] Minor X11 hack:

Sam Lantinga slouken at devolution.com
Mon Sep 2 08:59:01 PDT 2002


> Here's a patch to center a newly-created, non-fullscreen X11 window.
> While this may or may not be suitable for adding to SDL officially, I
> didn't want to put any Xlib dependencies in my code directly.

> To use:

> - Apply patch/rebuild.
> - export SDL_WINDOW_POS=center
> - Call SDL_SetVideoMode as needed.

> (Ideally, this could be expanded to handle other commands like
> SDL_WINDOW_POS=20x190, etc, and could be implemented for other targets,
> but this is really a hack to avoid API changes).

Cool, it's in CVS.

See ya!
	-Sam Lantinga, Software Engineer, Blizzard Entertainment




More information about the SDL mailing list