Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
- {
- // source center
- const qreal sourceTop = source.top();
- const qreal sourceLeft = source.left();
- const qreal sourceCenterTop = sourceTop + borders.sourceTopBorder;
- const qreal sourceCenterLeft = sourceLeft + borders.sourceLeftBorder;
- const qreal sourceCenterRight = source.right() - borders.sourceRightBorder;
- const qreal sourceCenterBottom = source.bottom() - borders.sourceBottomBorder;
- const qreal sourceCenterWidth = sourceCenterRight - borders.sourceLeftBorder;
- const qreal sourceCenterHeight = sourceCenterBottom - borders.sourceTopBorder;
- // target borders
- const qreal targetTopBorder = (borders.targetTopBorder == -1 ? borders.sourceTopBorder : borders.targetTopBorder);
- const qreal targetLeftBorder = (borders.targetLeftBorder == -1 ? borders.sourceLeftBorder : borders.targetLeftBorder);
- const qreal targetBottomBorder = (borders.targetBottomBorder == -1 ? borders.sourceBottomBorder : borders.targetBottomBorder);
- const qreal targetRightBorder = (borders.targetRightBorder == -1 ? borders.sourceRightBorder : borders.targetRightBorder);
- // target center
- const qreal targetTop = target.top();
- const qreal targetLeft = target.left();
- const qreal targetCenterTop = targetTop + targetTopBorder;
- const qreal targetCenterLeft = targetLeft + targetLeftBorder;
- const qreal targetCenterRight = target.right() - targetRightBorder;
- const qreal targetCenterBottom = target.bottom() - targetBottomBorder;
- const qreal targetCenterWidth = targetCenterRight - targetCenterLeft;
- const qreal targetCenterHeight = targetCenterBottom - targetCenterTop;

