(*(chp) & 0x00ff)
-/* XXX: xfaces requires these structures, but the question is are we
- forced to use them? */
-typedef struct _XGCValues
-{
- unsigned long foreground;
- unsigned long background;
- void *font;
-} XGCValues;
-
-typedef XGCValues * GC;
-
-#define GCForeground 0x01
-#define GCBackground 0x02
-#define GCFont 0x03
-
-typedef void *Pixmap;
-
-typedef void *Cursor;
-
-#define No_Cursor (0)
+typedef void *Emacs_Cursor;
typedef void * Color;
typedef int Window;
else
{
/* Cursor on non-default face: must merge. */
- XGCValues xgcv;
+ Emacs_GC xgcv;
PGTK_TRACE("x_set_cursor_gc: 2.");
xgcv.background = FRAME_X_OUTPUT(s->f)->cursor_color;
{
/* Otherwise construct scratch_cursor_gc with values from FACE
except for FONT. */
- XGCValues xgcv;
+ Emacs_GC xgcv;
xgcv.background = s->face->background;
xgcv.foreground = s->face->foreground;
x_setup_relief_color (struct frame *f, struct relief *relief, double factor,
int delta, unsigned long default_pixel)
{
- XGCValues xgcv;
+ Emacs_GC xgcv;
struct pgtk_output *di = FRAME_X_OUTPUT(f);
unsigned long pixel;
unsigned long background = di->relief_background;
}
static void
-pgtk_cr_draw_image (struct frame *f, GC gc, cairo_pattern_t *image,
+pgtk_cr_draw_image (struct frame *f, Emacs_GC *gc, cairo_pattern_t *image,
int src_x, int src_y, int width, int height,
int dest_x, int dest_y, bool overlay_p)
{
PGTK_TRACE("which: %d, max_fringe_bmp: %d.", p->which, max_fringe_bmp);
if (p->which && p->which < max_fringe_bmp)
{
- XGCValues gcv;
+ Emacs_GC gcv;
PGTK_TRACE("cursor_p=%d.", p->cursor_p);
PGTK_TRACE("overlay_p_p=%d.", p->overlay_p);
}
void
-pgtk_set_cr_source_with_gc_foreground (struct frame *f, XGCValues *gc)
+pgtk_set_cr_source_with_gc_foreground (struct frame *f, Emacs_GC *gc)
{
PGTK_TRACE("pgtk_set_cr_source_with_gc_foreground: %08lx", gc->foreground);
pgtk_set_cr_source_with_color(f, gc->foreground);
}
void
-pgtk_set_cr_source_with_gc_background (struct frame *f, XGCValues *gc)
+pgtk_set_cr_source_with_gc_background (struct frame *f, Emacs_GC *gc)
{
PGTK_TRACE("pgtk_set_cr_source_with_gc_background: %08lx", gc->background);
pgtk_set_cr_source_with_color(f, gc->background);
mapped to display an hourglass cursor. */
GtkWidget *hourglass_widget;
- XGCValues cursor_xgcv;
+ Emacs_GC cursor_xgcv;
/* lord knows why Emacs needs to know about our Window ids.. */
Window window_desc, parent_desc;
/* Relief GCs, colors etc. */
struct relief
{
- XGCValues xgcv;
+ Emacs_GC xgcv;
unsigned long pixel;
}
black_relief, white_relief;
/* Cairo related functions implemented in pgtkterm.c */
extern cairo_t *pgtk_begin_cr_clip (struct frame *f);
extern void pgtk_end_cr_clip (struct frame *f);
-extern void pgtk_set_cr_source_with_gc_foreground (struct frame *f, XGCValues *gc);
-extern void pgtk_set_cr_source_with_gc_background (struct frame *f, XGCValues *gc);
+extern void pgtk_set_cr_source_with_gc_foreground (struct frame *f, Emacs_GC *gc);
+extern void pgtk_set_cr_source_with_gc_background (struct frame *f, Emacs_GC *gc);
extern void pgtk_set_cr_source_with_color (struct frame *f, unsigned long color);
extern void pgtk_cr_draw_frame (cairo_t *cr, struct frame *f);
extern void pgtk_cr_destroy_surface(struct frame *f);
#ifdef HAVE_PGTK
/* PGTK emulation of GCs */
-static GC
+static Emacs_GC *
x_create_gc (struct frame *f,
unsigned long mask,
- XGCValues *xgcv)
+ Emacs_GC *xgcv)
{
- GC gc = xmalloc (sizeof *gc);
+ Emacs_GC *gc = xmalloc (sizeof *gc);
*gc = *xgcv;
return gc;
}
static void
-x_free_gc (struct frame *f, GC gc)
+x_free_gc (struct frame *f, Emacs_GC *gc)
{
xfree (gc);
}