Infragistics Home

Infragistics Forums

Infragistics community online discussions.
Welcome to Infragistics Forums Sign in | FAQ
in Search

ultraPrintPreviewControl Scrollbar width and position

Last post 07-17-2008 8:39 by [Infragistics] Andrew Smith. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 07-03-2008 14:11

    • rasiue
    • Not Ranked
    • Joined on 01-28-2008
    • Points 80

    ultraPrintPreviewControl Scrollbar width and position

    Is there a way to obtain the position and width of the horizontal and vertical scrollbar of the ultraPrintPreviewControl? I need this because i wanted to implement the actions: zoom in and zoom out when the user clicks on the control. Problem is, that I don't want the zoom action to execute when I click at the scrollbars of the control, only the document, but can't find a way to obtain the position and width of the scrollbar. I can try to guess it by try an error, but I need that there be a method or property since using a fixed width and position won't help when users uses different windows themes, where scrollbars appearance and sizes changes.

     Another approach I wanted to do is if it exists a way to determine the position of the printing area document, that is excluding the gray background of the control, only the document, such that only when I click on the document printing area, I can zoom in, otherwise no.

     Hope I explained my troubles well and that someone can help me out here.

     

    Thx in advance 

    • Post Points: 20
  • 07-17-2008 8:39 In reply to

    Re: ultraPrintPreviewControl Scrollbar width and position

    The area of the control that contains the pages is the PreviewPageAreaUIElement. So you can either handle the MouseEnterElement and MouseLeaveElement watching for this element and keep a flag or you can get this element from the control's main element and check its Rect. For the latter, you can use something like this to get the element: ((IUltraControlElement)this.ultraPrintPreviewControl1).MainUIElement.GetDescendant(typeof(PreviewPageAreaUIElement)).

    • Post Points: 5
Page 1 of 1 (2 items)
Powered by Community Server (Commercial Edition), by Telligent Systems