![]() | Steema Issues DatabaseNote: This database is for bugs and wishes only. For technical support help, if you are a customer please visit our online forums;otherwise you can use StackOverflow. Before using this bug-tracker we recommend a look at this document, Steema Bug Fixing Policy. |
| Summary: | KeepAspectRatio allows to have the mouse pointer at a different position to the edge of the ZoomRect, resulting in a strange zooming area | ||
|---|---|---|---|
| Product: | VCL TeeChart | Reporter: | yeray alonso <yeray> |
| Component: | Axis | Assignee: | Steema Issue Manager <issuemanager> |
| Status: | RESOLVED FIXED | ||
| Severity: | enhancement | CC: | david |
| Priority: | --- | ||
| Version: | 131119 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows | ||
| URL: | http://www.teechart.net/support/viewtopic.php?f=3&t=14626 | ||
| Chart Series: | --- | Delphi / C++ Builder RAD IDE Version: | |
| Attachments: | test project | ||
Fixed. The problem was Chart MouseUp was forcing the ending zoom rectangle coordinates (X1,Y1) to be the mouse cursor position at mouseup. Also improved how is the zoom rectangle calculated when KeepAspectRatio=True. Now it follows better the mouse cursor position, either at bottom or right side. |
Created attachment 78 [details] test project With KeepAspectRatio=true, the ZoomRect being drawn tries to keep the aspect ratio of the original chart. The zoom rectangle being drawn is always proportional. However, when you release the mouse button, the area zoomed in is the area from the mouse position, not the area the zoom rectangle is defining. Note the top-left edge of the ZoomRect is always the mouse position where the MouseDown is made, but with KeepAspectRatio the bottom-right edge of the ZoomRect can be far below or far on the right side of the mouse position. See the project attached and the images on it.