ZoomBorder is designed to work both with direct input and with command surfaces such as toolbars, menus, and keyboard shortcuts.
The main command properties are:
ZoomInCommandZoomOutCommandResetCommandFitCommandFillCommandUniformCommandUniformToFillCommandNavigateBackCommandNavigateForwardCommandToggleStretchCommandBind them directly:
<StackPanel>
<Button Content="Zoom In" Command="{Binding #ZoomBorder.ZoomInCommand}" />
<Button Content="Zoom Out" Command="{Binding #ZoomBorder.ZoomOutCommand}" />
<Button Content="Reset" Command="{Binding #ZoomBorder.ResetCommand}" />
<Button Content="Back" Command="{Binding #ZoomBorder.NavigateBackCommand}" />
</StackPanel>
When EnableKeyboardNavigation is enabled:
+ and = zoom in- zoom outCtrl+0 resets the viewHome fits content to the viewportCtrl+Left and Ctrl+Right navigate historyFocusable="True" on the control if you rely on keyboard input.ZoomIn(...), ResetMatrix(...), or CenterOn(...).