VTools static library.

--HG--
branch : feature
This commit is contained in:
Roman Telezhynskyi 2015-06-18 20:23:24 +03:00
parent b395465659
commit bfaeddfc85
298 changed files with 1333 additions and 946 deletions

View File

@ -16,7 +16,8 @@ DEPENDPATH += \
../src/libs/vlayout \ ../src/libs/vlayout \
../src/libs/vgeometry \ ../src/libs/vgeometry \
../src/libs/vpatterndb \ ../src/libs/vpatterndb \
../src/libs/vmisc ../src/libs/vmisc \
../src/libs/vtools
include(../src/app/app.pri) include(../src/app/app.pri)
include(../src/libs/qmuparser/qmuparser.pri) include(../src/libs/qmuparser/qmuparser.pri)
@ -26,6 +27,8 @@ include(../src/libs/vobj/vobj.pri)
include(../src/libs/vlayout/vlayout.pri) include(../src/libs/vlayout/vlayout.pri)
include(../src/libs/vgeometry/vgeometry.pri) include(../src/libs/vgeometry/vgeometry.pri)
include(../src/libs/vpatterndb/vpatterndb.pri) include(../src/libs/vpatterndb/vpatterndb.pri)
include(../src/libs/vmisc/vmisc.pri)
include(../src/libs/vtools/vtools.pri)
# Add here path to new translation file with name "valentina_*_*.ts" if you want to add new language. # Add here path to new translation file with name "valentina_*_*.ts" if you want to add new language.
# Same paths in variable INSTALL_TRANSLATIONS (app.pro). # Same paths in variable INSTALL_TRANSLATIONS (app.pro).

View File

@ -1,9 +1,6 @@
# Suport subdirectories. Just better project code tree. # Suport subdirectories. Just better project code tree.
include(dialogs/dialogs.pri) include(dialogs/dialogs.pri)
include(tools/tools.pri)
include(xml/xml.pri) include(xml/xml.pri)
include(undocommands/undocommands.pri)
include(visualization/visualization.pri)
include(core/core.pri) include(core/core.pri)
# ADD TO EACH PATH $$PWD VARIABLE!!!!!! # ADD TO EACH PATH $$PWD VARIABLE!!!!!!

View File

