diff --git a/graphics/grTCairo1.c b/graphics/grTCairo1.c index 9e1d710d..be9d3fd9 100644 --- a/graphics/grTCairo1.c +++ b/graphics/grTCairo1.c @@ -216,6 +216,8 @@ grtcairoSetStipple (stipple) int stipple; /* The stipple number to be used. */ { static int oldStip = -1; + cairo_matrix_t matrix; + if (stipple == oldStip) return; oldStip = stipple; GR_TCAIRO_FLUSH_BATCH(); @@ -223,6 +225,10 @@ int stipple; /* The stipple number to be used. */ currentStipple = cairo_pattern_create_rgba(0, 0, 0, 1); } else { if (stipplePatterns[stipple] == (cairo_pattern_t *)NULL) MainExit(1); + + /* Patterns will be upside-down if not transformed like the window */ + cairo_matrix_init_scale (&matrix, 1.0, -1.0); + cairo_pattern_set_matrix (stipplePatterns[stipple], &matrix); cairo_pattern_set_extend(stipplePatterns[stipple], CAIRO_EXTEND_REPEAT); cairo_pattern_set_filter(stipplePatterns[stipple], CAIRO_FILTER_NEAREST); currentStipple = stipplePatterns[stipple]; diff --git a/graphics/grTkCommon.c b/graphics/grTkCommon.c index b88ffec1..20244ea5 100644 --- a/graphics/grTkCommon.c +++ b/graphics/grTkCommon.c @@ -743,8 +743,8 @@ typedef struct LayerInstance { */ static int ImgLayerCreate _ANSI_ARGS_((Tcl_Interp *interp, - const char *name, int argc, Tcl_Obj *CONST objv[], - const Tk_ImageType *typePtr, Tk_ImageMaster master, + CONST86 char *name, int argc, Tcl_Obj *const objv[], + CONST86 Tk_ImageType *typePtr, Tk_ImageMaster master, ClientData *clientDataPtr)); static ClientData ImgLayerGet _ANSI_ARGS_((Tk_Window tkwin, ClientData clientData));