Compare commits

...

4 commits

Author SHA1 Message Date
Roman Telezhynskyi 0b6abc6bbb Update MSVC version. 2024-01-13 08:38:41 +02:00
Roman Telezhynskyi 97bc0266c2 Fix compatibility with Qt 5.6. 2024-01-13 08:33:22 +02:00
Roman Telezhynskyi ea57284c1c Forward declaration is not enough. 2024-01-13 08:29:42 +02:00
Roman Telezhynskyi 3cfb25869a Skip patching if already patched and cached. 2024-01-13 08:22:34 +02:00
5 changed files with 12 additions and 11 deletions

View file

@ -257,7 +257,7 @@ macos_task_template: &MACOS_TASK_TEMPLATE
- qbs --version
# Patch Qbs. Remove after Qbs 2.2.1+.
- curl https://gist.githubusercontent.com/dismine/43f3c51e05f3317c5d4fe16cd3c4b6d8/raw/2d297bcb53c2c022f740509923adf1eb1796afe2/qbs-pkg-config-probe.patch --output $HOME/qbs-pkg-config-probe.patch --silent
- patch -d $(brew --prefix qbs)/ -p1 < $HOME/qbs-pkg-config-probe.patch
- patch -N -d $(brew --prefix qbs)/ -p1 < $HOME/qbs-pkg-config-probe.patch
- rm $HOME/qbs-pkg-config-probe.patch
build_script:
- echo $PATH

View file

@ -187,7 +187,7 @@ environment:
BUILD_SYSTEM: "qbs"
QMAKE: qmake.exe
ENABLE_PCH: true
MSVC_PATH: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\VC\\Tools\\MSVC\\14.37.32822\\bin\\Hostx64\\x64"
MSVC_PATH: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\VC\\Tools\\MSVC\\14.38.33130\\bin\\Hostx64\\x64"
VSINSTALLDIR: "C:\\Program Files\\Microsoft Visual Studio\\2022\\Community\\"
ARCH: x64
PYTHON: "C:\\Python311-x64"
@ -728,7 +728,7 @@ for:
- qbs --version
# Patch Qbs. Remove after Qbs 2.2.1+.
- curl https://gist.githubusercontent.com/dismine/43f3c51e05f3317c5d4fe16cd3c4b6d8/raw/2d297bcb53c2c022f740509923adf1eb1796afe2/qbs-pkg-config-probe.patch --output $HOME/qbs-pkg-config-probe.patch --silent
- patch -d $(brew --prefix qbs)/ -p1 < $HOME/qbs-pkg-config-probe.patch
- patch -N -d $(brew --prefix qbs)/ -p1 < $HOME/qbs-pkg-config-probe.patch
- rm $HOME/qbs-pkg-config-probe.patch
- /usr/bin/curl -LJ https://github.com/dismine/macdeployqt/archive/refs/heads/main.zip --output ${HOME}/macdeployqt-main.zip --silent
- unzip ${HOME}/macdeployqt-main.zip -d ${HOME}
@ -911,7 +911,7 @@ for:
- qbs --version
# Patch Qbs. Remove after Qbs 2.2.1+.
- curl https://gist.githubusercontent.com/dismine/43f3c51e05f3317c5d4fe16cd3c4b6d8/raw/2d297bcb53c2c022f740509923adf1eb1796afe2/qbs-pkg-config-probe.patch --output $HOME/qbs-pkg-config-probe.patch --silent
- patch -d $(brew --prefix qbs)/ -p1 < $HOME/qbs-pkg-config-probe.patch
- patch -N -d $(brew --prefix qbs)/ -p1 < $HOME/qbs-pkg-config-probe.patch
- rm $HOME/qbs-pkg-config-probe.patch
- /usr/bin/curl -LJ https://github.com/dismine/macdeployqt/archive/refs/heads/main.zip --output ${HOME}/macdeployqt-main.zip --silent
- unzip ${HOME}/macdeployqt-main.zip -d ${HOME}

View file

@ -17,6 +17,9 @@
#include "drw_header.h"
#include "drw_interface.h"
#include "drw_objects.h"
#include "intern/dxfreader.h"
#include "intern/dxfwriter.h"
#include <string>
#include <unordered_map>
@ -25,9 +28,6 @@
#include <ciso646> // and, not, or
#endif
class dxfReader;
class dxfWriter;
class dxfRW
{
public:

View file

@ -507,7 +507,7 @@ auto VFoldLine::TrueCenter(const QLineF &base, qreal width) const -> QPointF
if (VFuzzyComparePossibleNulls(base.length(), width) || qFuzzyIsNull(width))
{
return base.center();
return LineCenter(base);
}
QLineF seg1 = base;

View file

@ -1680,8 +1680,8 @@ auto VPiece::SeamAllowanceMirrorLine(const VContainer *data) const -> QLineF
QRectF rec = QRectF(0, 0, INT_MAX, INT_MAX);
rec.translate(-INT_MAX / 2.0, -INT_MAX / 2.0);
QLineF axis =
QLineF(seamMirrorLine.center(), VGObject::BuildRay(seamMirrorLine.center(), seamMirrorLine.angle() + 180, rec));
QLineF axis = QLineF(LineCenter(seamMirrorLine),
VGObject::BuildRay(LineCenter(seamMirrorLine), seamMirrorLine.angle() + 180, rec));
QVector<QPointF> points;
CastTo(SeamAllowancePoints(data), points);
@ -1695,7 +1695,8 @@ auto VPiece::SeamAllowanceMirrorLine(const VContainer *data) const -> QLineF
const QPointF startPoint = intersections.constFirst();
std::reverse(points.begin(), points.end());
axis = QLineF(seamMirrorLine.center(), VGObject::BuildRay(seamMirrorLine.center(), seamMirrorLine.angle(), rec));
axis =
QLineF(LineCenter(seamMirrorLine), VGObject::BuildRay(LineCenter(seamMirrorLine), seamMirrorLine.angle(), rec));
intersections = VAbstractCurve::CurveIntersectLine(points, axis);
if (intersections.isEmpty())
{