Follow-up Comment #10, bug #19352 (project gnustep):

I wrote a small test program and this shows that the problem with the clip
copying is completely within cairo. Here is the code:

#include <stddef.h>
#include <cairo.h>
#include <cairo-ps.h>

int 
main (int argc, const char *argv[])
{
  cairo_status_t status;
  cairo_t *ct;
  cairo_surface_t *surface;
  cairo_rectangle_list_t *clip_rects;
 
  surface = cairo_ps_surface_create("test.ps", 100, 100);
  status = cairo_surface_status(surface);
  if (status != CAIRO_STATUS_SUCCESS)
    {
      printf("Cairo status '%s' for surfacen",
cairo_status_to_string(status));
      return 0;
    }

  ct = cairo_create(surface);
  status = cairo_status(ct);
  if (status != CAIRO_STATUS_SUCCESS)
    {
      printf("Cairo status '%s' for contextn",
cairo_status_to_string(status));
      return 0;
    }

  cairo_reset_clip(ct);
  cairo_rectangle(ct, 10, 10, 80, 80);
  cairo_clip(ct);
  clip_rects = cairo_copy_clip_rectangle_list(ct);
  status = clip_rects->status;
  if (status != CAIRO_STATUS_SUCCESS)
    {
      printf("Cairo status '%s' in copy clipn",
cairo_status_to_string(status));
    }

  cairo_destroy(ct);
  cairo_surface_destroy(surface);
}


Compile with the usual command (eg. gcc -I/usr/local/include/cairo cairo.c
-L/usr/local/lib -L/usr/X11R6/lib -lcairo -lm -lfreetype -lz -lfontconfig
-lexpat -lpng12 -lXrender -lX11 -lpthread -o cairo_test)

THis leaves only the positioning of the draw area to be resolved in GNUstep.


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?19352>

_______________________________________________
  Nachricht geschickt von/durch Savannah
  http://savannah.gnu.org/



_______________________________________________
Bug-gnustep mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-gnustep

Reply via email to