@ -83,6 +83,7 @@ CONFIG(debug, debug|release){
-isystem "$${OUT_PWD}/$${UI_DIR}" \ -isystem "$${OUT_PWD}/$${UI_DIR}" \
-isystem "$${OUT_PWD}/$${MOC_DIR}" \ -isystem "$${OUT_PWD}/$${MOC_DIR}" \
-isystem "$${OUT_PWD}/$${RCC_DIR}" \ -isystem "$${OUT_PWD}/$${RCC_DIR}" \
-isystem "$${OUT_PWD}/../libs/vtools/$${UI_DIR}" \ # For VTools UI files
$$GCC_DEBUG_CXXFLAGS # See Valentina.pri for more details. $$GCC_DEBUG_CXXFLAGS # See Valentina.pri for more details.
noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer noAddressSanitizer{ # For enable run qmake with CONFIG+=noAddressSanitizer
@ -101,6 +102,7 @@ CONFIG(debug, debug|release){
-isystem "$${OUT_PWD}/$${UI_DIR}" \ -isystem "$${OUT_PWD}/$${UI_DIR}" \
-isystem "$${OUT_PWD}/$${MOC_DIR}" \ -isystem "$${OUT_PWD}/$${MOC_DIR}" \
-isystem "$${OUT_PWD}/$${RCC_DIR}" \ -isystem "$${OUT_PWD}/$${RCC_DIR}" \
-isystem "$${OUT_PWD}/../libs/vtools/$${UI_DIR}" \ # For VTools UI files
$$CLANG_DEBUG_CXXFLAGS # See Valentina.pri for more details. $$CLANG_DEBUG_CXXFLAGS # See Valentina.pri for more details.
# -isystem key works only for headers. In some cases it's not enough. But we can't delete this warnings and # -isystem key works only for headers. In some cases it's not enough. But we can't delete this warnings and
@ -560,6 +562,27 @@ else:unix: LIBS += -L$${OUT_PWD}/../libs/vpropertyexplorer/$${DESTDIR} -lvproper
INCLUDEPATH += $${PWD}/../libs/vpropertyexplorer INCLUDEPATH += $${PWD}/../libs/vpropertyexplorer
DEPENDPATH += $${PWD}/../libs/vpropertyexplorer DEPENDPATH += $${PWD}/../libs/vpropertyexplorer
# When the GNU linker sees a library, it discards all symbols that it doesn't need.
# Add dependent library the first.
#VPatternDB static library (depend on vgeometry)
unix|win32: LIBS += -L$$OUT_PWD/../libs/vpatterndb/$${DESTDIR} -lvpatterndb
INCLUDEPATH += $$PWD/../libs/vpatterndb
DEPENDPATH += $$PWD/../libs/vpatterndb
win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vpatterndb/$${DESTDIR}/vpatterndb.lib
else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vpatterndb/$${DESTDIR}/libvpatterndb.a
# VGeometry static library (depend on ifc)
unix|win32: LIBS += -L$$OUT_PWD/../libs/vgeometry/$${DESTDIR}/ -lvgeometry
INCLUDEPATH += $$PWD/../libs/vgeometry
DEPENDPATH += $$PWD/../libs/vgeometry
win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vgeometry/$${DESTDIR}/vgeometry.lib
else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vgeometry/$${DESTDIR}/libvgeometry.a
# IFC static library # IFC static library
unix|win32: LIBS += -L$$OUT_PWD/../libs/ifc/$${DESTDIR}/ -lifc unix|win32: LIBS += -L$$OUT_PWD/../libs/ifc/$${DESTDIR}/ -lifc
@ -587,23 +610,15 @@ DEPENDPATH += $$PWD/../libs/vlayout
win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vlayout/$${DESTDIR}/vlayout.lib win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vlayout/$${DESTDIR}/vlayout.lib
else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vlayout/$${DESTDIR}/libvlayout.a else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vlayout/$${DESTDIR}/libvlayout.a
# VGeometry static library #VTools static library (depend on vwidgets and vmisc)
unix|win32: LIBS += -L$$OUT_PWD/../libs/vgeometry/$${DESTDIR}/ -lvgeometry unix|win32: LIBS += -L$$OUT_PWD/../libs/vtools/$${DESTDIR}/ -lvtools
INCLUDEPATH += $$PWD/../libs/vgeometry INCLUDEPATH += $$PWD/../libs/vtools
DEPENDPATH += $$PWD/../libs/vgeometry INCLUDEPATH += $$OUT_PWD/../libs/vtools/$${UI_DIR} # For UI files
DEPENDPATH += $$PWD/../libs/vtools
win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vgeometry/$${DESTDIR}/vgeometry.lib win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vtools/$${DESTDIR}/vtools.lib
else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vgeometry/$${DESTDIR}/libvgeometry.a else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vtools/$${DESTDIR}/libvtools.a
#VPatternDB static library
unix|win32: LIBS += -L$$OUT_PWD/../libs/vpatterndb/$${DESTDIR}/ -lvpatterndb
INCLUDEPATH += $$PWD/../libs/vpatterndb
DEPENDPATH += $$PWD/../libs/vpatterndb
win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vpatterndb/$${DESTDIR}/vpatterndb.lib
else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../libs/vpatterndb/$${DESTDIR}/libvpatterndb.a
#VMisc static library #VMisc static library
unix|win32: LIBS += -L$$OUT_PWD/../libs/vmisc/$${DESTDIR}/ -lvmisc unix|win32: LIBS += -L$$OUT_PWD/../libs/vmisc/$${DESTDIR}/ -lvmisc

View File

@ -32,7 +32,7 @@
#include "../libs/ifc/exception/vexceptionconversionerror.h" #include "../libs/ifc/exception/vexceptionconversionerror.h"
#include "../libs/ifc/exception/vexceptionemptyparameter.h" #include "../libs/ifc/exception/vexceptionemptyparameter.h"
#include "../libs/ifc/exception/vexceptionwrongid.h" #include "../libs/ifc/exception/vexceptionwrongid.h"
#include "vmaingraphicsview.h" #include "../libs/vwidgets/vmaingraphicsview.h"
#include "../version.h" #include "../version.h"
#include "../vmisc/logging.h" #include "../vmisc/logging.h"
@ -156,9 +156,9 @@ const QString VApplication::GistFileName = QStringLiteral("gist.json");
* @param argv command line. * @param argv command line.
*/ */
VApplication::VApplication(int &argc, char **argv) VApplication::VApplication(int &argc, char **argv)
: VAbstractApplication(argc, argv), _patternUnit(Unit::Cm), : VAbstractApplication(argc, argv),
trVars(nullptr), undoStack(nullptr), sceneView(nullptr), currentScene(nullptr), autoSaveTimer(nullptr), trVars(nullptr), autoSaveTimer(nullptr),
mainWindow(nullptr), openingPattern(false), doc(nullptr), log(nullptr), log(nullptr),
#if QT_VERSION >= QT_VERSION_CHECK(5, 1, 0) #if QT_VERSION >= QT_VERSION_CHECK(5, 1, 0)
out(nullptr), logLock(nullptr) out(nullptr), logLock(nullptr)
#else #else
@ -223,15 +223,6 @@ void VApplication::NewValentina(const QString &fileName)
} }
} }
//---------------------------------------------------------------------------------------------------------------------
void VApplication::CheckFactor(qreal &oldFactor, const qreal &Newfactor)
{
if (Newfactor <= 2 && Newfactor >= 0.5)
{
oldFactor = Newfactor;
}
}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**
* @brief notify Reimplemented from QApplication::notify(). * @brief notify Reimplemented from QApplication::notify().
@ -465,12 +456,6 @@ void VApplication::ClearOldLogs() const
} }
} }
//---------------------------------------------------------------------------------------------------------------------
void VApplication::setPatternUnit(const Unit &patternUnit)
{
_patternUnit = patternUnit;
}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
void VApplication::InitOptions() void VApplication::InitOptions()
{ {
@ -535,56 +520,6 @@ void VApplication::InitOptions()
} }
} }
//---------------------------------------------------------------------------------------------------------------------
double VApplication::toPixel(double val) const
{
return ToPixel(val, _patternUnit);
}
//---------------------------------------------------------------------------------------------------------------------
double VApplication::fromPixel(double pix) const
{
return FromPixel(pix, _patternUnit);
}
//---------------------------------------------------------------------------------------------------------------------
QWidget *VApplication::getMainWindow() const
{
return mainWindow;
}
//---------------------------------------------------------------------------------------------------------------------
void VApplication::setMainWindow(QWidget *value)
{
SCASSERT(value != nullptr)
mainWindow = value;
}
//---------------------------------------------------------------------------------------------------------------------
bool VApplication::getOpeningPattern() const
{
return openingPattern;
}
//---------------------------------------------------------------------------------------------------------------------
void VApplication::setOpeningPattern()
{
openingPattern = !openingPattern;
}
//---------------------------------------------------------------------------------------------------------------------
QGraphicsScene *VApplication::getCurrentScene() const
{
SCASSERT(currentScene != nullptr);
return currentScene;
}
//---------------------------------------------------------------------------------------------------------------------
void VApplication::setCurrentScene(QGraphicsScene *value)
{
currentScene = value;
}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
QStringList VApplication::LabelLanguages() QStringList VApplication::LabelLanguages()
{ {

View File

@ -36,7 +36,6 @@
#include "vsettings.h" #include "vsettings.h"
class VApplication;// use in define class VApplication;// use in define
class QUndoStack;
class VMainGraphicsView; class VMainGraphicsView;
class VPattern; class VPattern;
class QFile; class QFile;
@ -59,38 +58,18 @@ public:
VApplication(int &argc, char ** argv); VApplication(int &argc, char ** argv);
virtual ~VApplication(); virtual ~VApplication();
static void NewValentina(const QString &fileName = QString()); static void NewValentina(const QString &fileName = QString());
static void CheckFactor(qreal &oldFactor, const qreal &Newfactor);
virtual bool notify(QObject * receiver, QEvent * event); virtual bool notify(QObject * receiver, QEvent * event);
Unit patternUnit() const;
const Unit *patternUnitP() const;
void setPatternUnit(const Unit &patternUnit);
void InitOptions(); void InitOptions();
double toPixel(double val) const;
double fromPixel(double pix) const;
#if QT_VERSION >= QT_VERSION_CHECK(5, 1, 0) #if QT_VERSION >= QT_VERSION_CHECK(5, 1, 0)
static bool TryLock(QLockFile *lock); static bool TryLock(QLockFile *lock);
#endif //QT_VERSION >= QT_VERSION_CHECK(5, 1, 0) #endif //QT_VERSION >= QT_VERSION_CHECK(5, 1, 0)
QString translationsPath() const; QString translationsPath() const;
QUndoStack *getUndoStack() const;
VMainGraphicsView *getSceneView() const;
void setSceneView(VMainGraphicsView *value);
QTimer *getAutoSaveTimer() const; QTimer *getAutoSaveTimer() const;
void setAutoSaveTimer(QTimer *value); void setAutoSaveTimer(QTimer *value);
QWidget *getMainWindow() const;
void setMainWindow(QWidget *value);
bool getOpeningPattern() const;
void setOpeningPattern();
QGraphicsScene *getCurrentScene() const;
void setCurrentScene(QGraphicsScene *value);
void setCurrentDocument(VPattern *doc);
VPattern *getCurrentDocument()const;
static QStringList LabelLanguages(); static QStringList LabelLanguages();
@ -100,7 +79,6 @@ public:
virtual const VTranslateVars *TrVars(); virtual const VTranslateVars *TrVars();
void InitTrVars(); void InitTrVars();
#if defined(Q_OS_WIN) && defined(Q_CC_GNU) #if defined(Q_OS_WIN) && defined(Q_CC_GNU)
static void DrMingw(); static void DrMingw();
void CollectReports() const; void CollectReports() const;
@ -113,24 +91,9 @@ private slots:
private: private:
Q_DISABLE_COPY(VApplication) Q_DISABLE_COPY(VApplication)
Unit _patternUnit;
VTranslateVars *trVars; VTranslateVars *trVars;
QUndoStack *undoStack;
VMainGraphicsView *sceneView;
QGraphicsScene *currentScene;
QTimer *autoSaveTimer; QTimer *autoSaveTimer;
/**
* @brief mainWindow pointer to main window. Usefull if need create modal dialog. Without pointer to main window
* modality doesn't work.
*/
QWidget *mainWindow;
/**
* @brief openingPattern true when we opening pattern. If something will be wrong in formula this help understand if
* we can allow user use Undo option.
*/
bool openingPattern;
VPattern *doc;
QFile *log; QFile *log;
QTextStream *out; QTextStream *out;
#if QT_VERSION >= QT_VERSION_CHECK(5, 1, 0) #if QT_VERSION >= QT_VERSION_CHECK(5, 1, 0)
@ -155,36 +118,6 @@ private:
void ClearOldLogs()const; void ClearOldLogs()const;
}; };
//---------------------------------------------------------------------------------------------------------------------
inline Unit VApplication::patternUnit() const
{
return _patternUnit;
}
//---------------------------------------------------------------------------------------------------------------------
inline const Unit *VApplication::patternUnitP() const
{
return &_patternUnit;
}
//---------------------------------------------------------------------------------------------------------------------
inline QUndoStack *VApplication::getUndoStack() const
{
return undoStack;
}
//---------------------------------------------------------------------------------------------------------------------
inline VMainGraphicsView *VApplication::getSceneView() const
{
return sceneView;
}
//---------------------------------------------------------------------------------------------------------------------
inline void VApplication::setSceneView(VMainGraphicsView *value)
{
sceneView = value;
}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
inline QTimer *VApplication::getAutoSaveTimer() const inline QTimer *VApplication::getAutoSaveTimer() const
{ {
@ -197,17 +130,4 @@ inline void VApplication::setAutoSaveTimer(QTimer *value)
autoSaveTimer = value; autoSaveTimer = value;
} }
//---------------------------------------------------------------------------------------------------------------------
inline void VApplication::setCurrentDocument(VPattern *doc)
{
this->doc = doc;
}
//---------------------------------------------------------------------------------------------------------------------
inline VPattern *VApplication::getCurrentDocument() const
{
SCASSERT(doc != nullptr)
return doc;
}
#endif // VAPPLICATION_H #endif // VAPPLICATION_H

View File

@ -35,7 +35,7 @@
#include <QColorDialog> #include <QColorDialog>
#include "../../libs/vpropertyexplorer/vproperty.h" #include "../../libs/vpropertyexplorer/vproperty.h"
#include "../dialogs/tools/dialogeditwrongformula.h" #include "../../libs/vtools/dialogs/support/dialogeditwrongformula.h"
using namespace VPE; using namespace VPE;

View File

@ -27,9 +27,9 @@
*************************************************************************/ *************************************************************************/
#include "vtooloptionspropertybrowser.h" #include "vtooloptionspropertybrowser.h"
#include "../tools/drawTools/drawtools.h" #include "../../libs/vtools/tools/drawTools/drawtools.h"
#include "../core/vapplication.h" #include "../core/vapplication.h"
#include "vmaingraphicsview.h" #include "../../libs/vwidgets/vmaingraphicsview.h"
#include "../../libs/vwidgets/vgraphicssimpletextitem.h" #include "../../libs/vwidgets/vgraphicssimpletextitem.h"
#include "../../libs/vwidgets/vcontrolpointspline.h" #include "../../libs/vwidgets/vcontrolpointspline.h"
#include "../../libs/vpropertyexplorer/vproperties.h" #include "../../libs/vpropertyexplorer/vproperties.h"

View File

