mirror of
https://github.com/bancika/diy-layout-creator
synced 2026-11-11 01:32:08 +10:00
fix selection bounds
increase extra area
This commit is contained in:
@@ -67,7 +67,7 @@ public class DrawingManager {
|
||||
private static final Logger LOG = Logger.getLogger(DrawingManager.class);
|
||||
|
||||
public static int CONTROL_POINT_SIZE = 7;
|
||||
public static double EXTRA_SPACE = 0.2;
|
||||
public static double EXTRA_SPACE = 0.25;
|
||||
|
||||
public static final String ZOOM_KEY = "zoom";
|
||||
|
||||
|
||||
@@ -927,6 +927,15 @@ public class Presenter implements IPlugInPort {
|
||||
LOG.debug("Area is null for " + c.getName() + " of type "
|
||||
+ c.getClass().getName());
|
||||
}
|
||||
|
||||
if (ConfigurationManager.getInstance().readBoolean(EXTRA_SPACE_KEY, true)) {
|
||||
double extraSpace = drawingManager.getExtraSpace(currentProject);
|
||||
minX += extraSpace;
|
||||
maxX += extraSpace;
|
||||
minY += extraSpace;
|
||||
maxY += extraSpace;
|
||||
}
|
||||
|
||||
if (drawingManager.getZoomLevel() != 1 && applyZoom) {
|
||||
minX *= drawingManager.getZoomLevel();
|
||||
maxX *= drawingManager.getZoomLevel();
|
||||
|
||||
Reference in New Issue
Block a user