Our last post before the new year and some new material is an update to the
ImageBox (now at version 188.8.131.52) and
TabList (at version 184.108.40.206) controls. You can grab the updated source from the links at the end of the post, or from the GitHub page.
Changes and new features
IsPointInImagemethod. This function returns if a given point is within the image viewport, and is useful for combining with
ImageBorderColorproperty, allowing you to customize the color of the image border
- Added a new
FixedSingleGlowShadow. This style allows for a more smoother outer glow shadow instead of the existing clunky drop shadow.
PixelGridColorproperties. When set, a dotted grid is displayed around pixels when zooming in on an image.
- Added new overload to
PointToImagewhich allows you to specify if the function should map the given point to the nearest available edge(s) if the point is outside the image boundaries
AllowDoubleClickproperty. When set, the normal double click events and overrides work as expected.
VirtualSizeproperties. These new properties allow you to use all functionality of the ImageBox control without having to set the
Imageproperty. You can also use the new
VirtualDrawevent to provide custom drawing without having to override existing drawing functionality.
- Additional documentation added via XML comments
- If the
GridDisplayModeproperty is set to
Imagean explicit image border is no longer drawn, instead the
ImageBorderproperty is correctly honoured.
- Fixes a problem where half the pixels of the first row/column were lost when zooming. Thanks to Rotem for the fix.
GetImageViewportmethod now correctly returns a width and height that accounts for control size, padding and zoom levels.
- Fixed incorrect attributes on
- Fixed the image viewport sometimes being the incorrect size when zoomed in. Thanks to WMJ for the fix.
- Fixes "see also" documentation errors for events
Changes and new features
ShowTabListproperty. When set to
False, the list of tabs is no longer displayed, and navigation can only occur via code.
AllowTabSelectionproperty. When set to
False, the control can no longer gain focus, mouse hover effects are not displayed, and navigation can only occur via code. This allows you to disable navigation whilst still having the tabs visible.
- Fixed the
HoverIndexproperty always defaulting to zero.
Happy New Year all!
Related articles you may be interested in
- Displaying multi-page tiff files using the ImageBox control and C#
- Adding drag handles to an ImageBox to allow resizing of selection regions
- ImageBox 220.127.116.11 update
- ImageBox update, version 18.104.22.168
- Zooming to fit a region in a ScrollableControl
- Zooming into a fixed point on a ScrollableControl
- Arcade explosion generator
- Creating an image viewer in C# Part 5: Selecting part of an image
- Extending the ImageBox component to display the contents of a PDF file using C#
- Creating a scrollable and zoomable image viewer in C# Part 4
- Creating a scrollable and zoomable image viewer in C# Part 3
- Creating a scrollable and zoomable image viewer in C# Part 2
- Creating a scrollable and zoomable image viewer in C# Part 1
Cyotek ImageBox Control, 22.214.171.124 update
Cyotek.Windows.Forms.TabList control, a multi-paged container control with design time support and a Visual Studio 2012 look