@ -31,10 +31,10 @@
#include "../../libs/vgeometry/varc.h" #include "../../libs/vgeometry/varc.h"
#include "../../libs/vgeometry/vsplinepath.h" #include "../../libs/vgeometry/vsplinepath.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../libs/vgeometry/vpointf.h"
#include "../../tools/vabstracttool.h" #include "../../libs/vtools/tools/vabstracttool.h"
#include "../../tools/drawTools/vtoolcutspline.h" #include "../../libs/vtools/tools/drawTools/vtoolcutspline.h"
#include "../../tools/drawTools/vtoolcutsplinepath.h" #include "../../libs/vtools/tools/drawTools/vtoolcutsplinepath.h"
#include "../../tools/drawTools/vtoolcutarc.h" #include "../../libs/vtools/tools/drawTools/vtoolcutarc.h"
#include "../../xml/vpattern.h" #include "../../xml/vpattern.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View File

@ -29,7 +29,7 @@
#ifndef DIALOGHISTORY_H #ifndef DIALOGHISTORY_H
#define DIALOGHISTORY_H #define DIALOGHISTORY_H
#include "../tools/dialogtool.h" #include "../../libs/vtools/dialogs/tools/dialogtool.h"
#include <QDomElement> #include <QDomElement>

View File

@ -34,6 +34,8 @@
#include "../../xml/vstandardmeasurements.h" #include "../../xml/vstandardmeasurements.h"
#include "../../xml/vindividualmeasurements.h" #include "../../xml/vindividualmeasurements.h"
#include "../../libs/vmisc/vsettings.h" #include "../../libs/vmisc/vsettings.h"
#include "../../libs/qmuparser/qmudef.h"
#include "../../libs/vpatterndb/vtranslatevars.h"
#include <QFileDialog> #include <QFileDialog>
#include <QDir> #include <QDir>

View File

@ -29,7 +29,7 @@
#ifndef DIALOGINCREMENTS_H #ifndef DIALOGINCREMENTS_H
#define DIALOGINCREMENTS_H #define DIALOGINCREMENTS_H
#include "../tools/dialogtool.h" #include "../../libs/vtools/dialogs/tools/dialogtool.h"
#include "../../xml/vpattern.h" #include "../../xml/vpattern.h"
class VIndividualMeasurements; class VIndividualMeasurements;

View File

@ -29,34 +29,6 @@
#ifndef DIALOGS_H #ifndef DIALOGS_H
#define DIALOGS_H #define DIALOGS_H
#include "tools/dialogalongline.h"
#include "tools/dialogarc.h"
#include "tools/dialogarcwithlength.h"
#include "tools/dialogbisector.h"
#include "tools/dialogdetail.h"
#include "tools/dialogendline.h"
#include "tools/dialogline.h"
#include "tools/dialoglineintersect.h"
#include "tools/dialognormal.h"
#include "tools/dialogpointofcontact.h"
#include "tools/dialogshoulderpoint.h"
#include "tools/dialogsinglepoint.h"
#include "tools/dialogspline.h"
#include "tools/dialogsplinepath.h"
#include "tools/dialogheight.h"
#include "tools/dialogcutarc.h"
#include "tools/dialogcutspline.h"
#include "tools/dialogcutsplinepath.h"
#include "tools/dialoguniondetails.h"
#include "tools/dialogtriangle.h"
#include "tools/dialogpointofintersection.h"
#include "tools/dialoglineintersectaxis.h"
#include "tools/dialogcurveintersectaxis.h"
#include "tools/dialogpointofintersectionarcs.h"
#include "tools/dialogpointofintersectioncircles.h"
#include "tools/dialogpointfromcircleandtangent.h"
#include "tools/dialogpointfromarcandtangent.h"
#include "app/dialoghistory.h" #include "app/dialoghistory.h"
#include "app/dialogincrements.h" #include "app/dialogincrements.h"
#include "app/configdialog.h" #include "app/configdialog.h"

View File

@ -3,29 +3,6 @@
HEADERS += \ HEADERS += \
$$PWD/dialogs.h \ $$PWD/dialogs.h \
$$PWD/tools/dialogtriangle.h \
$$PWD/tools/dialogtool.h \
$$PWD/tools/dialogsplinepath.h \
$$PWD/tools/dialogspline.h \
$$PWD/tools/dialogsinglepoint.h \
$$PWD/tools/dialogshoulderpoint.h \
$$PWD/tools/dialogpointofintersection.h \
$$PWD/tools/dialogpointofcontact.h \
$$PWD/tools/dialognormal.h \
$$PWD/tools/dialoglineintersect.h \
$$PWD/tools/dialogline.h \
$$PWD/tools/dialogheight.h \
$$PWD/tools/dialogendline.h \
$$PWD/tools/dialogdetail.h \
$$PWD/tools/dialogbisector.h \
$$PWD/tools/dialogarc.h \
$$PWD/tools/dialogalongline.h \
$$PWD/tools/dialogcutspline.h \
$$PWD/tools/dialogcutsplinepath.h \
$$PWD/tools/dialoguniondetails.h \
$$PWD/tools/dialogcutarc.h \
$$PWD/tools/dialogeditwrongformula.h \
$$PWD/tools/dialoglineintersectaxis.h \
$$PWD/app/dialogincrements.h \ $$PWD/app/dialogincrements.h \
$$PWD/app/dialoghistory.h \ $$PWD/app/dialoghistory.h \
$$PWD/app/configdialog.h \ $$PWD/app/configdialog.h \
@ -40,41 +17,11 @@ HEADERS += \
$$PWD/app/configpages/patternpage.h \ $$PWD/app/configpages/patternpage.h \
$$PWD/app/configpages/communitypage.h \ $$PWD/app/configpages/communitypage.h \
$$PWD/app/configpages/pathpage.h \ $$PWD/app/configpages/pathpage.h \
$$PWD/app/dialogundo.h \
$$PWD/tools/dialogcurveintersectaxis.h \
$$PWD/app/dialoglayoutsettings.h \ $$PWD/app/dialoglayoutsettings.h \
$$PWD/app/dialoglayoutprogress.h \ $$PWD/app/dialoglayoutprogress.h \
$$PWD/app/dialogsavelayout.h \ $$PWD/app/dialogsavelayout.h
$$PWD/tools/dialogpointofintersectionarcs.h \
$$PWD/tools/dialogpointofintersectioncircles.h \
$$PWD/tools/dialogpointfromcircleandtangent.h \
$$PWD/tools/dialogpointfromarcandtangent.h \
$$PWD/tools/dialogarcwithlength.h
SOURCES += \ SOURCES += \
$$PWD/tools/dialogtriangle.cpp \
$$PWD/tools/dialogtool.cpp \
$$PWD/tools/dialogsplinepath.cpp \
$$PWD/tools/dialogspline.cpp \
$$PWD/tools/dialogsinglepoint.cpp \
$$PWD/tools/dialogshoulderpoint.cpp \
$$PWD/tools/dialogpointofintersection.cpp \
$$PWD/tools/dialogpointofcontact.cpp \
$$PWD/tools/dialognormal.cpp \
$$PWD/tools/dialoglineintersect.cpp \
$$PWD/tools/dialogline.cpp \
$$PWD/tools/dialogheight.cpp \
$$PWD/tools/dialogendline.cpp \
$$PWD/tools/dialogdetail.cpp \
$$PWD/tools/dialogbisector.cpp \
$$PWD/tools/dialogarc.cpp \
$$PWD/tools/dialogalongline.cpp \
$$PWD/tools/dialogcutspline.cpp \
$$PWD/tools/dialogcutsplinepath.cpp \
$$PWD/tools/dialoguniondetails.cpp \
$$PWD/tools/dialogcutarc.cpp \
$$PWD/tools/dialogeditwrongformula.cpp \
$$PWD/tools/dialoglineintersectaxis.cpp \
$$PWD/app/dialogincrements.cpp \ $$PWD/app/dialogincrements.cpp \
$$PWD/app/dialoghistory.cpp \ $$PWD/app/dialoghistory.cpp \
$$PWD/app/configdialog.cpp \ $$PWD/app/configdialog.cpp \
@ -88,40 +35,11 @@ SOURCES += \
$$PWD/app/configpages/patternpage.cpp \ $$PWD/app/configpages/patternpage.cpp \
$$PWD/app/configpages/communitypage.cpp \ $$PWD/app/configpages/communitypage.cpp \
$$PWD/app/configpages/pathpage.cpp \ $$PWD/app/configpages/pathpage.cpp \
$$PWD/app/dialogundo.cpp \
$$PWD/tools/dialogcurveintersectaxis.cpp \
$$PWD/app/dialoglayoutsettings.cpp \ $$PWD/app/dialoglayoutsettings.cpp \
$$PWD/app/dialoglayoutprogress.cpp \ $$PWD/app/dialoglayoutprogress.cpp \
$$PWD/app/dialogsavelayout.cpp \ $$PWD/app/dialogsavelayout.cpp
$$PWD/tools/dialogpointofintersectionarcs.cpp \
$$PWD/tools/dialogpointofintersectioncircles.cpp \
$$PWD/tools/dialogpointfromcircleandtangent.cpp \
$$PWD/tools/dialogpointfromarcandtangent.cpp \
$$PWD/tools/dialogarcwithlength.cpp
FORMS += \ FORMS += \
$$PWD/tools/dialogtriangle.ui \
$$PWD/tools/dialogsplinepath.ui \
$$PWD/tools/dialogspline.ui \
$$PWD/tools/dialogsinglepoint.ui \
$$PWD/tools/dialogshoulderpoint.ui \
$$PWD/tools/dialogpointofintersection.ui \
$$PWD/tools/dialogpointofcontact.ui \
$$PWD/tools/dialognormal.ui \
$$PWD/tools/dialoglineintersect.ui \
$$PWD/tools/dialogline.ui \
$$PWD/tools/dialogheight.ui \
$$PWD/tools/dialogendline.ui \
$$PWD/tools/dialogdetail.ui \
$$PWD/tools/dialogbisector.ui \
$$PWD/tools/dialogarc.ui \
$$PWD/tools/dialogalongline.ui \
$$PWD/tools/dialogcutspline.ui \
$$PWD/tools/dialogcutsplinepath.ui \
$$PWD/tools/dialoguniondetails.ui \
$$PWD/tools/dialogcutarc.ui \
$$PWD/tools/dialogeditwrongformula.ui \
$$PWD/tools/dialoglineintersectaxis.ui \
$$PWD/app/dialogincrements.ui \ $$PWD/app/dialogincrements.ui \
$$PWD/app/dialoghistory.ui \ $$PWD/app/dialoghistory.ui \
$$PWD/app/dialogpatternproperties.ui \ $$PWD/app/dialogpatternproperties.ui \
@ -130,13 +48,6 @@ FORMS += \
$$PWD/app/dialogindividualmeasurements.ui \ $$PWD/app/dialogindividualmeasurements.ui \
$$PWD/app/dialogaboutapp.ui \ $$PWD/app/dialogaboutapp.ui \
$$PWD/app/dialogpatternxmledit.ui \ $$PWD/app/dialogpatternxmledit.ui \
$$PWD/app/dialogundo.ui \
$$PWD/tools/dialogcurveintersectaxis.ui \
$$PWD/app/dialoglayoutsettings.ui \ $$PWD/app/dialoglayoutsettings.ui \
$$PWD/app/dialoglayoutprogress.ui \ $$PWD/app/dialoglayoutprogress.ui \
$$PWD/app/dialogsavelayout.ui \ $$PWD/app/dialogsavelayout.ui
$$PWD/tools/dialogpointofintersectionarcs.ui \
$$PWD/tools/dialogpointofintersectioncircles.ui \
$$PWD/tools/dialogpointfromcircleandtangent.ui \
$$PWD/tools/dialogpointfromarcandtangent.ui \
$$PWD/tools/dialogarcwithlength.ui

