We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback
Platform : WinForms
Category : Drawing Tips

Are AutoScrolling bounds setup in World or Device coordinates

AutoScrollingMinSize is setup in device coordinates. If you are using a world coordinate system other than pixels this means that you have to translate between world and device coordinates before you set these value. You can use the Graphics.TransformPoints API to do this as shown below. All this does is go from the GraphicsUnit that you are using to pixels. For example if your GraphicsUnit is Inch, then with a Graphics object that represents a monitor screen you will have translated values that come to about 100 pixels for every logical inch. Using this API ensures that you are insulated from the underlying device. The values will be much higher for printers. Another important point to remember is that your Transform in the painting code (please refer earlier FAQ in this section on AutoScrolling implementation) will have to be in logical coordinates and will hence have to translate between logical and device coordinates. Play around with the sample and all should be clear. When you run the sample nothing will be seen on the screen. Scroll around. Remember the logical units are in inches. You will be looking at a huge ellipse! Source: Syncfusion Staff

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon