i draw two dividing rectangles on a surface (i do not want to overlap them) with the following code<br><br>#include <cairo/cairo-pdf.h><br><br>int<br>main (void)<br>{<br> cairo_surface_t *surface;<br> cairo_t *cr;<br>
surface = cairo_pdf_surface_create ("cairo_test_fill.pdf", 40, 60);<br> cr = cairo_create (surface);<br><br> cairo_save (cr);<br> cairo_translate (cr, 20, 20);<br> cairo_rectangle (cr, -10, -10, 20, 20);<br>
cairo_fill (cr);<br> cairo_restore (cr);<br><br> cairo_save (cr);<br> cairo_translate (cr, 20, 40);<br> cairo_rectangle (cr, -10, -10, 20, 20);<br> cairo_fill (cr);<br> cairo_restore (cr);<br><br> cairo_surface_write_to_png (surface, "cairo_test_fill.png");<br>
cairo_destroy (cr);<br> cairo_surface_destroy (surface);<br> return 0;<br>}<br><br>i see a dividing line between them on vectorial surface and not on image surface<br>how can i fix the problem on the vectorial surface?<br>
i suspect this is a device resolution dependent problem?<br>perhaps the rectangle API is a solution?<br><br>Thanks <br>