VintaSoft Imaging .NET SDK v8.6
Vintasoft.Imaging.UI.VisualTools Namespace / PanTool Class
Members Example

In This Topic
    PanTool Class
    In This Topic
    Visual tool for panning an image in image viewer.
    Object Model
    PanTool ClassImageViewer Class
    Public NotInheritable Class PanTool 
       Inherits VisualTool
    public sealed class PanTool : VisualTool 
    public __gc __sealed class PanTool : public VisualTool 
    public ref class PanTool sealed : public VisualTool 
    Image in image viewer can be panned as follows:
    • place the mouse to the desired position
    • press and hold the action button (VisualTool.ActionButton)
    • pull the cursor for panning the image

    If VisualTool.ActionButton is set to right mouse button, context menu during action can be disabled with the VisualTool.DisableContextMenu property.
    This example shows how to set the PanTool as active visual in Vintasoft.Imaging.UI.ImageViewer.
    Class PanToolExample
        Public Sub SetPanToolAsActiveVisualToolOfImageViewer(viewer As Vintasoft.Imaging.UI.ImageViewer)
            ' create an instance of the PanTool class
            Dim panTool1 As New Vintasoft.Imaging.UI.VisualTools.PanTool()
            ' set the tool as the current tool of the ImageViewer
            viewer.VisualTool = panTool1
        End Sub
    End Class
    class PanToolExample
        public void SetPanToolAsActiveVisualToolOfImageViewer(
            Vintasoft.Imaging.UI.ImageViewer viewer)
            // create an instance of the PanTool class
            Vintasoft.Imaging.UI.VisualTools.PanTool panTool1 =
                new Vintasoft.Imaging.UI.VisualTools.PanTool();
            // set the tool as the current tool of the ImageViewer
            viewer.VisualTool = panTool1;
    Inheritance Hierarchy



    Target Platforms: Windows 10, Windows 8, Windows 7, Windows Vista, Windows XP, Windows Server 2012, Windows Server 2008, Windows Server 2003

    See Also