Skip to main content

RepositoryItemPictureEdit.ShowZoomSubMenu Property

Gets or sets whether the picture editor’s context menu contains zoom-related commands.

Namespace: DevExpress.XtraEditors.Repository

Assembly: DevExpress.XtraEditors.v23.2.dll

NuGet Package: DevExpress.Win.Navigation

Declaration

[DefaultValue(DefaultBoolean.Default)]
[DXCategory("Behavior")]
public DefaultBoolean ShowZoomSubMenu { get; set; }

Property Value

Type Default Description
DefaultBoolean Default

A DefaultBoolean value that specifies if the picture editor’s context menu contains zoom-related commands.

Available values:

Name Description Return Value
True

The value is true.

0

False

The value is false.

1

Default

The value is specified by a global option or a higher-level object.

2

Remarks

If the RepositoryItemPictureEdit.ShowMenu option is set to true, the Picture Edit supports a context menu, which optionally may contain zoom-related commands:

PictureEdit_Class.gif

The zoom sub-menu is available in all image size modes (RepositoryItemPictureEdit.SizeMode) in the following cases:

  • the RepositoryItemPictureEdit.ShowZoomSubMenu property is set to Default and the RepositoryItemPictureEdit.ShowScrollBars property is set to true.
  • the RepositoryItemPictureEdit.ShowZoomSubMenu property is set to True.

The appearance of context menus is controlled by a dedicated Menu Manager object. For standalone PictureEdit controls, the Menu Manager is specified by the BaseEdit.MenuManager inherited property.

By default, the Zoom to menu command is not available. To display it, assign a BarManager object to the Picture Editor’s Menu Manager.

To zoom an image in code, use the RepositoryItemPictureEdit.ZoomPercent property.

An end-user can also zoom the image via the mouse and keyboard, provided that the zoom sub-menu is enabled and the RepositoryItemPictureEdit.SizeMode property is set to Clip. The following actions are supported:

Key/Key Combination Action
Add key (on the numeric keypad) Zooms the image in.
Subtract key (on the numeric keypad) Zooms the image out.
Multiply key (on the numeric keypad) Fits the image into the view region.
Divide key (on the numeric keypad) Displays the image in its original size, by setting the ShowZoomSubMenu to 100.
CTRL+MOUSE WHEEL Zooms the image in and out.

The zooming functionality via the menu is available in any image size mode (RepositoryItemPictureEdit.SizeMode). After a user invokes the zooming functionality via the context menu, the RepositoryItemPictureEdit.SizeMode property is automatically set to Clip, so the user is now able to zoom the image via the mouse and keyboard.

Note

Image scrolling and zooming is not supported for Metafile images.

See Also