View File

@ -31,6 +31,7 @@
#include "mainwindowsnogui.h" #include "mainwindowsnogui.h"
#include "../libs/vwidgets/vmaingraphicsview.h" #include "../libs/vwidgets/vmaingraphicsview.h"
#include "../libs/vtools/dialogs/tooldialogs.h"
#include "dialogs/dialogs.h" #include "dialogs/dialogs.h"
#include "tools/vtooldetail.h" #include "tools/vtooldetail.h"
#include "tools/vtooluniondetails.h" #include "tools/vtooluniondetails.h"

View File

@ -28,7 +28,3 @@
#include "options.h" #include "options.h"
#include <QString> #include <QString>
// From documantation: If you use QStringLiteral you should avoid declaring the same literal in multiple places: This
// furthermore blows up the binary sizes.
const QString degreeSymbol = QStringLiteral("°");

View File

@ -47,12 +47,6 @@
class QString; class QString;
class QStringList; class QStringList;
#define SceneSize 50000
#define DefPointRadius 1.5//mm
extern const QString degreeSymbol;
enum class Source : char { FromGui, FromFile, FromTool };
enum class Contour : char { OpenContour, CloseContour }; enum class Contour : char { OpenContour, CloseContour };
#endif // OPTIONS_H #endif // OPTIONS_H

View File

@ -27,23 +27,25 @@
*************************************************************************/ *************************************************************************/
#include "vpattern.h" #include "vpattern.h"
#include "../tools/vdatatool.h" #include "../../libs/vtools/tools/vdatatool.h"
#include "../tools/vtooldetail.h" #include "../../libs/vtools/tools/vtooldetail.h"
#include "../tools/vtooluniondetails.h" #include "../../libs/vtools/tools/vtooluniondetails.h"
#include "../tools/drawTools/drawtools.h" #include "../../libs/vtools/tools/drawTools/drawtools.h"
#include "../tools/nodeDetails/nodedetails.h" #include "../../libs/vtools/tools/nodeDetails/nodedetails.h"
#include "../libs/ifc/exception/vexceptionobjecterror.h" #include "../../libs/ifc/exception/vexceptionobjecterror.h"
#include "../libs/ifc/exception/vexceptionwrongid.h" #include "../../libs/ifc/exception/vexceptionwrongid.h"
#include "../libs/ifc/exception/vexceptionconversionerror.h" #include "../../libs/ifc/exception/vexceptionconversionerror.h"
#include "../libs/ifc/exception/vexceptionemptyparameter.h" #include "../../libs/ifc/exception/vexceptionemptyparameter.h"
#include "../libs/ifc/exception/vexceptionundo.h" #include "../../libs/ifc/exception/vexceptionundo.h"
#include "../libs/ifc/xml/vpatternconverter.h" #include "../../libs/ifc/xml/vpatternconverter.h"
#include "../libs/vmisc/undoevent.h" #include "../../libs/vmisc/undoevent.h"
#include "../libs/vmisc/vsettings.h" #include "../../libs/vmisc/vsettings.h"
#include "vstandardmeasurements.h" #include "vstandardmeasurements.h"
#include "vindividualmeasurements.h" #include "vindividualmeasurements.h"
#include "../../libs/qmuparser/qmuparsererror.h" #include "../../libs/qmuparser/qmuparsererror.h"
#include "../libs/vgeometry/varc.h" #include "../../libs/vgeometry/varc.h"
#include "../xml/vpattern.h"
#include "../core/vapplication.h"
#include <QMessageBox> #include <QMessageBox>
#include <QUndoStack> #include <QUndoStack>

View File

@ -36,9 +36,6 @@
class VDataTool; class VDataTool;
class VMainGraphicsScene; class VMainGraphicsScene;
enum class LabelType : char {NewPatternPiece, NewLabel};
enum class CrossCirclesPoint : char {FirstPoint = 1, SecondPoint = 2};
/** /**
* @brief The VPattern class working with pattern file. * @brief The VPattern class working with pattern file.
*/ */
@ -54,7 +51,7 @@ public:
void Parse(const Document &parse); void Parse(const Document &parse);
void setCurrentData(); void setCurrentData();
void UpdateToolData(const quint32 &id, VContainer *data); virtual void UpdateToolData(const quint32 &id, VContainer *data);
virtual void IncrementReferens(quint32 id) const; virtual void IncrementReferens(quint32 id) const;
virtual void DecrementReferens(quint32 id) const; virtual void DecrementReferens(quint32 id) const;
@ -68,7 +65,7 @@ public:
QString GetAuthor() const; QString GetAuthor() const;
void SetAuthor(const QString &text); void SetAuthor(const QString &text);
QString GenerateLabel(const LabelType &type)const; virtual QString GenerateLabel(const LabelType &type)const;
public slots: public slots:
void LiteParseTree(const Document &parse); void LiteParseTree(const Document &parse);

View File

@ -28,8 +28,6 @@
#include "ifcdef.h" #include "ifcdef.h"
const qreal PrintDPI = 96.0;
#define DefWidth 1.2//mm #define DefWidth 1.2//mm
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -59,112 +57,3 @@ qreal WidthHairLine(Unit patternUnit)
{ {
return WidthMainLine(patternUnit)/3.0; return WidthMainLine(patternUnit)/3.0;
} }
//---------------------------------------------------------------------------------------------------------------------
double ToPixel(double val, const Unit &unit)
{
switch (unit)
{
case Unit::Mm:
return (val / 25.4) * PrintDPI;
case Unit::Cm:
return ((val * 10.0) / 25.4) * PrintDPI;
case Unit::Inch:
return val * PrintDPI;
case Unit::Px:
return val;
default:
break;
}
return 0;
}
//---------------------------------------------------------------------------------------------------------------------
double FromPixel(double pix, const Unit &unit)
{
switch (unit)
{
case Unit::Mm:
return (pix / PrintDPI) * 25.4;
case Unit::Cm:
return ((pix / PrintDPI) * 25.4) / 10.0;
case Unit::Inch:
return pix / PrintDPI;
case Unit::Px:
return pix;
default:
break;
}
return 0;
}
//---------------------------------------------------------------------------------------------------------------------
qreal UnitConvertor(qreal value, const Unit &from, const Unit &to)
{
switch (from)
{
case Unit::Mm:
switch (to)
{
case Unit::Mm:
return value;
case Unit::Cm:
return value / 10.0;
case Unit::Inch:
return value / 25.4;
case Unit::Px:
return (value / 25.4) * PrintDPI;
default:
break;
}
break;
case Unit::Cm:
switch (to)
{
case Unit::Mm:
return value * 10.0;
case Unit::Cm:
return value;
case Unit::Inch:
return value / 2.54;
case Unit::Px:
return ((value * 10.0) / 25.4) * PrintDPI;
default:
break;
}
break;
case Unit::Inch:
switch (to)
{
case Unit::Mm:
return value * 25.4;
case Unit::Cm:
return value * 2.54;
case Unit::Inch:
return value;
case Unit::Px:
return value * PrintDPI;
default:
break;
}
break;
case Unit::Px:
switch (to)
{
case Unit::Mm:
return (value / PrintDPI) * 25.4;
case Unit::Cm:
return ((value / PrintDPI) * 25.4) / 10.0;
case Unit::Inch:
return value / PrintDPI;
case Unit::Px:
return value;
default:
break;
}
break;
default:
break;
}
return 0;
}

