Click or drag to resize

ZoomPanel Methods

The ZoomPanel type exposes the following members.

Methods
  NameDescription
Public methodCode exampleCalculateVisibleArea
Calculates the visible area that would be shown if ZoomPanel.Viewbox would be (0,0,1,1).
Public methodFitToHeight
Sets the zoom and translation to show the whole height of the ZoomPanel's content.
Public methodFitToLimitsHeight
Sets the zoom and translation to show the whole limits height of the ZoomPanel's content.
Public methodFitToLimitsWidth
Sets the zoom and translation to show the whole limits width of the ZoomPanel's content (if ZoomPanel is Limited)
Public methodFitToWidth
Sets the zoom and translation to show the whole width of the ZoomPanel's content.
Public methodGetCenterPosition
Returns center positions as Point in the specified units (relative or absolute) and from the specified viewbox.
Public methodGetContentSize
Gets the size of the ZoomPanel's content.
Public methodGetViewboxFromCenterAndZoomFactor
Returns viewbox as Rect from the specified centerPosition, its units and zoomFactor.
Public methodGetZoomFactor
Returns the zoom factor from the specified viewbox as Rect. The method can be overridden to provide custom zoom factor calculations - for example exponential.
Public methodLineDown
IScrollInfo.LineDown
Public methodLineLeft
IScrollInfo.LineLeft
Public methodLineRight
IScrollInfo.LineRight
Public methodLineUp
IScrollInfo.LineUp
Public methodMakeVisible
IScrollInfo.MakeVisible
Public methodMouseWheelDown
IScrollInfo.MouseWheelDown
Public methodMouseWheelLeft
IScrollInfo.MouseWheelLeft
Public methodMouseWheelRight
IScrollInfo.MouseWheelRight
Public methodMouseWheelUp
IScrollInfo.MouseWheelUp
Public methodOnApplyTemplate
OnApplyTemplate
(Overrides FrameworkElementOnApplyTemplate.)
Public methodPageDown
IScrollInfo.PageDown
Public methodPageLeft
IScrollInfo.PageLeft
Public methodPageRight
IScrollInfo.PageRight
Public methodPageUp
IScrollInfo.PageUp
Public methodRefresh
Forces the ZoomPanel to immediately recalculate the visible area based on the current Viewbox settings.
Public methodCode exampleRegisterCustomContentProvider
Registers the ZoomPanel control to show custom content. With custom content the ZoomPanel does not apply scale and translate transform to its content but instead calls the customContentProvider delegate that returns the custom content based on the current zoom parameters.
Public methodReset
Resets the zoom and translation to show the whole content of ZoomPanel (Viewbox="0 0 1 1"). The method also resets the RotationAngle to 0.
Public methodResetNow
Immediately resets the zoom and translation to show the whole content of ZoomPanel (Viewbox="0 0 1 1"). The method also resets the RotationAngle to 0.
Public methodResetToLimits
Resets the zoom and translation to show the content of ZoomPanel based on the ViewboxLimits. If Viewbox is not limited (IsViewboxLimited == false), the method is the same as Reset method. The method also resets the RotationAngle to 0.
Public methodResetToLimitsNow
Resets the zoom and translation to show the whole content of ZoomPanel. The method also resets the RotationAngle to 0.
Public methodSetHorizontalOffset
IScrollInfo.SetHorizontalOffset
Public methodSetVerticalOffset
IScrollInfo.SetVerticalOffset
Public methodSetViewbox
Sets the viewbox relative to the ZoomPanel content.
Public methodSetViewboxNow
Immediately sets the viewbox relative to the ZoomPanel content.
Public methodSetZoom(Double)
Sets the zoom area to the currently set CenterPosition and the zoomFactor parameter. If IsAnimated property is true, the zoom area change is animated.
Public methodSetZoom(Point)
Sets the zoom area to centerPosition parameter (in the current CenterPositionUnits) and the currently set ZoomFactor. If IsAnimated property is true, the zoom area change is animated.
Public methodCode exampleSetZoom(Rect)
Sets the zoom area to the new viewbox. If IsAnimated property is true, the zoom area change is animated.
Public methodSetZoom(Point, Double)
Sets the zoom area to centerPosition parameter (in the current CenterPositionUnits) and the zoomFactor parameter. If IsAnimated property is true, the zoom area change is animated.
Public methodSetZoom(Rect, Double)
Sets the zoom area to the new viewbox. If IsAnimated property is true, the zoom area change is animated.
Public methodSetZoom(Point, ZoomPanelCenterPositionUnitsType, Double)
Sets the zoom area based on centerPosition, units and zoomFactor parameters. If IsAnimated property is true, the viewbox change is animated.
Public methodSetZoom(Point, ZoomPanelCenterPositionUnitsType, Double, Double)
Sets the zoom area based on centerPosition, units and zoomFactor parameters. If IsAnimated property is true, the viewbox change is animated.
Public methodSetZoom(Point, ZoomPanelCenterPositionUnitsType, Double, Double, Boolean, Boolean)
Sets the zoom from the centerPosition and zoomFactor.
Public methodSetZoomNow(Double)
Sets the zoom area to the currently set CenterPosition and the zoomFactor parameter. The zoom area is changed immediately regardless of the IsAnimated property.
Public methodSetZoomNow(Point)
Sets the zoom area to centerPosition parameter (in the current CenterPositionUnits) and the currently set ZoomFactor. The zoom area is changed immediately regardless of the IsAnimated property.
Public methodCode exampleSetZoomNow(Rect)
Sets the zoom area to the new viewbox. The zoom area is changed immediately regardless of the IsAnimated property.
Public methodSetZoomNow(Point, Double)
Sets the zoom area to centerPosition parameter (in the current CenterPositionUnits) and the zoomFactor parameter. The zoom area is changed immediately regardless of the IsAnimated property.
Public methodSetZoomNow(Rect, Double)
Sets the zoom area to the new viewbox. If IsAnimated property is true, the zoom area change is animated.
Public methodSetZoomNow(Point, ZoomPanelCenterPositionUnitsType, Double)
Sets the zoom area based on centerPosition, units and zoomFactor parameters. The zoom area is changed immediately regardless of the IsAnimated property.
Public methodSetZoomNow(Point, ZoomPanelCenterPositionUnitsType, Double, Double)
Sets the zoom area based on centerPosition, units and zoomFactor parameters. The zoom area is changed immediately regardless of the IsAnimated property.
Public methodTranslate
Translates the content by the dx and dy (in absolute units)
Public methodTranslateNow
Translates the content by the dx and dy (in absolute units).
Public methodTranslateRelative
Translates the content by the dx and dy (in relative units: 1 is the whole width/height of ZoomPanel)
Public methodTranslateToCenter
Translates the content of ZoomPanel so that the mouseNewCenterPoint is shown in the center of ZoomPanel.
Public methodTranslateToCenterRelative
Translates the content of ZoomPanel so that the mouseNewCenterPoint is shown in the center of ZoomPanel. newRelativeCenterPoint is in relative coordinates - (0.5, 0.5) is the center of ZoomPanel
Public methodUnregisterCustomContentProvider
Unregisters the ZoomPanel control from custom content provider - from now on the ZoomPanel will use ViewboxEx to apply scale and translate transforms to its content
Public methodZoomAndTranslateToCenter
Zooms and translates the content of ZoomPanel so that the mouseNewCenterPoint is shown in the center of ZoomPanel. mouseNewCenterPoint is in absolute units.
Public methodZoomAndTranslateToCenterRelative
Zooms and translates the content of ZoomPanel so that the mouseNewCenterPoint is shown in the center of ZoomPanel. newRelativeCenterPoint is in relative coordinates - (0.5, 0.5) is the center of ZoomPanel
Public methodZoomAtMousePosition
Zooms the content of ZoomPanel so that the mousePosition stays at the same location.
Public methodZoomAtRelativeMousePosition
Zooms the content of ZoomPanel so that the mousePosition stays at the same location. relativeMousePosition is in relative coordinates - (0.5, 0.5) is the center of ZoomPanel.
Public methodZoomForFactor
Zooms the scene for the zoomFactor. For example zoom factor 2 means that the currently shown scene is scaled for factor 2 (for 100%).
Public methodZoomForRectangle(Rect)
Zooms and translates to show the content defined by newZoomRectangle (coordinates absolute units - from ZoomPanel's position and its ActualWidth and ActualHeight)
Public methodZoomForRectangle(Point, Point)
Zooms and translates to show the content defined by startPoint and endPoint (coordinates in absolute units - from ZoomPanel's position and its ActualWidth and ActualHeight)
Public methodZoomForRectangleRelative
Zooms and translates to show the content defined by newZoomRectangle (coordinates in relative units - 1,1 is right bottom corner or ZoomPanel)
Public methodZoomToFactor
Zooms the scene to the zoomFactor regardless of the current zoomFactor. For example zoomFactor 2 shows app. 50% of the content, 4 shows 25% of the content.
Top
See Also