Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
290
Scaling Expansion Indicator in Treeview
posted

We need to support very high DPI settings (the new Surface Pro's) and the TreeView expansion indicator does not scale and is incredibly tiny and hard to click.

Is there some way to increase the size of this so that it is possibly to use?


Thanks,


Terry

Parents
  • 469350
    Verified Answer
    Offline posted

    Hi Terry,

    There are really two separate issues here.

    One is the clickable area of the expansion indicator. The other is the actual appearance of the expansion indicator. And there are several approaches you could take here.

    I recommend putting an UltraTouchProvider on the form. This will automatically make a whole lot of things bigger in all of the Infragistics WinForms controls in order to better support Touch. The touch metrics calculate some good sizes measured in millimeters and taking the screen DPI into account. So this will make the clickable area of the expansion indicators much larger. 

    It will not change the appearance of the Expansion indicators, though - it just puts a big space around them and makes them easier to touch. Changing the appearance is a bit more complex and depends on a number of factors - primarily, whether or not you are using OS Themes. The themed expansion indicator will not draw any bigger, so there's not much we can do there. But you could apply your own images to the expansion indicator and use any image size you want. The images can be set directly on the tree control via properties like ExpansionIndicatorImageExpanded and ExpansionIndicatorImageCollapsed.

    Since the size will vary based on the system DPI, you might want to know what size the TouchProvider is using for the size of the expansion indicator area so you can generate an image of the appropriate size. You can get the size using a static method on TouchUtilites: 

    Infragistics.Win.Touch.TouchUtilities.GetTouchElementSize(Infragistics.Win.Touch.TouchElementSizes.Minimum);

Reply Children
No Data