View File

@ -30,14 +30,13 @@
#define IFCDEF_H #define IFCDEF_H
#include <QtGlobal> #include <QtGlobal>
#include "../vmisc/def.h"
#ifdef Q_OS_WIN32 #ifdef Q_OS_WIN32
extern Q_CORE_EXPORT int qt_ntfs_permission_lookup; extern Q_CORE_EXPORT int qt_ntfs_permission_lookup;
#include <windows.h> #include <windows.h>
#endif /*Q_OS_WIN32*/ #endif /*Q_OS_WIN32*/
enum class Unit : char { Mm, Cm, Inch, Px };
static const quint32 null_id = 0; static const quint32 null_id = 0;
#define NULL_ID null_id//use this value for initialization variables that keeps id values. 0 mean uknown id value. #define NULL_ID null_id//use this value for initialization variables that keeps id values. 0 mean uknown id value.
@ -58,14 +57,7 @@ static const quint32 null_id = 0;
# define V_NOEXCEPT_EXPR(x) # define V_NOEXCEPT_EXPR(x)
# endif # endif
extern const qreal PrintDPI;
qreal WidthMainLine(Unit patternUnit); qreal WidthMainLine(Unit patternUnit);
qreal WidthHairLine(Unit patternUnit); qreal WidthHairLine(Unit patternUnit);
double ToPixel(double val, const Unit &unit);
double FromPixel(double pix, const Unit &unit);
qreal UnitConvertor(qreal value, const Unit &from, const Unit &to);
#endif // IFCDEF_H #endif // IFCDEF_H

View File

@ -35,8 +35,11 @@
#include <QObject> #include <QObject>
enum class Document : char { LiteParse, LitePPParse, FullParse }; enum class Document : char { LiteParse, LitePPParse, FullParse };
enum class CrossCirclesPoint : char {FirstPoint = 1, SecondPoint = 2};
enum class LabelType : char {NewPatternPiece, NewLabel};
class VDataTool; class VDataTool;
class VContainer;
class VAbstractPattern : public QObject, public VDomDocument class VAbstractPattern : public QObject, public VDomDocument
{ {
@ -64,6 +67,10 @@ public:
virtual void IncrementReferens(quint32 id) const=0; virtual void IncrementReferens(quint32 id) const=0;
virtual void DecrementReferens(quint32 id) const=0; virtual void DecrementReferens(quint32 id) const=0;
virtual QString GenerateLabel(const LabelType &type)const=0;
virtual void UpdateToolData(const quint32 &id, VContainer *data)=0;
QHash<quint32, VDataTool *> *getTools(); QHash<quint32, VDataTool *> *getTools();
VDataTool *getTool(const quint32 &id); VDataTool *getTool(const quint32 &id);
void AddTool(const quint32 &id, VDataTool *tool); void AddTool(const quint32 &id, VDataTool *tool);

View File

@ -33,7 +33,7 @@
#include <QDebug> #include <QDebug>
#include <QCoreApplication> #include <QCoreApplication>
#include "ifcdef.h" #include "../ifc/ifcdef.h"
#include "../vmisc/def.h" #include "../vmisc/def.h"
#include "../vmisc/logging.h" #include "../vmisc/logging.h"

View File

@ -8,6 +8,5 @@ SUBDIRS = \
vgeometry \ vgeometry \
vpatterndb \ vpatterndb \
vmisc \ vmisc \
vwidgets vwidgets \
vtools
vgeometry.depends = ifc

View File

@ -94,12 +94,3 @@ CONFIG(debug, debug|release){
} }
} }
} }
# IFC static library
unix|win32: LIBS += -L$$OUT_PWD/../ifc/$${DESTDIR}/ -lifc
INCLUDEPATH += $$PWD/../ifc
DEPENDPATH += $$PWD/../ifc
win32:!win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../ifc/$${DESTDIR}/ifc.lib
else:unix|win32-g++: PRE_TARGETDEPS += $$OUT_PWD/../ifc/$${DESTDIR}/libifc.a

View File

@ -222,6 +222,10 @@ const QString in_Oprt = QStringLiteral("in");
const QString cursorArrowOpenHand = QStringLiteral("://cursor/cursor-arrow-openhand.png"); const QString cursorArrowOpenHand = QStringLiteral("://cursor/cursor-arrow-openhand.png");
const QString cursorArrowCloseHand = QStringLiteral("://cursor/cursor-arrow-closehand.png"); const QString cursorArrowCloseHand = QStringLiteral("://cursor/cursor-arrow-closehand.png");
// From documantation: If you use QStringLiteral you should avoid declaring the same literal in multiple places: This
// furthermore blows up the binary sizes.
const QString degreeSymbol = QStringLiteral("°");
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
void SetOverrideCursor(const QString &pixmapPath, int hotX, int hotY) void SetOverrideCursor(const QString &pixmapPath, int hotX, int hotY)
{ {
@ -263,3 +267,123 @@ void RestoreOverrideCursor(const QString &pixmapPath)
} }
#endif #endif
} }
const qreal PrintDPI = 96.0;
//---------------------------------------------------------------------------------------------------------------------
double ToPixel(double val, const Unit &unit)
{
switch (unit)
{
case Unit::Mm:
return (val / 25.4) * PrintDPI;
case Unit::Cm:
return ((val * 10.0) / 25.4) * PrintDPI;
case Unit::Inch:
return val * PrintDPI;
case Unit::Px:
return val;
default:
break;
}
return 0;
}
//---------------------------------------------------------------------------------------------------------------------
double FromPixel(double pix, const Unit &unit)
{
switch (unit)
{
case Unit::Mm:
return (pix / PrintDPI) * 25.4;
case Unit::Cm:
return ((pix / PrintDPI) * 25.4) / 10.0;
case Unit::Inch:
return pix / PrintDPI;
case Unit::Px:
return pix;
default:
break;
}
return 0;
}
//---------------------------------------------------------------------------------------------------------------------
qreal UnitConvertor(qreal value, const Unit &from, const Unit &to)
{
switch (from)
{
case Unit::Mm:
switch (to)
{
case Unit::Mm:
return value;
case Unit::Cm:
return value / 10.0;
case Unit::Inch:
return value / 25.4;
case Unit::Px:
return (value / 25.4) * PrintDPI;
default:
break;
}
break;
case Unit::Cm:
switch (to)
{
case Unit::Mm:
return value * 10.0;
case Unit::Cm:
return value;
case Unit::Inch:
return value / 2.54;
case Unit::Px:
return ((value * 10.0) / 25.4) * PrintDPI;
default:
break;
}
break;
case Unit::Inch:
switch (to)
{
case Unit::Mm:
return value * 25.4;
case Unit::Cm:
return value * 2.54;
case Unit::Inch:
return value;
case Unit::Px:
return value * PrintDPI;
default:
break;
}
break;
case Unit::Px:
switch (to)
{
case Unit::Mm:
return (value / PrintDPI) * 25.4;
case Unit::Cm:
return ((value / PrintDPI) * 25.4) / 10.0;
case Unit::Inch:
return value / PrintDPI;
case Unit::Px:
return value;
default:
break;
}
break;
default:
break;
}
return 0;
}
//---------------------------------------------------------------------------------------------------------------------
void CheckFactor(qreal &oldFactor, const qreal &Newfactor)
{
if (Newfactor <= 2 && Newfactor >= 0.5)
{
oldFactor = Newfactor;
}
}

View File

