Menu

shape size relative to canvas size

Help
mael15
2015-08-23
2015-08-25
  • mael15

    mael15 - 2015-08-23

    hi,
    first of all, great package! :)
    is there a way to keep shape sizes relative to the canvas size? i want to use a canvas as part of a printable page. the user can zoom that page with the mouse wheel, so everything on the canvas should zoom together with the page and canvas.
    i have found wxSFShapeCanvas::SetScale and it kind of goes in the right direction. but is there a way to just keep the relative sizes when i use wxWindowBase::SetSize?
    thank you!

     
  • iwbnwif

    iwbnwif - 2015-08-25

    Hi, I would like to help but I am afraid I don't understand your question.

    I thought that mouse wheel zooming is built in. When you zoom the canvas in the wxSFDemo using the mouse wheel all shapes change size relative to the canvas.

    Why do you want to change the size using wxWindowBase::SetSize? Do you mean (for example) that when you change the size of your application's window that the size of the shapes should scale accordingly?

     

Log in to post a comment.