title: Drawing to the left of x,y coordinates
body: <p>I'm working currently on Qt, when i try to draw something (for e.x Rectangle) giving its x,y coordinates &amp; its width &amp; height Qt starts to draw the rectangle starting from its x, y coordinates to the right direction, to demonstrate what I'm talking about see the following picture: </p>
  
  <p><a href="https://i.stack.imgur.com/u9VEu.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/u9VEu.png" alt="Rect1"></a>
  </p>
  
  <p>and the following code:</p>
  
  <pre><code>Rectangle {
      id: rectangle1
      x: 257
      y: 221
      width: 50
      height: 50
      color: "#000000"
  }
  </code></pre>
  
  <p>I would like to know if there is anyway i can start drawing to the left of x,y coordinates, it's like drawing giving the width &amp; height negative values. see the following image for illustration: </p>
  
  <p><a href="https://i.stack.imgur.com/bmpp5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/bmpp5.png" alt="Rect2"></a>
  </p>
  
  <p>I have tried drawing giving the width a negative value, it works fine on the design mode but when i run or debug my application the rectangle does not show up, any ideas on this would be appreciated</p>