@ -33,9 +33,14 @@
#include <QtGlobal> #include <QtGlobal>
#include <QStringList> #include <QStringList>
#define SceneSize 50000
#define DefPointRadius 1.5//mm
enum class NodeDetail : char { Contour, Modeling }; enum class NodeDetail : char { Contour, Modeling };
enum class SceneObject : char { Point, Line, Spline, Arc, SplinePath, Detail, Unknown }; enum class SceneObject : char { Point, Line, Spline, Arc, SplinePath, Detail, Unknown };
enum class MeasurementsType : char { Standard, Individual }; enum class MeasurementsType : char { Standard, Individual };
enum class Unit : char { Mm, Cm, Inch, Px };
enum class Source : char { FromGui, FromFile, FromTool };
enum class Tool : unsigned char enum class Tool : unsigned char
{ {
@ -372,7 +377,18 @@ extern const QString in_Oprt;
extern const QString cursorArrowOpenHand; extern const QString cursorArrowOpenHand;
extern const QString cursorArrowCloseHand; extern const QString cursorArrowCloseHand;
extern const QString degreeSymbol;
void SetOverrideCursor(const QString & pixmapPath, int hotX = -1, int hotY = -1); void SetOverrideCursor(const QString & pixmapPath, int hotX = -1, int hotY = -1);
void RestoreOverrideCursor(const QString & pixmapPath); void RestoreOverrideCursor(const QString & pixmapPath);
extern const qreal PrintDPI;
double ToPixel(double val, const Unit &unit);
double FromPixel(double pix, const Unit &unit);
qreal UnitConvertor(qreal value, const Unit &from, const Unit &to);
void CheckFactor(qreal &oldFactor, const qreal &Newfactor);
#endif // DEF_H #endif // DEF_H

View File

@ -27,16 +27,44 @@
*************************************************************************/ *************************************************************************/
#include "vabstractapplication.h" #include "vabstractapplication.h"
#include "../vmisc/def.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
VAbstractApplication::VAbstractApplication(int &argc, char **argv) VAbstractApplication::VAbstractApplication(int &argc, char **argv)
:QApplication(argc, argv), _patternType(MeasurementsType::Individual), settings(nullptr) :QApplication(argc, argv),
undoStack(nullptr),
mainWindow(nullptr),
_patternUnit(Unit::Cm),
_patternType(MeasurementsType::Individual),
settings(nullptr),
currentScene(nullptr),
sceneView(nullptr),
doc(nullptr),
openingPattern(false)
{} {}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
VAbstractApplication::~VAbstractApplication() VAbstractApplication::~VAbstractApplication()
{} {}
//---------------------------------------------------------------------------------------------------------------------
Unit VAbstractApplication::patternUnit() const
{
return _patternUnit;
}
//---------------------------------------------------------------------------------------------------------------------
const Unit *VAbstractApplication::patternUnitP() const
{
return &_patternUnit;
}
//---------------------------------------------------------------------------------------------------------------------
void VAbstractApplication::setPatternUnit(const Unit &patternUnit)
{
_patternUnit = patternUnit;
}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**
* @brief OpenSettings get acsses to application settings. * @brief OpenSettings get acsses to application settings.
@ -59,3 +87,41 @@ VSettings *VAbstractApplication::Settings()
SCASSERT(settings != nullptr); SCASSERT(settings != nullptr);
return settings; return settings;
} }
//---------------------------------------------------------------------------------------------------------------------
QGraphicsScene *VAbstractApplication::getCurrentScene() const
{
SCASSERT(currentScene != nullptr);
return currentScene;
}
//---------------------------------------------------------------------------------------------------------------------
void VAbstractApplication::setCurrentScene(QGraphicsScene *value)
{
currentScene = value;
}
//---------------------------------------------------------------------------------------------------------------------
VMainGraphicsView *VAbstractApplication::getSceneView() const
{
return sceneView;
}
//---------------------------------------------------------------------------------------------------------------------
void VAbstractApplication::setSceneView(VMainGraphicsView *value)
{
sceneView = value;
}
//---------------------------------------------------------------------------------------------------------------------
double VAbstractApplication::toPixel(double val) const
{
return ToPixel(val, _patternUnit);
}
//---------------------------------------------------------------------------------------------------------------------
double VAbstractApplication::fromPixel(double pix) const
{
return FromPixel(pix, _patternUnit);
}

View File

@ -30,11 +30,15 @@
#define VABSTRACTAPPLICATION_H #define VABSTRACTAPPLICATION_H
#include <QApplication> #include <QApplication>
#include <QGraphicsScene>
#include "def.h" #include "def.h"
#include "vsettings.h" #include "vsettings.h"
class VAbstractApplication;// use in define class VAbstractApplication;// use in define
class VTranslateVars; class VTranslateVars;
class VAbstractPattern;
class VMainGraphicsView;
class QUndoStack;
#if defined(qApp) #if defined(qApp)
#undef qApp #undef qApp
@ -49,23 +53,67 @@ public:
virtual const VTranslateVars *TrVars()=0; virtual const VTranslateVars *TrVars()=0;
Unit patternUnit() const;
const Unit *patternUnitP() const;
void setPatternUnit(const Unit &patternUnit);
MeasurementsType patternType() const; MeasurementsType patternType() const;
void setPatternType(const MeasurementsType &patternType); void setPatternType(const MeasurementsType &patternType);
void OpenSettings(); void OpenSettings();
VSettings *Settings(); VSettings *Settings();
template <typename T> template <typename T>
QString LocaleToString(const T &value); QString LocaleToString(const T &value);
QGraphicsScene *getCurrentScene() const;
void setCurrentScene(QGraphicsScene *value);
VMainGraphicsView *getSceneView() const;
void setSceneView(VMainGraphicsView *value);
double toPixel(double val) const;
double fromPixel(double pix) const;
void setCurrentDocument(VAbstractPattern *doc);
VAbstractPattern *getCurrentDocument()const;
bool getOpeningPattern() const;
void setOpeningPattern();
QWidget *getMainWindow() const;
void setMainWindow(QWidget *value);
QUndoStack *getUndoStack() const;
protected:
QUndoStack *undoStack;
/**
* @brief mainWindow pointer to main window. Usefull if need create modal dialog. Without pointer to main window
* modality doesn't work.
*/
QWidget *mainWindow;
private: private:
Q_DISABLE_COPY(VAbstractApplication) Q_DISABLE_COPY(VAbstractApplication)
Unit _patternUnit;
MeasurementsType _patternType; MeasurementsType _patternType;
/** /**
* @brief settings pointer to settings. Help hide constructor creation settings. Make make code more readable. * @brief settings pointer to settings. Help hide constructor creation settings. Make make code more readable.
*/ */
VSettings *settings; VSettings *settings;
QGraphicsScene *currentScene;
VMainGraphicsView *sceneView;
VAbstractPattern *doc;
/**
* @brief openingPattern true when we opening pattern. If something will be wrong in formula this help understand if
* we can allow user use Undo option.
*/
bool openingPattern;
}; };
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
@ -89,4 +137,48 @@ QString VAbstractApplication::LocaleToString(const T &value)
return loc.toString(value); return loc.toString(value);
} }
//---------------------------------------------------------------------------------------------------------------------
inline void VAbstractApplication::setCurrentDocument(VAbstractPattern *doc)
{
this->doc = doc;
}
//---------------------------------------------------------------------------------------------------------------------
inline VAbstractPattern *VAbstractApplication::getCurrentDocument() const
{
SCASSERT(doc != nullptr)
return doc;
}
//---------------------------------------------------------------------------------------------------------------------
inline bool VAbstractApplication::getOpeningPattern() const
{
return openingPattern;
}
//---------------------------------------------------------------------------------------------------------------------
inline void VAbstractApplication::setOpeningPattern()
{
openingPattern = !openingPattern;
}
//---------------------------------------------------------------------------------------------------------------------
inline QWidget *VAbstractApplication::getMainWindow() const
{
return mainWindow;
}
//---------------------------------------------------------------------------------------------------------------------
inline void VAbstractApplication::setMainWindow(QWidget *value)
{
SCASSERT(value != nullptr)
mainWindow = value;
}
//---------------------------------------------------------------------------------------------------------------------
inline QUndoStack *VAbstractApplication::getUndoStack() const
{
return undoStack;
}
#endif // VABSTRACTAPPLICATION_H #endif // VABSTRACTAPPLICATION_H

View File

