title: Understanding cairo_scale()
body: <p>I am trying to understand the <code>cairo_scale()</code> function. There is a <a href="http://cairographics.org/manual/cairo-Transformations.html" rel="nofollow">documentation</a> but I still don't get it.</p>
  
  <p>Consider the following code </p>
  
  <pre><code>cairo_scale(cr,1./WIDTH,1./HEIGHT);
  cairo_move_to(cr,0,0);
  cairo_line_to(cr,1,1);
  cairo_stroke(cr); //draw a line across the image
  </code></pre>
  
  <p>and (the working version) without scale</p>
  
  <pre><code>cairo_move_to(cr,0,0);
  cairo_line_to(cr,WIDTH,HEIGHT);
  cairo_stroke(cr);
  </code></pre>
  
  <p>As far as I understand <code>cairo_scale(1/width,1/height)</code> should scale all following verbs, so the x and y ranges are from 0 to 1 (instead of 0 to WIDTH and 0 to HEIGHT).</p>
  
  <p>Unfortunately it does not work and I cannot see anything. What is my mistake? </p>