mirror of
https://github.com/greenshot/greenshot
synced 2025-08-19 13:10:00 -07:00
Fix: zoom-in when selection is out of sight
This commit is contained in:
parent
b2a6fc8774
commit
79ea558dbb
1 changed files with 4 additions and 3 deletions
|
@ -1590,10 +1590,11 @@ namespace Greenshot {
|
||||||
var size = surface.Size;
|
var size = surface.Size;
|
||||||
if (value > Surface.ZoomFactor) // being smart on zoom-in
|
if (value > Surface.ZoomFactor) // being smart on zoom-in
|
||||||
{
|
{
|
||||||
var sel = surface.GetSelectionRectangle();
|
var selection = surface.GetSelectionRectangle();
|
||||||
if (sel != Rectangle.Empty)
|
selection.Intersect(rc);
|
||||||
|
if (selection != Rectangle.Empty)
|
||||||
{
|
{
|
||||||
rc.Intersect(sel); // zoom to visible part of selection
|
rc = selection; // zoom to visible part of selection
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue