Resize and Alignment of Objects

hi

I have some problems.

  1. After creating the button control on GoDrawView
    When I copy a button, copied new button is created in the below the exsiting button. GoDrawing and GoRectangle are not have this problem. How do I resoleve it.

  2. When I adjust the size of the object by using the size adjustment handle, Negative direction is not adjusted.
    (when hoding the bottom-right Resize handle and then, moving mouse upper direction, The minimum size is limited to zero at both axis)

please give me some advice and example code.

thanks.

  1. Sorry, I’m not seeing that behavior. you mean when you copy / paste, right?

  2. The GoButton class isn’t built to be resizable.

    Its size is determined by the size of the text and the TopLeftMargin and BottomRightMargin.

  1. Whenever creating new Control Objects(Gobutton, Editbox, etc), as well as Copy / paste, new Control objects are located below the exsiting button.
    I think it is related AddGoControl() method in GoView.cs.
    or SetChildIndex() method.

  2. All Objects(GoRectangle, GoDrawing, etc) are not adjusted to reverse direction.
    I think it is related MinumumSize is set 1 in GoToolResizing.cs

I want to resize all directions like MS PowerPoint’s Resizing…

please reply. Thank you very much.

I don’t see any code that sets the location of a GoControl. If you want to send me a small sample program, I’ll look into it.

You’ll have to write your own GoObject.DoResize method to get that behavior. BlockArrow in DrawDemo may be a good place to look for inspiration.