@ -454,9 +454,9 @@ const QMap<QString, QSharedPointer<VArcAngle> > VContainer::DataAnglesArcs() con
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
const QMap<QString, QSharedPointer<VCurveAngle> > VContainer::DataAnglesCurves() const const QMap<QString, QSharedPointer<VSplineAngle> > VContainer::DataAnglesCurves() const
{ {
return DataVar<VCurveAngle>(VarType::SplineAngle); return DataVar<VSplineAngle>(VarType::SplineAngle);
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View File

@ -156,7 +156,7 @@ public:
const QMap<QString, QSharedPointer<VLineAngle> > DataAngleLines() const; const QMap<QString, QSharedPointer<VLineAngle> > DataAngleLines() const;
const QMap<QString, QSharedPointer<VArcRadius> > DataRadiusesArcs() const; const QMap<QString, QSharedPointer<VArcRadius> > DataRadiusesArcs() const;
const QMap<QString, QSharedPointer<VArcAngle> > DataAnglesArcs() const; const QMap<QString, QSharedPointer<VArcAngle> > DataAnglesArcs() const;
const QMap<QString, QSharedPointer<VCurveAngle> > DataAnglesCurves() const; const QMap<QString, QSharedPointer<VSplineAngle> > DataAnglesCurves() const;
static bool IsUnique(const QString &name); static bool IsUnique(const QString &name);

View File

@ -0,0 +1,98 @@
# ADD TO EACH PATH $$PWD VARIABLE!!!!!!
# This need for corect working file translations.pro
HEADERS += \
$$PWD/tooldialogs.h \
$$PWD/tools/dialogalongline.h \
$$PWD/tools/dialogarc.h \
$$PWD/tools/dialogarcwithlength.h \
$$PWD/tools/dialogbisector.h \
$$PWD/tools/dialogcurveintersectaxis.h \
$$PWD/tools/dialogcutarc.h \
$$PWD/tools/dialogcutspline.h \
$$PWD/tools/dialogcutsplinepath.h \
$$PWD/tools/dialogdetail.h \
$$PWD/tools/dialogendline.h \
$$PWD/tools/dialogheight.h \
$$PWD/tools/dialogline.h \
$$PWD/tools/dialoglineintersect.h \
$$PWD/tools/dialoglineintersectaxis.h \
$$PWD/tools/dialognormal.h \
$$PWD/tools/dialogpointfromarcandtangent.h \
$$PWD/tools/dialogpointfromcircleandtangent.h \
$$PWD/tools/dialogpointofcontact.h \
$$PWD/tools/dialogpointofintersection.h \
$$PWD/tools/dialogpointofintersectionarcs.h \
$$PWD/tools/dialogpointofintersectioncircles.h \
$$PWD/tools/dialogshoulderpoint.h \
$$PWD/tools/dialogsinglepoint.h \
$$PWD/tools/dialogspline.h \
$$PWD/tools/dialogsplinepath.h \
$$PWD/tools/dialogtool.h \
$$PWD/tools/dialogtriangle.h \
$$PWD/tools/dialoguniondetails.h \
$$PWD/support/dialogeditwrongformula.h \
$$PWD/support/dialogundo.h
SOURCES += \
$$PWD/tools/dialogalongline.cpp \
$$PWD/tools/dialogarc.cpp \
$$PWD/tools/dialogarcwithlength.cpp \
$$PWD/tools/dialogbisector.cpp \
$$PWD/tools/dialogcurveintersectaxis.cpp \
$$PWD/tools/dialogcutarc.cpp \
$$PWD/tools/dialogcutspline.cpp \
$$PWD/tools/dialogcutsplinepath.cpp \
$$PWD/tools/dialogdetail.cpp \
$$PWD/tools/dialogendline.cpp \
$$PWD/tools/dialogheight.cpp \
$$PWD/tools/dialogline.cpp \
$$PWD/tools/dialoglineintersect.cpp \
$$PWD/tools/dialoglineintersectaxis.cpp \
$$PWD/tools/dialognormal.cpp \
$$PWD/tools/dialogpointfromarcandtangent.cpp \
$$PWD/tools/dialogpointfromcircleandtangent.cpp \
$$PWD/tools/dialogpointofcontact.cpp \
$$PWD/tools/dialogpointofintersection.cpp \
$$PWD/tools/dialogpointofintersectionarcs.cpp \
$$PWD/tools/dialogpointofintersectioncircles.cpp \
$$PWD/tools/dialogshoulderpoint.cpp \
$$PWD/tools/dialogsinglepoint.cpp \
$$PWD/tools/dialogspline.cpp \
$$PWD/tools/dialogsplinepath.cpp \
$$PWD/tools/dialogtool.cpp \
$$PWD/tools/dialogtriangle.cpp \
$$PWD/tools/dialoguniondetails.cpp \
$$PWD/support/dialogeditwrongformula.cpp \
$$PWD/support/dialogundo.cpp
FORMS += \
$$PWD/tools/dialogalongline.ui \
$$PWD/tools/dialogarc.ui \
$$PWD/tools/dialogarcwithlength.ui \
$$PWD/tools/dialogbisector.ui \
$$PWD/tools/dialogcurveintersectaxis.ui \
$$PWD/tools/dialogcutarc.ui \
$$PWD/tools/dialogcutspline.ui \
$$PWD/tools/dialogcutsplinepath.ui \
$$PWD/tools/dialogdetail.ui \
$$PWD/tools/dialogendline.ui \
$$PWD/tools/dialogheight.ui \
$$PWD/tools/dialogline.ui \
$$PWD/tools/dialoglineintersect.ui \
$$PWD/tools/dialoglineintersectaxis.ui \
$$PWD/tools/dialognormal.ui \
$$PWD/tools/dialogpointfromarcandtangent.ui \
$$PWD/tools/dialogpointfromcircleandtangent.ui \
$$PWD/tools/dialogpointofcontact.ui \
$$PWD/tools/dialogpointofintersection.ui \
$$PWD/tools/dialogpointofintersectionarcs.ui \
$$PWD/tools/dialogpointofintersectioncircles.ui \
$$PWD/tools/dialogshoulderpoint.ui \
$$PWD/tools/dialogsinglepoint.ui \
$$PWD/tools/dialogspline.ui \
$$PWD/tools/dialogsplinepath.ui \
$$PWD/tools/dialogtriangle.ui \
$$PWD/tools/dialoguniondetails.ui \
$$PWD/support/dialogeditwrongformula.ui \
$$PWD/support/dialogundo.ui

View File

@ -28,7 +28,8 @@
#include "dialogeditwrongformula.h" #include "dialogeditwrongformula.h"
#include "ui_dialogeditwrongformula.h" #include "ui_dialogeditwrongformula.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
DialogEditWrongFormula::DialogEditWrongFormula(const VContainer *data, const quint32 &toolId, QWidget *parent) DialogEditWrongFormula::DialogEditWrongFormula(const VContainer *data, const quint32 &toolId, QWidget *parent)
@ -203,8 +204,8 @@ void DialogEditWrongFormula::ValChenged(int row)
if (ui->radioButtonAnglesCurves->isChecked()) if (ui->radioButtonAnglesCurves->isChecked())
{ {
const QString desc = QString("%1(%2) - %3").arg(item->text()) const QString desc = QString("%1(%2) - %3").arg(item->text())
.arg(*data->GetVariable<VCurveAngle>(qApp->TrVars()->VarFromUser(item->text()))->GetValue()) .arg(*data->GetVariable<VSplineAngle>(qApp->TrVars()->VarFromUser(item->text()))->GetValue())
.arg(tr("Curve angle")); .arg(tr("Curve angle"));
ui->labelDescription->setText(desc); ui->labelDescription->setText(desc);
return; return;
} }

View File

@ -29,7 +29,7 @@
#ifndef DIALOGEDITWRONGFORMULA_H #ifndef DIALOGEDITWRONGFORMULA_H
#define DIALOGEDITWRONGFORMULA_H #define DIALOGEDITWRONGFORMULA_H
#include "dialogtool.h" #include "../tools/dialogtool.h"
namespace Ui namespace Ui
{ {

View File

@ -28,8 +28,8 @@
#include "dialogundo.h" #include "dialogundo.h"
#include "ui_dialogundo.h" #include "ui_dialogundo.h"
#include "../../core/vapplication.h" #include "../../../ifc/exception/vexceptionundo.h"
#include "../../libs/ifc/exception/vexceptionundo.h" #include "../../../vmisc/vabstractapplication.h"
#include <QCloseEvent> #include <QCloseEvent>
#include <QUndoStack> #include <QUndoStack>

View File

@ -0,0 +1,63 @@
/************************************************************************
**
** @file dialogs.h
** @author Roman Telezhynskyi <dismine(at)gmail.com>
** @date 16 6, 2015
**
** @brief
** @copyright
** This source code is part of the Valentine project, a pattern making
** program, whose allow create and modeling patterns of clothing.
** Copyright (C) 2015 Valentina project
** <https://bitbucket.org/dismine/valentina> All Rights Reserved.
**
** Valentina is free software: you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
** the Free Software Foundation, either version 3 of the License, or
** (at your option) any later version.
**
** Valentina is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with Valentina. If not, see <http://www.gnu.org/licenses/>.
**
*************************************************************************/
#ifndef TOOLDIALOGS_H
#define TOOLDIALOGS_H
#include "dialogs/tools/dialogalongline.h"
#include "dialogs/tools/dialogarc.h"
#include "dialogs/tools/dialogarcwithlength.h"
#include "dialogs/tools/dialogbisector.h"
#include "dialogs/tools/dialogdetail.h"
#include "dialogs/tools/dialogendline.h"
#include "dialogs/tools/dialogline.h"
#include "dialogs/tools/dialoglineintersect.h"
#include "dialogs/tools/dialognormal.h"
#include "dialogs/tools/dialogpointofcontact.h"
#include "dialogs/tools/dialogshoulderpoint.h"
#include "dialogs/tools/dialogsinglepoint.h"
#include "dialogs/tools/dialogspline.h"
#include "dialogs/tools/dialogsplinepath.h"
#include "dialogs/tools/dialogheight.h"
#include "dialogs/tools/dialogcutarc.h"
#include "dialogs/tools/dialogcutspline.h"
#include "dialogs/tools/dialogcutsplinepath.h"
#include "dialogs/tools/dialoguniondetails.h"
#include "dialogs/tools/dialogtriangle.h"
#include "dialogs/tools/dialogpointofintersection.h"
#include "dialogs/tools/dialoglineintersectaxis.h"
#include "dialogs/tools/dialogcurveintersectaxis.h"
#include "dialogs/tools/dialogpointofintersectionarcs.h"
#include "dialogs/tools/dialogpointofintersectioncircles.h"
#include "dialogs/tools/dialogpointfromcircleandtangent.h"
#include "dialogs/tools/dialogpointfromarcandtangent.h"
#include "dialogs/support/dialogeditwrongformula.h"
#include "dialogs/support/dialogundo.h"
#endif // TOOLDIALOGS_H

View File

@ -30,8 +30,9 @@
#include "ui_dialogalongline.h" #include "ui_dialogalongline.h"
#include "../../visualization/vistoolalongline.h" #include "../../visualization/vistoolalongline.h"
#include "../../tools/vabstracttool.h" #include "../../tools/vabstracttool.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "dialogeditwrongformula.h" #include "../../../vpatterndb/vtranslatevars.h"
#include "../support/dialogeditwrongformula.h"
#include <QPushButton> #include <QPushButton>

View File

@ -32,11 +32,12 @@
#include <QPushButton> #include <QPushButton>
#include <QTimer> #include <QTimer>
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../libs/ifc/xml/vdomdocument.h" #include "../../../vpatterndb/vtranslatevars.h"
#include "../../../ifc/xml/vdomdocument.h"
#include "../../visualization/vistoolarc.h" #include "../../visualization/vistoolarc.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -32,11 +32,12 @@
#include <QPushButton> #include <QPushButton>
#include <QTimer> #include <QTimer>
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../libs/ifc/xml/vdomdocument.h" #include "../../../vpatterndb/vtranslatevars.h"
#include "../../../ifc/xml/vdomdocument.h"
#include "../../visualization/vistoolarcwithlength.h" #include "../../visualization/vistoolarcwithlength.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
DialogArcWithLength::DialogArcWithLength(const VContainer *data, const quint32 &toolId, QWidget *parent) DialogArcWithLength::DialogArcWithLength(const VContainer *data, const quint32 &toolId, QWidget *parent)

View File

@ -29,12 +29,13 @@
#include "dialogbisector.h" #include "dialogbisector.h"
#include "ui_dialogbisector.h" #include "ui_dialogbisector.h"
#include "../../libs/vgeometry/vpointf.h" #include "../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../vpatterndb/vcontainer.h"
#include "../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolbisector.h" #include "../../visualization/vistoolbisector.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../vwidgets/vmaingraphicsscene.h"
#include "../../tools/vabstracttool.h" #include "../../tools/vabstracttool.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -29,12 +29,13 @@
#include "dialogcurveintersectaxis.h" #include "dialogcurveintersectaxis.h"
#include "ui_dialogcurveintersectaxis.h" #include "ui_dialogcurveintersectaxis.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolcurveintersectaxis.h" #include "../../visualization/vistoolcurveintersectaxis.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../tools/vabstracttool.h" #include "../../tools/vabstracttool.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
#include <QTimer> #include <QTimer>

View File

@ -29,12 +29,12 @@
#include "dialogcutarc.h" #include "dialogcutarc.h"
#include "ui_dialogcutarc.h" #include "ui_dialogcutarc.h"
#include "../../libs/vgeometry/varc.h" #include "../../../vgeometry/varc.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolcutarc.h" #include "../../visualization/vistoolcutarc.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../xml/vpattern.h" #include "../support/dialogeditwrongformula.h"
#include "dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -29,11 +29,11 @@
#include "dialogcutspline.h" #include "dialogcutspline.h"
#include "ui_dialogcutspline.h" #include "ui_dialogcutspline.h"
#include "../../libs/vgeometry/vspline.h" #include "../../../vgeometry/vspline.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../xml/vpattern.h" #include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolcutspline.h" #include "../../visualization/vistoolcutspline.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -29,11 +29,11 @@
#include "dialogcutsplinepath.h" #include "dialogcutsplinepath.h"
#include "ui_dialogcutsplinepath.h" #include "ui_dialogcutsplinepath.h"
#include "../../libs/vgeometry/vsplinepath.h" #include "../../../vgeometry/vsplinepath.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../xml/vpattern.h" #include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolcutsplinepath.h" #include "../../visualization/vistoolcutsplinepath.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -30,12 +30,11 @@
#include <QDebug> #include <QDebug>
#include "../../libs/vgeometry/varc.h" #include "../../../vgeometry/varc.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vgeometry/vsplinepath.h" #include "../../../vgeometry/vsplinepath.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../libs/ifc/xml/vdomdocument.h" #include "../../../ifc/xml/vdomdocument.h"
#include "../../xml/vabstractmeasurements.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -29,12 +29,13 @@
#include "dialogendline.h" #include "dialogendline.h"
#include "ui_dialogendline.h" #include "ui_dialogendline.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolendline.h" #include "../../visualization/vistoolendline.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../tools/vabstracttool.h" #include "../../tools/vabstracttool.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
#include <QTimer> #include <QTimer>
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View File

@ -29,11 +29,10 @@
#include "dialogline.h" #include "dialogline.h"
#include "ui_dialogline.h" #include "ui_dialogline.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../visualization/vistoolline.h" #include "../../visualization/vistoolline.h"
#include "../../core/vapplication.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h"
#include "../../tools/vabstracttool.h" #include "../../tools/vabstracttool.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View File

@ -33,7 +33,6 @@
#include "../../libs/vpatterndb/vcontainer.h" #include "../../libs/vpatterndb/vcontainer.h"
#include "../../visualization/vistoollineintersect.h" #include "../../visualization/vistoollineintersect.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../libs/vwidgets/vmaingraphicsscene.h"
#include "../../xml/vpattern.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -29,12 +29,13 @@
#include "dialoglineintersectaxis.h" #include "dialoglineintersectaxis.h"
#include "ui_dialoglineintersectaxis.h" #include "ui_dialoglineintersectaxis.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoollineintersectaxis.h" #include "../../visualization/vistoollineintersectaxis.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../tools/vabstracttool.h" #include "../../tools/vabstracttool.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
#include <QTimer> #include <QTimer>

View File

@ -29,9 +29,10 @@
#include "dialognormal.h" #include "dialognormal.h"
#include "ui_dialognormal.h" #include "ui_dialognormal.h"
#include "../../visualization/vistoolnormal.h" #include "../../visualization/vistoolnormal.h"
#include "../../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../tools/vabstracttool.h" #include "../../tools/vabstracttool.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
#include "../../../vpatterndb/vtranslatevars.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -29,11 +29,12 @@
#include "dialogpointfromcircleandtangent.h" #include "dialogpointfromcircleandtangent.h"
#include "ui_dialogpointfromcircleandtangent.h" #include "ui_dialogpointfromcircleandtangent.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolpointfromcircleandtangent.h" #include "../../visualization/vistoolpointfromcircleandtangent.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
DialogPointFromCircleAndTangent::DialogPointFromCircleAndTangent(const VContainer *data, const quint32 &toolId, DialogPointFromCircleAndTangent::DialogPointFromCircleAndTangent(const VContainer *data, const quint32 &toolId,

View File

@ -28,12 +28,12 @@
#include "dialogpointofcontact.h" #include "dialogpointofcontact.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolpointofcontact.h" #include "../../visualization/vistoolpointofcontact.h"
#include "../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../xml/vpattern.h" #include "../support/dialogeditwrongformula.h"
#include "dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -29,11 +29,10 @@
#include "dialogpointofintersection.h" #include "dialogpointofintersection.h"
#include "ui_dialogpointofintersection.h" #include "ui_dialogpointofintersection.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../visualization/vistoolpointofintersection.h" #include "../../visualization/vistoolpointofintersection.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "../../xml/vpattern.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**

View File

@ -30,7 +30,6 @@
#define DIALOGPOINTOFINTERSECTIONARCS_H #define DIALOGPOINTOFINTERSECTIONARCS_H
#include "dialogtool.h" #include "dialogtool.h"
#include "../../xml/vpattern.h"
namespace Ui namespace Ui
{ {

View File

@ -29,11 +29,12 @@
#include "dialogpointofintersectioncircles.h" #include "dialogpointofintersectioncircles.h"
#include "ui_dialogpointofintersectioncircles.h" #include "ui_dialogpointofintersectioncircles.h"
#include "../../libs/vgeometry/vpointf.h" #include "../../../vgeometry/vpointf.h"
#include "../../libs/vpatterndb/vcontainer.h" #include "../../../vpatterndb/vcontainer.h"
#include "../../../vpatterndb/vtranslatevars.h"
#include "../../visualization/vistoolpointofintersectioncircles.h" #include "../../visualization/vistoolpointofintersectioncircles.h"
#include "../../libs/vwidgets/vmaingraphicsscene.h" #include "../../../vwidgets/vmaingraphicsscene.h"
#include "dialogeditwrongformula.h" #include "../support/dialogeditwrongformula.h"
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
DialogPointOfIntersectionCircles::DialogPointOfIntersectionCircles(const VContainer *data, const quint32 &toolId, DialogPointOfIntersectionCircles::DialogPointOfIntersectionCircles(const VContainer *data, const quint32 &toolId,

View File

@ -30,7 +30,6 @@
#define DIALOGPOINTOFINTERSECTIONCIRCLES_H #define DIALOGPOINTOFINTERSECTIONCIRCLES_H
#include "dialogtool.h" #include "dialogtool.h"
#include "../../xml/vpattern.h"
namespace Ui namespace Ui
{ {

Some files were not shown because too many files have changed in this diff Show More