Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:54:03

0001 /* cairo - a vector graphics library with display and print output
0002  *
0003  * Copyright © 2002 University of Southern California
0004  *
0005  * This library is free software; you can redistribute it and/or
0006  * modify it either under the terms of the GNU Lesser General Public
0007  * License version 2.1 as published by the Free Software Foundation
0008  * (the "LGPL") or, at your option, under the terms of the Mozilla
0009  * Public License Version 1.1 (the "MPL"). If you do not alter this
0010  * notice, a recipient may use your version of this file under either
0011  * the MPL or the LGPL.
0012  *
0013  * You should have received a copy of the LGPL along with this library
0014  * in the file COPYING-LGPL-2.1; if not, write to the Free Software
0015  * Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA
0016  * You should have received a copy of the MPL along with this library
0017  * in the file COPYING-MPL-1.1
0018  *
0019  * The contents of this file are subject to the Mozilla Public License
0020  * Version 1.1 (the "License"); you may not use this file except in
0021  * compliance with the License. You may obtain a copy of the License at
0022  * http://www.mozilla.org/MPL/
0023  *
0024  * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY
0025  * OF ANY KIND, either express or implied. See the LGPL or the MPL for
0026  * the specific language governing rights and limitations.
0027  *
0028  * The Original Code is the cairo graphics library.
0029  *
0030  * The Initial Developer of the Original Code is University of Southern
0031  * California.
0032  *
0033  * Contributor(s):
0034  *  Carl D. Worth <cworth@cworth.org>
0035  */
0036 
0037 #ifndef CAIRO_XLIB_H
0038 #define CAIRO_XLIB_H
0039 
0040 #include "cairo.h"
0041 
0042 #if CAIRO_HAS_XLIB_SURFACE
0043 
0044 #include <X11/Xlib.h>
0045 
0046 CAIRO_BEGIN_DECLS
0047 
0048 cairo_public cairo_surface_t *
0049 cairo_xlib_surface_create (Display     *dpy,
0050                Drawable drawable,
0051                Visual      *visual,
0052                int      width,
0053                int      height);
0054 
0055 cairo_public cairo_surface_t *
0056 cairo_xlib_surface_create_for_bitmap (Display  *dpy,
0057                       Pixmap    bitmap,
0058                       Screen    *screen,
0059                       int   width,
0060                       int   height);
0061 
0062 cairo_public void
0063 cairo_xlib_surface_set_size (cairo_surface_t *surface,
0064                  int              width,
0065                  int              height);
0066 
0067 cairo_public void
0068 cairo_xlib_surface_set_drawable (cairo_surface_t *surface,
0069                  Drawable     drawable,
0070                  int              width,
0071                  int              height);
0072 
0073 cairo_public Display *
0074 cairo_xlib_surface_get_display (cairo_surface_t *surface);
0075 
0076 cairo_public Drawable
0077 cairo_xlib_surface_get_drawable (cairo_surface_t *surface);
0078 
0079 cairo_public Screen *
0080 cairo_xlib_surface_get_screen (cairo_surface_t *surface);
0081 
0082 cairo_public Visual *
0083 cairo_xlib_surface_get_visual (cairo_surface_t *surface);
0084 
0085 cairo_public int
0086 cairo_xlib_surface_get_depth (cairo_surface_t *surface);
0087 
0088 cairo_public int
0089 cairo_xlib_surface_get_width (cairo_surface_t *surface);
0090 
0091 cairo_public int
0092 cairo_xlib_surface_get_height (cairo_surface_t *surface);
0093 
0094 /* debug interface */
0095 
0096 cairo_public void
0097 cairo_xlib_device_debug_cap_xrender_version (cairo_device_t *device,
0098                          int major_version,
0099                          int minor_version);
0100 
0101 /*
0102  * @precision: -1 implies automatically choose based on antialiasing mode,
0103  *            any other value overrides and sets the corresponding PolyMode.
0104  */
0105 cairo_public void
0106 cairo_xlib_device_debug_set_precision (cairo_device_t *device,
0107                        int precision);
0108 
0109 cairo_public int
0110 cairo_xlib_device_debug_get_precision (cairo_device_t *device);
0111 
0112 CAIRO_END_DECLS
0113 
0114 #else  /* CAIRO_HAS_XLIB_SURFACE */
0115 # error Cairo was not compiled with support for the xlib backend
0116 #endif /* CAIRO_HAS_XLIB_SURFACE */
0117 
0118 #endif /* CAIRO_XLIB_H */