2 Replies Latest reply on Mar 21, 2013 4:09 PM by morgalr

    Centering Shapes

      Not even sure this is where you post help questions, but if you were to draw a shape, the x,y coordinate determines the top-left corner of the shape. Is there any way to make the x,y the middle? I've tried more "amateur" forums, but since they're so abandoned, I have no choice but to turn to you with this simple question. Thank you!
        • 1. Re: Centering Shapes
          Short: no, you cannot make x and y centered.
          BUT: you can recalculate x and y to center the shape within your container or on screen.
          • 2. Re: Centering Shapes
            As mentioned by the mod... nope, but it can be calculated.

            What I usually do is make my object take care of painting itself, but parameters of convenience for control--graphics context, location, color, scale, and etc... that way I can send the centered coordinates to the object and it can calculate palcement according to scale.