WSTester updated to work plus hopefully all the other changes that need to go into...
[jabaws.git] / binaries / src / ViennaRNA / RNAforester / g2-0.70 / src / X11 / g2_X11_P.h
1 /*****************************************************************************
2 **  Copyright (C) 1998-2001  Ljubomir Milanovic & Horst Wagner
3 **  This file is part of the g2 library
4 **
5 **  This library is free software; you can redistribute it and/or
6 **  modify it under the terms of the GNU Lesser General Public
7 **  License as published by the Free Software Foundation; either
8 **  version 2.1 of the License, or (at your option) any later version.
9 **
10 **  This library is distributed in the hope that it will be useful,
11 **  but WITHOUT ANY WARRANTY; without even the implied warranty of
12 **  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13 **  Lesser General Public License for more details.
14 **
15 **  You should have received a copy of the GNU Lesser General Public
16 **  License along with this library; if not, write to the Free Software
17 **  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
18 ******************************************************************************/
19 #ifndef _G2_X11_P_H
20 #define _G2_X11_P_H
21
22 #include <X11/Xlib.h>
23
24 #include "g2.h"
25
26 typedef struct {
27     Display     *display;
28     Window      window;
29     Window      root;
30     Colormap    colormap;
31     GC          gc;
32     Drawable    dest;
33     Pixmap      backing_pixmap;
34     
35     
36     unsigned long  *inks;                         /* allocated colors*/
37     int            NofInks;                       /* N of allocated colors */
38     int            width;                         /* window dimensions */
39     int            height;
40     int            background;
41 } g2_X11_device;
42
43
44 int g2_X11_init_X11X(int pid, int width, int height,
45                      int xposition, int yposition,
46                      char *window_name, char *icon_name,
47                      char *icon_data,
48                      unsigned int icon_width, unsigned int icon_height);
49 int g2_X11_delete(int pid, void *pdp);
50 int g2_X11_clear(int pid, void *pdp);
51 int g2_X11_flush(int pid, void *pdp);
52 int g2_X11_ink(int pid, void *pdp,
53                double red, double green, double blue);
54 int g2_X11_clear_palette(int pid, void *pdp);
55 int g2_X11_reset_palette(int pid, void *pdp);
56 int g2_X11_set_background(int pid, void *pdp, int color);
57 int g2_X11_pen(int pid, void *pdp, int color);
58 int g2_X11_paper(int pid, void *pdp, int color);
59 int g2_X11_set_line_width(int pid, void *pdp, int w);
60 int g2_X11_set_dash(int pid, void *pdp, int n, int *data);
61 int g2_X11_set_font_size(int pid, void *pdp, int size);
62 int g2_X11_plot(int pid, void *pdp, int x, int y);
63 int g2_X11_line(int pid, void *pdp, int x1, int y1, int x2, int y2);
64 int g2_X11_poly_line(int pid, void *pdp, int N, int *p);
65 int g2_X11_polygon(int pid, void *pdp, int N, int *p);
66 int g2_X11_filled_polygon(int pid, void *pdp, int N, int *p);
67 int g2_X11_triangle(int pid, void *pdp,
68                     int x1, int y1,
69                     int x2, int y2,
70                     int x3, int y3);
71 int g2_X11_filled_triangle(int pid, void *pdp, int x1, int y1,
72                            int x2, int y2,
73                            int x3, int y3);
74 int g2_X11_rectangle(int pid, void *pdp, int x1, int y1, int x2, int y2);
75 int g2_X11_filled_rectangle(int pid, void *pdp,
76                             int x1, int y1, int x2, int y2);
77 int g2_X11_arc(int pid, void *pdp, int x, int y,
78                int r1, int r2, double a1, double a2);
79 int g2_X11_filled_arc(int pid, void *pdp, int x, int y,
80                       int r1, int r2, double a1, double a2);
81 int g2_X11_ellipse(int pid, void *pdp, int x, int y, int r1, int r2);
82 int g2_X11_filled_ellipse(int pid, void *pdp, int x, int y, int r1, int r2);
83 int g2_X11_draw_string(int pid, void *pdp, int x, int y, const char *text);
84 int g2_X11_image(int pid, void *pdp,
85                  int x, int y, int width, int height, int *pen_array);
86 int g2_X11_query_pointer(int pid, void *pdp,
87                          int *x, int *y, unsigned int *button);
88 int g2_X11_get_pd_handles(int pid, void *pdp, void *handles[G2_PD_HANDLES_SIZE]);
89 #endif /* _G2_X11_P_H */
90
91
92
93
94