Xinerama.h 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. /*
  2. Copyright 2003 The Open Group
  3. Permission to use, copy, modify, distribute, and sell this software and its
  4. documentation for any purpose is hereby granted without fee, provided that
  5. the above copyright notice appear in all copies and that both that
  6. copyright notice and this permission notice appear in supporting
  7. documentation.
  8. The above copyright notice and this permission notice shall be included in
  9. all copies or substantial portions of the Software.
  10. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  11. IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  12. FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  13. OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
  14. AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
  15. CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  16. Except as contained in this notice, the name of The Open Group shall not be
  17. used in advertising or otherwise to promote the sale, use or other dealings
  18. in this Software without prior written authorization from The Open Group.
  19. */
  20. #ifndef _Xinerama_h
  21. #define _Xinerama_h
  22. #include <X11/Xlib.h>
  23. typedef struct {
  24. int screen_number;
  25. short x_org;
  26. short y_org;
  27. short width;
  28. short height;
  29. } XineramaScreenInfo;
  30. _XFUNCPROTOBEGIN
  31. Bool XineramaQueryExtension (
  32. Display *dpy,
  33. int *event_base,
  34. int *error_base
  35. );
  36. Status XineramaQueryVersion(
  37. Display *dpy,
  38. int *major_versionp,
  39. int *minor_versionp
  40. );
  41. Bool XineramaIsActive(Display *dpy);
  42. /*
  43. Returns the number of heads and a pointer to an array of
  44. structures describing the position and size of the individual
  45. heads. Returns NULL and number = 0 if Xinerama is not active.
  46. Returned array should be freed with XFree().
  47. */
  48. XineramaScreenInfo *
  49. XineramaQueryScreens(
  50. Display *dpy,
  51. int *number
  52. );
  53. _XFUNCPROTOEND
  54. #endif /* _Xinerama_h */