2013-11-15 13:41:26 +01:00
|
|
|
|
/************************************************************************
|
2013-09-23 14:08:06 +02:00
|
|
|
|
**
|
2013-11-15 13:50:05 +01:00
|
|
|
|
** @file vapplication.cpp
|
2014-04-30 07:38:52 +02:00
|
|
|
|
** @author Roman Telezhynskyi <dismine(at)gmail.com>
|
2013-11-15 13:50:05 +01:00
|
|
|
|
** @date November 15, 2013
|
2013-09-23 14:08:06 +02:00
|
|
|
|
**
|
2013-11-15 13:41:26 +01:00
|
|
|
|
** @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) 2013 Valentina project
|
|
|
|
|
** <https://bitbucket.org/dismine/valentina> All Rights Reserved.
|
2013-09-23 14:08:06 +02:00
|
|
|
|
**
|
2013-11-15 13:41:26 +01:00
|
|
|
|
** Valentina is free software: you can redistribute it and/or modify
|
2013-09-23 14:08:06 +02:00
|
|
|
|
** 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.
|
|
|
|
|
**
|
2013-10-27 13:36:29 +01:00
|
|
|
|
** Valentina is distributed in the hope that it will be useful,
|
2013-09-23 14:08:06 +02:00
|
|
|
|
** 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/>.
|
|
|
|
|
**
|
2013-11-15 13:41:26 +01:00
|
|
|
|
*************************************************************************/
|
2013-09-23 14:08:06 +02:00
|
|
|
|
|
|
|
|
|
#include "vapplication.h"
|
2013-11-06 18:06:00 +01:00
|
|
|
|
#include "../exception/vexceptionobjecterror.h"
|
|
|
|
|
#include "../exception/vexceptionbadid.h"
|
|
|
|
|
#include "../exception/vexceptionconversionerror.h"
|
|
|
|
|
#include "../exception/vexceptionemptyparameter.h"
|
2014-03-03 18:32:38 +01:00
|
|
|
|
#include "../exception/vexceptionwrongid.h"
|
2014-06-08 20:10:57 +02:00
|
|
|
|
#include "vmaingraphicsview.h"
|
|
|
|
|
#include "../container/calculator.h"
|
2013-09-23 14:08:06 +02:00
|
|
|
|
|
2013-11-21 13:05:26 +01:00
|
|
|
|
#include <QDebug>
|
2014-05-12 11:35:33 +02:00
|
|
|
|
#include <QDir>
|
2014-07-04 16:52:11 +02:00
|
|
|
|
#include <QProcess>
|
2014-06-08 20:10:57 +02:00
|
|
|
|
#include <QUndoStack>
|
2013-11-21 13:05:26 +01:00
|
|
|
|
|
2014-06-17 11:50:11 +02:00
|
|
|
|
#include <QtMath>
|
2014-05-23 20:11:13 +02:00
|
|
|
|
|
2014-03-19 19:27:11 +01:00
|
|
|
|
const qreal VApplication::PrintDPI = 96.0;
|
|
|
|
|
|
2014-03-26 05:39:07 +01:00
|
|
|
|
#define DefWidth 1.2//mm
|
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-06-13 19:02:41 +02:00
|
|
|
|
/**
|
|
|
|
|
* @brief VApplication constructor.
|
|
|
|
|
* @param argc number arguments.
|
|
|
|
|
* @param argv command line.
|
|
|
|
|
*/
|
2014-03-19 19:27:11 +01:00
|
|
|
|
VApplication::VApplication(int &argc, char **argv)
|
2014-06-12 09:22:29 +02:00
|
|
|
|
: QApplication(argc, argv), _patternUnit(Unit::Cm), _patternType(MeasurementsType::Individual),
|
2014-05-13 10:08:37 +02:00
|
|
|
|
_widthMainLine(DefWidth), _widthHairLine(DefWidth/3.0), measurements(QMap<QString, VTranslation>()),
|
2014-05-16 12:00:33 +02:00
|
|
|
|
guiTexts(QMap<QString, VTranslation>()), descriptions(QMap<QString, VTranslation>()),
|
2014-05-23 09:14:21 +02:00
|
|
|
|
variables(QMap<QString, VTranslation>()), functions(QMap<QString, VTranslation>()),
|
2014-09-18 11:30:33 +02:00
|
|
|
|
postfixOperators(QMap<QString, VTranslation>()), stDescriptions(QMap<QString, VTranslation>()),
|
|
|
|
|
undoStack(nullptr), sceneView(nullptr), currentScene(nullptr),
|
2014-09-05 10:01:46 +02:00
|
|
|
|
autoSaveTimer(nullptr), mainWindow(nullptr), openingPattern(false), settings(nullptr), doc(nullptr)
|
2014-03-19 19:27:11 +01:00
|
|
|
|
{
|
2014-06-04 13:30:45 +02:00
|
|
|
|
undoStack = new QUndoStack(this);
|
|
|
|
|
|
2014-03-26 05:39:07 +01:00
|
|
|
|
InitLineWidth();
|
2014-05-13 10:08:37 +02:00
|
|
|
|
InitMeasurements();
|
|
|
|
|
InitVariables();
|
|
|
|
|
InitFunctions();
|
2014-05-23 09:14:21 +02:00
|
|
|
|
InitPostfixOperators();
|
2014-09-18 11:30:33 +02:00
|
|
|
|
InitSTDescriptions();
|
2014-03-19 19:27:11 +01:00
|
|
|
|
}
|
|
|
|
|
|
2014-07-04 16:52:11 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
/**
|
|
|
|
|
* @brief NewValentina start Valentina in new process, send path to pattern file in argument.
|
|
|
|
|
* @param fileName path to pattern file.
|
|
|
|
|
*/
|
|
|
|
|
void VApplication::NewValentina(const QString &fileName)
|
|
|
|
|
{
|
|
|
|
|
QProcess *v = new QProcess();
|
|
|
|
|
QStringList arguments;
|
|
|
|
|
arguments << fileName;
|
|
|
|
|
v->startDetached(QCoreApplication::applicationFilePath(), arguments);
|
|
|
|
|
delete v;
|
|
|
|
|
}
|
|
|
|
|
|
2014-07-15 15:51:15 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::CheckFactor(qreal &oldFactor, const qreal &Newfactor)
|
|
|
|
|
{
|
|
|
|
|
if (Newfactor <= 2 && Newfactor >= 0.5)
|
|
|
|
|
{
|
|
|
|
|
oldFactor = Newfactor;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-06-13 19:02:41 +02:00
|
|
|
|
/**
|
|
|
|
|
* @brief notify Reimplemented from QApplication::notify().
|
|
|
|
|
* @param receiver receiver.
|
|
|
|
|
* @param event event.
|
|
|
|
|
* @return value that is returned from the receiver's event handler.
|
|
|
|
|
*/
|
2014-03-26 05:39:07 +01:00
|
|
|
|
// reimplemented from QApplication so we can throw exceptions in slots
|
2013-11-04 21:35:15 +01:00
|
|
|
|
bool VApplication::notify(QObject *receiver, QEvent *event)
|
|
|
|
|
{
|
|
|
|
|
try
|
|
|
|
|
{
|
2014-03-19 19:27:11 +01:00
|
|
|
|
return QApplication::notify(receiver, event);
|
2013-09-23 14:08:06 +02:00
|
|
|
|
}
|
2013-11-04 21:35:15 +01:00
|
|
|
|
catch (const VExceptionObjectError &e)
|
|
|
|
|
{
|
2014-07-08 12:59:50 +02:00
|
|
|
|
e.CriticalMessageBox(tr("Error parsing file. Program will be terminated."), mainWindow);
|
2013-09-23 14:08:06 +02:00
|
|
|
|
abort();
|
|
|
|
|
}
|
2013-11-04 21:35:15 +01:00
|
|
|
|
catch (const VExceptionBadId &e)
|
|
|
|
|
{
|
2014-07-08 12:59:50 +02:00
|
|
|
|
e.CriticalMessageBox(tr("Error bad id. Program will be terminated."), mainWindow);
|
2013-09-23 14:08:06 +02:00
|
|
|
|
abort();
|
|
|
|
|
}
|
2013-11-04 21:35:15 +01:00
|
|
|
|
catch (const VExceptionConversionError &e)
|
|
|
|
|
{
|
2014-07-08 12:59:50 +02:00
|
|
|
|
e.CriticalMessageBox(tr("Error can't convert value. Program will be terminated."), mainWindow);
|
2013-09-23 14:08:06 +02:00
|
|
|
|
abort();
|
|
|
|
|
}
|
2013-11-04 21:35:15 +01:00
|
|
|
|
catch (const VExceptionEmptyParameter &e)
|
|
|
|
|
{
|
2014-07-08 12:59:50 +02:00
|
|
|
|
e.CriticalMessageBox(tr("Error empty parameter. Program will be terminated."), mainWindow);
|
2013-09-23 14:08:06 +02:00
|
|
|
|
abort();
|
|
|
|
|
}
|
2014-03-03 18:32:38 +01:00
|
|
|
|
catch (const VExceptionWrongId &e)
|
2013-11-04 21:35:15 +01:00
|
|
|
|
{
|
2014-07-08 12:59:50 +02:00
|
|
|
|
e.CriticalMessageBox(tr("Error wrong id. Program will be terminated."), mainWindow);
|
2013-09-23 14:08:06 +02:00
|
|
|
|
abort();
|
|
|
|
|
}
|
2013-11-04 21:35:15 +01:00
|
|
|
|
catch (const VException &e)
|
|
|
|
|
{
|
2014-07-08 12:59:50 +02:00
|
|
|
|
e.CriticalMessageBox(tr("Something's wrong!!"), mainWindow);
|
2014-03-03 16:42:14 +01:00
|
|
|
|
return true;
|
2013-10-10 20:45:58 +02:00
|
|
|
|
}
|
2013-11-04 21:35:15 +01:00
|
|
|
|
catch (std::exception& e)
|
|
|
|
|
{
|
2013-09-23 14:08:06 +02:00
|
|
|
|
qCritical() << "Exception thrown:" << e.what();
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
2014-03-19 19:27:11 +01:00
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-07-23 12:04:23 +02:00
|
|
|
|
double VApplication::toPixel(double val, const Unit &unit) const
|
2014-03-19 19:27:11 +01:00
|
|
|
|
{
|
|
|
|
|
double result = 0;
|
2014-07-23 12:04:23 +02:00
|
|
|
|
switch (unit)
|
2014-03-19 19:27:11 +01:00
|
|
|
|
{
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Mm:
|
2014-07-23 12:04:23 +02:00
|
|
|
|
result = (val / 25.4) * PrintDPI;
|
2014-03-19 19:27:11 +01:00
|
|
|
|
break;
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Cm:
|
2014-07-23 12:04:23 +02:00
|
|
|
|
result = ((val * 10.0) / 25.4) * PrintDPI;
|
2014-03-19 19:27:11 +01:00
|
|
|
|
break;
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Inch:
|
2014-07-23 12:04:23 +02:00
|
|
|
|
result = val * PrintDPI;
|
2014-03-19 19:27:11 +01:00
|
|
|
|
break;
|
|
|
|
|
default:
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-07-23 12:04:23 +02:00
|
|
|
|
double VApplication::toPixel(double val) const
|
|
|
|
|
{
|
|
|
|
|
return toPixel(val, _patternUnit);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
double VApplication::fromPixel(double pix, const Unit &unit) const
|
2014-03-19 19:27:11 +01:00
|
|
|
|
{
|
|
|
|
|
double result = 0;
|
2014-07-23 12:04:23 +02:00
|
|
|
|
switch (unit)
|
2014-03-19 19:27:11 +01:00
|
|
|
|
{
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Mm:
|
2014-03-19 19:27:11 +01:00
|
|
|
|
result = (pix / PrintDPI) * 25.4;
|
|
|
|
|
break;
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Cm:
|
2014-03-19 19:27:11 +01:00
|
|
|
|
result = ((pix / PrintDPI) * 25.4) / 10.0;
|
|
|
|
|
break;
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Inch:
|
2014-03-19 19:27:11 +01:00
|
|
|
|
result = pix / PrintDPI;
|
|
|
|
|
break;
|
|
|
|
|
default:
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
return result;
|
|
|
|
|
}
|
2014-05-02 13:11:30 +02:00
|
|
|
|
|
2014-07-23 12:04:23 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
double VApplication::fromPixel(double pix) const
|
|
|
|
|
{
|
|
|
|
|
return fromPixel(pix, _patternUnit);
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-03-19 19:27:11 +01:00
|
|
|
|
QString VApplication::pathToTables() const
|
|
|
|
|
{
|
2014-06-12 09:22:29 +02:00
|
|
|
|
if (_patternType == MeasurementsType::Individual)
|
2014-03-19 19:27:11 +01:00
|
|
|
|
{
|
2014-05-15 11:47:08 +02:00
|
|
|
|
return QStringLiteral("://tables/individual/individual.vit");
|
2014-03-19 19:27:11 +01:00
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
#ifdef Q_OS_WIN
|
2014-03-23 15:36:34 +01:00
|
|
|
|
return QApplication::applicationDirPath() + QStringLiteral("/tables/standard");
|
2014-03-19 19:27:11 +01:00
|
|
|
|
#else
|
|
|
|
|
#ifdef QT_DEBUG
|
2014-03-23 15:36:34 +01:00
|
|
|
|
return QApplication::applicationDirPath() + QStringLiteral("/tables/standard");
|
2014-03-19 19:27:11 +01:00
|
|
|
|
#else
|
2014-05-12 11:35:33 +02:00
|
|
|
|
QDir dir(QApplication::applicationDirPath() + QStringLiteral("/tables/standard"));
|
2014-06-10 22:14:16 +02:00
|
|
|
|
if (dir.exists())
|
2014-05-12 11:35:33 +02:00
|
|
|
|
{
|
|
|
|
|
return dir.absolutePath();
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
return QStringLiteral("/usr/share/valentina/tables/standard");
|
|
|
|
|
}
|
2014-03-19 19:27:11 +01:00
|
|
|
|
#endif
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-03-19 19:27:11 +01:00
|
|
|
|
QString VApplication::translationsPath() const
|
|
|
|
|
{
|
2014-03-26 05:39:07 +01:00
|
|
|
|
#ifdef Q_OS_WIN
|
|
|
|
|
return QApplication::applicationDirPath() + QStringLiteral("/translations");
|
|
|
|
|
#else
|
|
|
|
|
#ifdef QT_DEBUG
|
|
|
|
|
return QApplication::applicationDirPath() + QStringLiteral("/translations");
|
2014-05-12 11:35:33 +02:00
|
|
|
|
#else
|
|
|
|
|
QDir dir(QApplication::applicationDirPath() + QStringLiteral("/translations"));
|
2014-06-10 22:14:16 +02:00
|
|
|
|
if (dir.exists())
|
2014-05-12 11:35:33 +02:00
|
|
|
|
{
|
|
|
|
|
return dir.absolutePath();
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
2014-03-19 19:27:11 +01:00
|
|
|
|
return QStringLiteral("/usr/share/valentina/translations");
|
2014-05-12 11:35:33 +02:00
|
|
|
|
}
|
2014-03-19 19:27:11 +01:00
|
|
|
|
#endif
|
2014-05-12 11:35:33 +02:00
|
|
|
|
#endif
|
2014-03-19 19:27:11 +01:00
|
|
|
|
}
|
2014-03-26 05:39:07 +01:00
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-03-26 05:39:07 +01:00
|
|
|
|
void VApplication::InitLineWidth()
|
|
|
|
|
{
|
2014-05-01 13:33:40 +02:00
|
|
|
|
switch (_patternUnit)
|
2014-03-26 05:39:07 +01:00
|
|
|
|
{
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Mm:
|
2014-03-26 05:39:07 +01:00
|
|
|
|
_widthMainLine = DefWidth;
|
|
|
|
|
break;
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Cm:
|
2014-03-26 05:39:07 +01:00
|
|
|
|
_widthMainLine = DefWidth/10.0;
|
|
|
|
|
break;
|
2014-06-12 09:22:29 +02:00
|
|
|
|
case Unit::Inch:
|
2014-03-26 05:39:07 +01:00
|
|
|
|
_widthMainLine = DefWidth/25.4;
|
|
|
|
|
break;
|
|
|
|
|
default:
|
|
|
|
|
_widthMainLine = DefWidth;
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
_widthHairLine = _widthMainLine/3.0;
|
|
|
|
|
}
|
|
|
|
|
|
2014-09-16 21:08:48 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::InitMeasurement(const QString &name, const VTranslation &m, const VTranslation &g,
|
|
|
|
|
const VTranslation &d)
|
|
|
|
|
{
|
|
|
|
|
measurements.insert(name, m);
|
|
|
|
|
guiTexts.insert(name, g);
|
|
|
|
|
descriptions.insert(name, d);
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-13 10:08:37 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::InitMeasurements()
|
|
|
|
|
{
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//Note. We can't use here function and variables because lupdate tool doesn't see string in variables and doesn't
|
|
|
|
|
//mark such string to translation.
|
|
|
|
|
VTranslation m;
|
|
|
|
|
VTranslation g;
|
|
|
|
|
VTranslation d;
|
2014-05-13 10:08:37 +02:00
|
|
|
|
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
// head_and_neck
|
|
|
|
|
m = VTranslation::translate("Measurements", "head_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Head girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around fullest part of Head",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(headGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "mid_neck_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Mid-neck girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around middle part of Neck",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(midNeckGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_base_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck Base girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Neck at base", "Full measurement description");
|
|
|
|
|
InitMeasurement(neckBaseGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "head_and_neck_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Head and Neck length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Vertical Distance from Crown to Nape",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(headAndNeckLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
2014-05-13 10:08:37 +02:00
|
|
|
|
// torso
|
2014-05-24 18:50:40 +02:00
|
|
|
|
m = VTranslation::translate("Measurements", "center_front_waist_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Center length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front Neck Center over tape at Bustline to Front Waist "
|
|
|
|
|
"Center", "Full measurement description");
|
|
|
|
|
InitMeasurement(centerFrontWaistLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "center_back_waist_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Center length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Back Neck Center to Back Waist Center",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(centerBackWaistLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "shoulder_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Shoulder length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint to ShoulderTip", "Full measurement description");
|
|
|
|
|
InitMeasurement(shoulderLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "side_waist_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Side Waist length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Armpit to Waist side", "Full measurement description");
|
|
|
|
|
InitMeasurement(sideWaistLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "trunk_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Trunk length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Around Body from middle of Shoulder length to BustPoint to Crotch up back to beginning"
|
|
|
|
|
" point",
|
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(trunkLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "shoulder_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Shoulder girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Arms and Torso, at bicep level parallel to floor, "
|
|
|
|
|
"with arms hanging at the sides", "Full measurement description");
|
|
|
|
|
InitMeasurement(shoulderGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "upper_chest_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Upper Chest girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Chest at Armfold level, will be parallel to floor "
|
|
|
|
|
"across back, will not be parallel to floor across front chest",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(upperChestGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "bust_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Bust girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around fullest part of Bust, parallel to floor",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(bustGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "under_bust_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Under Bust girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Chest below the Bust, parallel to floor",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(underBustGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "waist_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Waist girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Tie a string around smallest part of waist, keep string "
|
|
|
|
|
"tied while taking meaasurements. Not usually parallel to floor for front waist or "
|
|
|
|
|
"back waist.",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(waistGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "high_hip_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "HighHip girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around HighHip, parallel to floor",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(highHipGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "hip_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Hip girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Hip, parallel to floor",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(hipGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "upper_front_chest_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Upper Chest width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Across Front UpperChest, smallest width from armscye to "
|
|
|
|
|
"armscye", "Full measurement description");
|
|
|
|
|
InitMeasurement(upperFrontChestWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_chest_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Chest width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Across Front Chest, from armfold to armfold",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontChestWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "across_front_shoulder_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Across Shoulder width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "From ShoulderTip to ShoulderTip, across Front",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(acrossFrontShoulderWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "across_back_shoulder_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Across Shoulder width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "From ShoulderTip to ShoulderTip, across Back",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(acrossBackShoulderWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "upper_back_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Upper Chest width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Across Back UpperChest, smallest width from armscye to "
|
|
|
|
|
"armscye", "Full measurement description");
|
|
|
|
|
InitMeasurement(upperBackWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Chest width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Across Back Chest, from armfold to armfold",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(backWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "bustpoint_to_bustpoint",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "BustPoint to BustPoint", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Distance between BustPoints, across Chest",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(bustpointToBustpoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "halter_bustpoint_to_bustpoint",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Halter Bustpoint to Bustpoint", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Distance from Bustpoint, behind neck, down to Bustpoint",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(halterBustpointToBustpoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_bustpoint",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "NeckPoint to BustPoint", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "From NeckPoint to BustPoint",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(neckToBustpoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "crotch_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Crotch length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "From Front Waist Center, down to crotch, up to Back Waist "
|
|
|
|
|
"Center", "Full measurement description");
|
|
|
|
|
InitMeasurement(crotchLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "rise_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Rise height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Sit on hard chair, measure from side waist straight down "
|
|
|
|
|
"to chair bottom", "Full measurement description");
|
|
|
|
|
InitMeasurement(riseHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "shoulder_drop",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Shoulder Drop", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Vertical Distance from NeckPoint level to ShoulderTip "
|
|
|
|
|
"level", "Full measurement description");
|
|
|
|
|
InitMeasurement(shoulderDrop_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "shoulder_slope_degrees",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Shoulder Slope degrees", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Degrees of angle from NeckPoint to ShoulderTip – requires "
|
|
|
|
|
"goniometer", "Full measurement description");
|
|
|
|
|
InitMeasurement(shoulderSlopeDegrees_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_shoulder_slope_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Shoulder Balance", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "ShoulderTip to Front Waist Center",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(frontShoulderSlopeLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_shoulder_slope_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Shoulder Balance", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "ShoulderTip to Back Waist Center",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(backShoulderSlopeLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_shoulder_to_waist_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Full Length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint straight down front chest to Waistline",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontShoulderToWaistLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_shoulder_to_waist_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Full Length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Back NeckPoint straight down back chest to Waistline",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(backShoulderToWaistLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_neck_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Neck arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint to NeckPoint through Front Neck Center",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontNeckArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_neck_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Neck arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint to NeckPoint across Nape",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(backNeckArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_upper_chest_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-17 20:29:46 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front upper-bust arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front upper-bust arc", "Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontUpperChestArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_upper_chest_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back UpperBust arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Back UpperBust side to side",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(backUpperChestArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_waist_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Waist arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front Waist side to side", "Full measurement description");
|
|
|
|
|
InitMeasurement(frontWaistArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_waist_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Waist arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Back Waist side to side", "Full measurement description");
|
|
|
|
|
InitMeasurement(backWaistArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_upper_hip_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front UpperHip arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front UpperHip side to side",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(frontUpperHipArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_upper_hip_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back UpperHip arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Back UpperHip side to side",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(backUpperHipArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_hip_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Hip arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front Hip side to side",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(frontHipArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_hip_arc",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Hip arc", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Back Hip side to side", "Full measurement description");
|
|
|
|
|
InitMeasurement(backHipArc_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "chest_slope",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Chest Balance", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint to Front ArmfoldPoint",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(chestSlope_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_slope",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Balance", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint to Back ArmfoldPoint",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(backSlope_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_waist_slope",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Waist Balance", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint across Front Chest to Waist side",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontWaistSlope_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_waist_slope",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back Waist Balance", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint across Back Chest to Waist side",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(backWaistSlope_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_neck_to_upper_chest_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front UpperChest height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front Neck Center straight down to UpperChest line",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontNeckToUpperChestHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_neck_to_bust_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Bust height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front Neck Center straight down to Bust line",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontNeckToBustHeight_M, m, g, d);
|
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_waist_to_upper_chest",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front Upper chest waist", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front Upper chest waist",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(frontWaistToUpperChest_M, m, g, d);
|
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_waist_to_lower_breast",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front waist to lower breast", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front waist to lower breast",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(frontWaistToLowerBreast_M, m, g, d);
|
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "back_waist_to_upper_chest",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Back waist to upper chest", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Back waist to upper chest",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(backWaistToUpperChest_M, m, g, d);
|
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "strap_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Strap length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Strap length",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(strapLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
2014-05-13 10:08:37 +02:00
|
|
|
|
// arm
|
2014-05-24 18:50:40 +02:00
|
|
|
|
m = VTranslation::translate("Measurements", "armscye_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Armscye Girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Armscye", "Full measurement description");
|
|
|
|
|
InitMeasurement(armscyeGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "elbow_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Elbow Girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Elbow with elbow bent",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(elbowGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "upper_arm_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Upperarm Girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around UpperArm", "Full measurement description");
|
|
|
|
|
InitMeasurement(upperArmGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "wrist_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Wrist girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Wrist", "Full measurement description");
|
|
|
|
|
InitMeasurement(wristGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "scye_depth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Armscye depth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Nape straight down to UnderBust line (same as Back "
|
|
|
|
|
"UpperBust height)", "Full measurement description");
|
|
|
|
|
InitMeasurement(scyeDepth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "shoulder_and_arm_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Shoulder and Arm length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "NeckPoint to ShoulderTip to Wrist, with elbow bent and "
|
|
|
|
|
"hand on hip", "Full measurement description");
|
|
|
|
|
InitMeasurement(shoulderAndArmLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "underarm_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Underarm length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Armpit to Wrist, with arm straight and hanging at side",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(underarmLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "cervicale_to_wrist_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Nape to wrist length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Nape to Wrist, with elbow bent and hand on hip",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(cervicaleToWristLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "shoulder_to_elbow_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Elbow length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "ShoulderTip to Elbow, with elbow bent and hand on hip",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(shoulderToElbowLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "arm_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Arm length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "ShoulderTip to Wrist, with elbow bent and hand on hip",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(armLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
2014-05-13 10:08:37 +02:00
|
|
|
|
// hand
|
2014-05-24 18:50:40 +02:00
|
|
|
|
m = VTranslation::translate("Measurements", "hand_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Hand width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Hand side to side", "Full measurement description");
|
|
|
|
|
InitMeasurement(handWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "hand_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Hand length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Hand Middle Finger tip to wrist",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(handLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "hand_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Hand girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Hand", "Full measurement description");
|
|
|
|
|
InitMeasurement(handGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
2014-05-13 10:08:37 +02:00
|
|
|
|
// leg
|
2014-05-24 18:50:40 +02:00
|
|
|
|
m = VTranslation::translate("Measurements", "thigh_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Thigh girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Thigh", "Full measurement description");
|
|
|
|
|
InitMeasurement(thighGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "mid_thigh_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Midthigh girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around MidThigh", "Full measurement description");
|
|
|
|
|
InitMeasurement(midThighGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "knee_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Knee girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Knee", "Full measurement description");
|
|
|
|
|
InitMeasurement(kneeGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "calf_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Calf girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Calf", "Full measurement description");
|
|
|
|
|
InitMeasurement(calfGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "ankle_girth",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Ankle girth", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Around Ankle", "Full measurement description");
|
|
|
|
|
InitMeasurement(ankleGirth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "knee_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Knee height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Knee to Floor", "Full measurement description");
|
|
|
|
|
InitMeasurement(kneeHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "ankle_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Ankle height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Ankle to Floor", "Full measurement description");
|
|
|
|
|
InitMeasurement(ankleHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
2014-05-13 10:08:37 +02:00
|
|
|
|
// foot
|
2014-05-24 18:50:40 +02:00
|
|
|
|
m = VTranslation::translate("Measurements", "foot_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Foot width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Widest part of Foot side to side",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(footWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "foot_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Foot length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Tip of Longest Toe straight to back of heel",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(footLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
2014-05-13 10:08:37 +02:00
|
|
|
|
// heights
|
2014-05-24 18:50:40 +02:00
|
|
|
|
m = VTranslation::translate("Measurements", "height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Total Height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Top of head to floor", "Full measurement description");
|
|
|
|
|
InitMeasurement(height_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "cervicale_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Nape height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Nape to Floor", "Full measurement description");
|
|
|
|
|
InitMeasurement(cervicaleHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "cervicale_to_knee_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Nape to knee height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Nape to Knee", "Full measurement description");
|
|
|
|
|
InitMeasurement(cervicaleToKneeHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "waist_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Waist height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Waist side to floor", "Full measurement description");
|
|
|
|
|
InitMeasurement(waistHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "high_hip_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "HighHip height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "HighHip side to Floor", "Full measurement description");
|
|
|
|
|
InitMeasurement(highHipHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "hip_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Hip height", "Full measurement name");
|
2014-09-17 20:29:46 +02:00
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Hip side to Floor", "Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(hipHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "waist_to_hip_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Waist to Hip height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Waist side to Hip", "Full measurement description");
|
|
|
|
|
InitMeasurement(waistToHipHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "waist_to_knee_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Waist to Knee height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Waist side to Knee", "Full measurement description");
|
|
|
|
|
InitMeasurement(waistToKneeHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "crotch_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Crotch height/Inseam", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Crotch to Floor along inside leg",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(crotchHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
2014-05-15 15:18:31 +02:00
|
|
|
|
//extended
|
2014-05-24 18:50:40 +02:00
|
|
|
|
m = VTranslation::translate("Measurements", "size", "Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Size", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Size", "Full measurement description");
|
|
|
|
|
InitMeasurement(size_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_front_neck_base_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height front neck base point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Height of the point base of the neck in front",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(heightFrontNeckBasePoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_base_neck_side_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height base neck side point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Height of the base of the neck side point",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(heightBaseNeckSidePoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_shoulder_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height shoulder point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The height of the shoulder point",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(heightShoulderPoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_nipple_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height nipple point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Height nipple point", "Full measurement description");
|
|
|
|
|
InitMeasurement(heightNipplePoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_back_angle_axilla",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height back angle axilla", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Height back angle axilla", "Full measurement description");
|
|
|
|
|
InitMeasurement(heightBackAngleAxilla_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_scapular_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height scapular point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Height scapular point", "Full measurement description");
|
|
|
|
|
InitMeasurement(heightScapularPoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_under_buttock_folds",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height under buttock folds", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Height under buttock folds",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(heightUnderButtockFolds_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "hips_excluding_protruding_abdomen",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Hips excluding protruding abdomen", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Hips excluding protruding abdomen",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(hipsExcludingProtrudingAbdomen_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "girth_foot_instep",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Girth foot instep", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Girth foot instep", "Full measurement description");
|
|
|
|
|
InitMeasurement(girthFootInstep_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "side_waist_to_floor",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Side waist to floor", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the side waist to floor",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(sideWaistToFloor_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_waist_to_floor",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front waist to floor", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the front waist to floor",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(frontWaistToFloor_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "arc_through_groin_area",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Arc through groin area", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Arc through groin area", "Full measurement description");
|
|
|
|
|
InitMeasurement(arcThroughGroinArea_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "waist_to_plane_seat",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Waist to plane seat", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the waist to the plane seat",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(waistToPlaneSeat_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_radial_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck to radial point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the base of the neck to the side of the "
|
|
|
|
|
"radial point", "Full measurement description");
|
|
|
|
|
InitMeasurement(neckToRadialPoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_third_finger",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck to third finger", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Distance from the base of the neck side point to the end "
|
|
|
|
|
"of the third finger", "Full measurement description");
|
|
|
|
|
InitMeasurement(neckToThirdFinger_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_first_line_chest_circumference",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck to first line chest circumference",
|
|
|
|
|
"Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the base of the neck to the side of the "
|
|
|
|
|
"first line in front of chest circumference", "Full measurement description");
|
|
|
|
|
InitMeasurement(neckToFirstLineChestCircumference_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_waist_length",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front waist length", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the base of the neck to the waist side "
|
|
|
|
|
"front (waist length in the front)", "Full measurement description");
|
|
|
|
|
InitMeasurement(frontWaistLength_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "arc_through_shoulder_joint",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Arc through shoulder joint", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Arc through the highest point of the shoulder joint",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(arcThroughShoulderJoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_back_line_chest_circumference",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck to back line chest circumference",
|
|
|
|
|
"Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the base of the neck to the back line "
|
|
|
|
|
"of chest circumference of the first and the second based on ledge vanes",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(neckToBackLineChestCircumference_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "waist_to_neck_side",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Waist to neck side", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the waist to the back base of the neck "
|
|
|
|
|
"side point", "Full measurement description");
|
|
|
|
|
InitMeasurement(waistToNeckSide_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "arc_length_upper_body",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Arc length upper body", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Arc length of the upper body through the base of the neck "
|
|
|
|
|
"side point", "Full measurement description");
|
|
|
|
|
InitMeasurement(arcLengthUpperBody_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "chest_width",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Chest width", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Chest width", "Full measurement description");
|
|
|
|
|
InitMeasurement(chestWidth_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "anteroposterior_diameter_hands",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Anteroposterior diameter hands", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Anteroposterior diameter of the hands",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(anteroposteriorDiameterHands_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_clavicular_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height clavicular point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Height clavicular point", "Full measurement description");
|
|
|
|
|
InitMeasurement(heightClavicularPoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "height_armhole_slash",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Height armhole slash", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the point to the cervical level of the "
|
|
|
|
|
"posterior angle of the front armpit (underarm height oblique)",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(heightArmholeSlash_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "slash_shoulder_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Slash shoulder height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Slash shoulder height", "Full measurement description");
|
|
|
|
|
InitMeasurement(slashShoulderHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_neck",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth neck", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth neck", "Full measurement description");
|
|
|
|
|
InitMeasurement(halfGirthNeck_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_neck_for_shirts",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth neck for shirts", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth neck for shirts",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(halfGirthNeckForShirts_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_chest_first",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth chest first", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth chest first", "Full measurement description");
|
|
|
|
|
InitMeasurement(halfGirthChestFirst_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_chest_second",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth chest second", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth chest second", "Full measurement description");
|
|
|
|
|
InitMeasurement(halfGirthChestSecond_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_chest_third",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth chest third", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth chest third", "Full measurement description");
|
|
|
|
|
InitMeasurement(halfGirthChestThird_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_waist",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth waist", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth waist", "Full measurement description");
|
|
|
|
|
InitMeasurement(halfGirthWaist_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_hips_considering_protruding_abdomen",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth hips considering protruding abdomen",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement name");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth hips considering protruding abdomen",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(halfGirthHipsConsideringProtrudingAbdomen_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "half_girth_hips_excluding_protruding_abdomen",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Half girth hips excluding protruding abdomen",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement name");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Half girth hips excluding protruding abdomen",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(halfGirthHipsExcludingProtrudingAbdomen_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "girth_knee_flexed_feet",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Girth knee flexed feet", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Girth knee flexed feet", "Full measurement description");
|
|
|
|
|
InitMeasurement(girthKneeFlexedFeet_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_transverse_diameter",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck transverse diameter", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Neck transverse diameter", "Full measurement description");
|
|
|
|
|
InitMeasurement(neckTransverseDiameter_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "front_slash_shoulder_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Front slash shoulder height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Front slash shoulder height",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(frontSlashShoulderHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_front_waist_line",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck to front waist line", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the base of the neck to the waist line "
|
|
|
|
|
"front", "Full measurement description");
|
|
|
|
|
InitMeasurement(neckToFrontWaistLine_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "hand_vertical_diameter",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Hand vertical diameter", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Hand vertical diameter", "Full measurement description");
|
|
|
|
|
InitMeasurement(handVerticalDiameter_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_knee_point",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck to knee point", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Distance from neck to knee point",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(neckToKneePoint_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "waist_to_knee",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Waist to knee", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "The distance from the waist to the knee",
|
2014-05-24 18:50:40 +02:00
|
|
|
|
"Full measurement description");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
InitMeasurement(waistToKnee_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "shoulder_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Shoulder height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Shoulder height", "Full measurement description");
|
|
|
|
|
InitMeasurement(shoulderHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "head_height",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Head height", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Head height", "Full measurement description");
|
|
|
|
|
InitMeasurement(headHeight_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "body_position",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Body position", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Body position", "Full measurement description");
|
|
|
|
|
InitMeasurement(bodyPosition_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "arc_behind_shoulder_girdle",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Arc behind shoulder girdle", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Arc behind the shoulder girdle",
|
|
|
|
|
"Full measurement description");
|
|
|
|
|
InitMeasurement(arcBehindShoulderGirdle_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "neck_to_neck_base",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Neck to neck base", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Distance from neck point to point on the base of the neck "
|
|
|
|
|
"side neck girth measurement line", "Full measurement description");
|
|
|
|
|
InitMeasurement(neckToNeckBase_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "depth_waist_first",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Depth waist first", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Depth waist first", "Full measurement description");
|
|
|
|
|
InitMeasurement(depthWaistFirst_M, m, g, d);
|
2014-05-24 18:50:40 +02:00
|
|
|
|
//=================================================================================================================
|
|
|
|
|
m = VTranslation::translate("Measurements", "depth_waist_second",
|
|
|
|
|
"Short measurement name. Don't use math symbols in name!!!!");
|
2014-09-16 21:08:48 +02:00
|
|
|
|
g = VTranslation::translate("MeasurementsFullNames", "Depth waist second", "Full measurement name");
|
|
|
|
|
d = VTranslation::translate("MeasurementsDescriptions", "Depth waist second", "Full measurement description");
|
|
|
|
|
InitMeasurement(depthWaistSecond_M, m, g, d);
|
2014-05-13 10:08:37 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::InitVariables()
|
|
|
|
|
{
|
2014-05-24 18:50:40 +02:00
|
|
|
|
variables.insert(line_, VTranslation::translate("Variables", "Line_", "Left symbol _ in name"));
|
|
|
|
|
variables.insert(angleLine_, VTranslation::translate("Variables", "AngleLine_", "Left symbol _ in name"));
|
|
|
|
|
variables.insert(arc_, VTranslation::translate("Variables", "Arc_", "Left symbol _ in name"));
|
|
|
|
|
variables.insert(spl_, VTranslation::translate("Variables", "Spl_", "Left symbol _ in name"));
|
|
|
|
|
variables.insert(splPath, VTranslation::translate("Variables", "SplPath"));
|
2014-05-13 10:08:37 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::InitFunctions()
|
|
|
|
|
{
|
2014-05-24 18:50:40 +02:00
|
|
|
|
functions.insert(sin_F, VTranslation::translate("Functions", "sin", "sine function"));
|
|
|
|
|
functions.insert(cos_F, VTranslation::translate("Functions", "cos", "cosine function"));
|
|
|
|
|
functions.insert(tan_F, VTranslation::translate("Functions", "tan", "tangens function"));
|
|
|
|
|
functions.insert(asin_F, VTranslation::translate("Functions", "asin", "arcus sine function"));
|
|
|
|
|
functions.insert(acos_F, VTranslation::translate("Functions", "acos", "arcus cosine function"));
|
|
|
|
|
functions.insert(atan_F, VTranslation::translate("Functions", "atan", "arcus tangens function"));
|
|
|
|
|
functions.insert(sinh_F, VTranslation::translate("Functions", "sinh", "hyperbolic sine function"));
|
|
|
|
|
functions.insert(cosh_F, VTranslation::translate("Functions", "cosh", "hyperbolic cosine"));
|
|
|
|
|
functions.insert(tanh_F, VTranslation::translate("Functions", "tanh", "hyperbolic tangens function"));
|
|
|
|
|
functions.insert(asinh_F, VTranslation::translate("Functions", "asinh", "hyperbolic arcus sine function"));
|
|
|
|
|
functions.insert(acosh_F, VTranslation::translate("Functions", "acosh", "hyperbolic arcus tangens function"));
|
|
|
|
|
functions.insert(atanh_F, VTranslation::translate("Functions", "atanh", "hyperbolic arcur tangens function"));
|
|
|
|
|
functions.insert(log2_F, VTranslation::translate("Functions", "log2", "logarithm to the base 2"));
|
|
|
|
|
functions.insert(log10_F, VTranslation::translate("Functions", "log10", "logarithm to the base 10"));
|
|
|
|
|
functions.insert(log_F, VTranslation::translate("Functions", "log", "logarithm to the base 10"));
|
|
|
|
|
functions.insert(ln_F, VTranslation::translate("Functions", "ln", "logarithm to base e (2.71828...)"));
|
|
|
|
|
functions.insert(exp_F, VTranslation::translate("Functions", "exp", "e raised to the power of x"));
|
|
|
|
|
functions.insert(sqrt_F, VTranslation::translate("Functions", "sqrt", "square root of a value"));
|
|
|
|
|
functions.insert(sign_F, VTranslation::translate("Functions", "sign", "sign function -1 if x<0; 1 if x>0"));
|
|
|
|
|
functions.insert(rint_F, VTranslation::translate("Functions", "rint", "round to nearest integer"));
|
|
|
|
|
functions.insert(abs_F, VTranslation::translate("Functions", "abs", "absolute value"));
|
|
|
|
|
functions.insert(min_F, VTranslation::translate("Functions", "min", "min of all arguments"));
|
|
|
|
|
functions.insert(max_F, VTranslation::translate("Functions", "max", "max of all arguments"));
|
|
|
|
|
functions.insert(sum_F, VTranslation::translate("Functions", "sum", "sum of all arguments"));
|
|
|
|
|
functions.insert(avg_F, VTranslation::translate("Functions", "avg", "mean value of all arguments"));
|
2014-05-13 10:08:37 +02:00
|
|
|
|
}
|
|
|
|
|
|
2014-05-23 20:11:13 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-05-23 09:14:21 +02:00
|
|
|
|
void VApplication::InitPostfixOperators()
|
|
|
|
|
{
|
2014-05-24 18:50:40 +02:00
|
|
|
|
postfixOperators.insert(cm_Oprt, VTranslation::translate("PostfixOperators", "cm", "centimeter"));
|
|
|
|
|
postfixOperators.insert(mm_Oprt, VTranslation::translate("PostfixOperators", "mm", "millimeter"));
|
|
|
|
|
postfixOperators.insert(in_Oprt, VTranslation::translate("PostfixOperators", "in", "inch"));
|
2014-05-23 09:14:21 +02:00
|
|
|
|
}
|
|
|
|
|
|
2014-09-18 11:30:33 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::InitSTDescriptions()
|
|
|
|
|
{
|
|
|
|
|
stDescriptions.insert("0", VTranslation::translate("STDescriptions",
|
|
|
|
|
"Standard figures of men 1st group, chest 100 cm",
|
|
|
|
|
"Standard table description"));
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-23 20:11:13 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bool VApplication::MeasurementsFromUser(QString &newFormula, int position, const QString &token, int &bias) const
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
QMap<QString, VTranslation>::const_iterator i = measurements.constBegin();
|
|
|
|
|
while (i != measurements.constEnd())
|
|
|
|
|
{
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (token == i.value().translate())
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
newFormula.replace(position, token.length(), i.key());
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bias = token.length() - i.key().length();
|
2014-05-23 20:11:13 +02:00
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
++i;
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bool VApplication::VariablesFromUser(QString &newFormula, int position, const QString &token, int &bias) const
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
QMap<QString, VTranslation>::const_iterator i = variables.constBegin();
|
|
|
|
|
while (i != variables.constEnd())
|
|
|
|
|
{
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (token.indexOf( i.value().translate() ) == 0)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
newFormula.replace(position, i.value().translate().length(), i.key());
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QString newToken = token;
|
|
|
|
|
newToken.replace(0, i.value().translate().length(), i.key());
|
|
|
|
|
bias = token.length() - newToken.length();
|
2014-05-23 20:11:13 +02:00
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
++i;
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bool VApplication::PostfixOperatorsFromUser(QString &newFormula, int position, const QString &token, int &bias) const
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
QMap<QString, VTranslation>::const_iterator i = postfixOperators.constBegin();
|
|
|
|
|
while (i != postfixOperators.constEnd())
|
|
|
|
|
{
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (token == i.value().translate())
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
newFormula.replace(position, token.length(), i.key());
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bias = token.length() - i.key().length();
|
2014-05-23 20:11:13 +02:00
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
++i;
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bool VApplication::FunctionsFromUser(QString &newFormula, int position, const QString &token, int &bias) const
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
QMap<QString, VTranslation>::const_iterator i = functions.constBegin();
|
|
|
|
|
while (i != functions.constEnd())
|
|
|
|
|
{
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (token == i.value().translate())
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
newFormula.replace(position, token.length(), i.key());
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bias = token.length() - i.key().length();
|
2014-05-23 20:11:13 +02:00
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
++i;
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-05-27 16:58:25 +02:00
|
|
|
|
bool VApplication::VariablesToUser(QString &newFormula, int position, const QString &token, int &bias) const
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
QMap<QString, VTranslation>::const_iterator i = variables.constBegin();
|
|
|
|
|
while (i != variables.constEnd())
|
|
|
|
|
{
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (token.indexOf( i.key() ) == 0)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-26 15:18:48 +02:00
|
|
|
|
newFormula.replace(position, i.key().length(), i.value().translate());
|
2014-05-27 16:58:25 +02:00
|
|
|
|
|
|
|
|
|
QString newToken = token;
|
|
|
|
|
newToken.replace(0, i.key().length(), i.value().translate());
|
|
|
|
|
bias = token.length() - newToken.length();
|
2014-05-23 20:11:13 +02:00
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
++i;
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
void VApplication::CorrectionsPositions(int position, int bias, QMap<int, QString> &tokens,
|
|
|
|
|
QMap<int, QString> &numbers)
|
|
|
|
|
{
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (bias == 0)
|
2014-05-27 16:58:25 +02:00
|
|
|
|
{
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
BiasTokens(position, bias, tokens);
|
|
|
|
|
BiasTokens(position, bias, numbers);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void VApplication::BiasTokens(int position, int bias, QMap<int, QString> &tokens) const
|
|
|
|
|
{
|
|
|
|
|
QMap<int, QString> newTokens;
|
|
|
|
|
QMap<int, QString>::const_iterator i = tokens.constBegin();
|
|
|
|
|
while (i != tokens.constEnd())
|
|
|
|
|
{
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (i.key()<= position)
|
2014-05-27 16:58:25 +02:00
|
|
|
|
{
|
|
|
|
|
newTokens.insert(i.key(), i.value());
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
newTokens.insert(i.key()-bias, i.value());
|
|
|
|
|
}
|
|
|
|
|
++i;
|
|
|
|
|
}
|
|
|
|
|
tokens = newTokens;
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-02 13:11:30 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-06-12 09:22:29 +02:00
|
|
|
|
void VApplication::setPatternUnit(const Unit &patternUnit)
|
2014-03-26 05:39:07 +01:00
|
|
|
|
{
|
|
|
|
|
_patternUnit = patternUnit;
|
|
|
|
|
InitLineWidth();
|
|
|
|
|
}
|
2014-05-16 12:00:33 +02:00
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-05-26 15:18:48 +02:00
|
|
|
|
QString VApplication::VarToUser(const QString &var) const
|
2014-05-16 12:00:33 +02:00
|
|
|
|
{
|
2014-05-26 15:18:48 +02:00
|
|
|
|
if (measurements.contains(var))
|
|
|
|
|
{
|
|
|
|
|
return measurements.value(var).translate();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (functions.contains(var))
|
|
|
|
|
{
|
|
|
|
|
return functions.value(var).translate();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (postfixOperators.contains(var))
|
|
|
|
|
{
|
|
|
|
|
return postfixOperators.value(var).translate();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
QString newVar = var;
|
2014-05-27 16:58:25 +02:00
|
|
|
|
int bias = 0;
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (VariablesToUser(newVar, 0, var, bias))
|
2014-05-26 15:18:48 +02:00
|
|
|
|
{
|
|
|
|
|
return newVar;
|
|
|
|
|
}
|
|
|
|
|
return newVar;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QString VApplication::VarFromUser(const QString &var) const
|
|
|
|
|
{
|
|
|
|
|
QString newVar = var;
|
2014-05-27 16:58:25 +02:00
|
|
|
|
int bias = 0;
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (MeasurementsFromUser(newVar, 0, var, bias))
|
2014-05-26 15:18:48 +02:00
|
|
|
|
{
|
|
|
|
|
return newVar;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (VariablesFromUser(newVar, 0, var, bias))
|
2014-05-26 15:18:48 +02:00
|
|
|
|
{
|
|
|
|
|
return newVar;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (PostfixOperatorsFromUser(newVar, 0, var, bias))
|
2014-05-26 15:18:48 +02:00
|
|
|
|
{
|
|
|
|
|
return newVar;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (FunctionsFromUser(newVar, 0, var, bias))
|
2014-05-26 15:18:48 +02:00
|
|
|
|
{
|
|
|
|
|
return newVar;
|
|
|
|
|
}
|
|
|
|
|
return newVar;
|
2014-05-16 12:00:33 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QString VApplication::GuiText(const QString &measurement) const
|
|
|
|
|
{
|
|
|
|
|
return guiTexts.value(measurement).translate();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QString VApplication::Description(const QString &measurement) const
|
|
|
|
|
{
|
|
|
|
|
return descriptions.value(measurement).translate();
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-23 20:11:13 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QString VApplication::PostfixOperator(const QString &name) const
|
|
|
|
|
{
|
|
|
|
|
return postfixOperators.value(name).translate();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QString VApplication::FormulaFromUser(const QString &formula)
|
|
|
|
|
{
|
|
|
|
|
QString newFormula = formula;
|
|
|
|
|
|
2014-05-30 10:32:40 +02:00
|
|
|
|
Calculator *cal = new Calculator(formula);
|
|
|
|
|
QMap<int, QString> tokens = cal->GetTokens();
|
|
|
|
|
QMap<int, QString> numbers = cal->GetNumbers();
|
|
|
|
|
delete cal;
|
2014-05-23 20:11:13 +02:00
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QList<int> tKeys = tokens.keys();
|
|
|
|
|
QList<QString> tValues = tokens.values();
|
|
|
|
|
for (int i = 0; i < tKeys.size(); ++i)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
int bias = 0;
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (MeasurementsFromUser(newFormula, tKeys.at(i), tValues.at(i), bias))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (VariablesFromUser(newFormula, tKeys.at(i), tValues.at(i), bias))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (PostfixOperatorsFromUser(newFormula, tKeys.at(i), tValues.at(i), bias))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (FunctionsFromUser(newFormula, tKeys.at(i), tValues.at(i), bias))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2014-07-10 11:36:46 +02:00
|
|
|
|
bool osSeparatorValue = getSettings()->value("configuration/osSeparator", 1).toBool();
|
2014-05-29 10:46:28 +02:00
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QLocale loc = QLocale::system();
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (loc != QLocale(QLocale::C) && osSeparatorValue)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QList<int> nKeys = numbers.keys();
|
|
|
|
|
QList<QString> nValues = numbers.values();
|
2014-05-30 10:32:40 +02:00
|
|
|
|
for (int i = 0; i < nKeys.size(); ++i)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
|
|
|
|
bool ok = false;
|
2014-05-27 16:58:25 +02:00
|
|
|
|
qreal d = loc.toDouble(nValues.at(i), &ok);
|
|
|
|
|
if (ok == false)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
qDebug()<<"Can't convert to double token"<<nValues.at(i);
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (qFloor (d) < d)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QLocale loc = QLocale(QLocale::C);
|
2014-05-23 20:11:13 +02:00
|
|
|
|
QString dStr = loc.toString(d);
|
2014-05-27 16:58:25 +02:00
|
|
|
|
newFormula.replace(nKeys.at(i), nValues.at(i).length(), dStr);
|
|
|
|
|
int bias = nValues.at(i).length() - dStr.length();
|
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(nKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
nKeys = numbers.keys();
|
|
|
|
|
nValues = numbers.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
}
|
2014-05-27 16:58:25 +02:00
|
|
|
|
|
2014-05-23 20:11:13 +02:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return newFormula;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QString VApplication::FormulaToUser(const QString &formula)
|
|
|
|
|
{
|
|
|
|
|
QString newFormula = formula;
|
|
|
|
|
|
|
|
|
|
QMap<int, QString> tokens;
|
|
|
|
|
QMap<int, QString> numbers;
|
|
|
|
|
try
|
|
|
|
|
{
|
2014-05-30 10:32:40 +02:00
|
|
|
|
Calculator *cal = new Calculator(formula, false);
|
|
|
|
|
tokens = cal->GetTokens();
|
|
|
|
|
numbers = cal->GetNumbers();
|
|
|
|
|
delete cal;
|
2014-05-23 20:11:13 +02:00
|
|
|
|
}
|
|
|
|
|
catch (qmu::QmuParserError &e)
|
|
|
|
|
{
|
|
|
|
|
qDebug() << "\nMath parser error:\n"
|
|
|
|
|
<< "--------------------------------------\n"
|
|
|
|
|
<< "Message: " << e.GetMsg() << "\n"
|
|
|
|
|
<< "Expression: " << e.GetExpr() << "\n"
|
|
|
|
|
<< "--------------------------------------";
|
|
|
|
|
return newFormula;
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QList<int> tKeys = tokens.keys();
|
|
|
|
|
QList<QString> tValues = tokens.values();
|
|
|
|
|
for (int i = 0; i < tKeys.size(); ++i)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (measurements.contains(tValues.at(i)))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
newFormula.replace(tKeys.at(i), tValues.at(i).length(), measurements.value(tValues.at(i)).translate());
|
|
|
|
|
int bias = tValues.at(i).length() - measurements.value(tValues.at(i)).translate().length();
|
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (functions.contains(tValues.at(i)))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
newFormula.replace(tKeys.at(i), tValues.at(i).length(), functions.value(tValues.at(i)).translate());
|
|
|
|
|
int bias = tValues.at(i).length() - functions.value(tValues.at(i)).translate().length();
|
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (postfixOperators.contains(tValues.at(i)))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
newFormula.replace(tKeys.at(i), tValues.at(i).length(), postfixOperators.value(tValues.at(i)).translate());
|
|
|
|
|
int bias = tValues.at(i).length() - postfixOperators.value(tValues.at(i)).translate().length();
|
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
int bias = 0;
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (VariablesToUser(newFormula, tKeys.at(i), tValues.at(i), bias))
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(tKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
tKeys = tokens.keys();
|
|
|
|
|
tValues = tokens.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2014-07-10 11:36:46 +02:00
|
|
|
|
bool osSeparatorValue = getSettings()->value("configuration/osSeparator", 1).toBool();
|
2014-05-29 10:46:28 +02:00
|
|
|
|
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QLocale loc = QLocale::system();
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (loc != QLocale::C && osSeparatorValue)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QList<int> nKeys = numbers.keys();
|
|
|
|
|
QList<QString> nValues = numbers.values();
|
2014-05-30 10:32:40 +02:00
|
|
|
|
for (int i = 0; i < nKeys.size(); ++i)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QLocale loc = QLocale(QLocale::C);
|
2014-05-23 20:11:13 +02:00
|
|
|
|
bool ok = false;
|
2014-05-27 16:58:25 +02:00
|
|
|
|
qreal d = loc.toDouble(nValues.at(i), &ok);
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (ok == false)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
qDebug()<<"Can't convert to double token"<<nValues.at(i);
|
2014-05-23 20:11:13 +02:00
|
|
|
|
continue;
|
|
|
|
|
}
|
2014-06-16 19:18:36 +02:00
|
|
|
|
if (qFloor (d) < d)
|
2014-05-23 20:11:13 +02:00
|
|
|
|
{
|
2014-05-27 16:58:25 +02:00
|
|
|
|
QLocale loc = QLocale::system();
|
2014-05-23 20:11:13 +02:00
|
|
|
|
QString dStr = loc.toString(d);
|
2014-05-27 16:58:25 +02:00
|
|
|
|
newFormula.replace(nKeys.at(i), nValues.at(i).length(), dStr);
|
|
|
|
|
int bias = nValues.at(i).length() - dStr.length();
|
|
|
|
|
|
|
|
|
|
if (bias != 0)
|
|
|
|
|
{
|
|
|
|
|
CorrectionsPositions(nKeys.at(i), bias, tokens, numbers);
|
|
|
|
|
nKeys = numbers.keys();
|
|
|
|
|
nValues = numbers.values();
|
|
|
|
|
}
|
2014-05-23 20:11:13 +02:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return newFormula;
|
|
|
|
|
}
|
2014-07-08 12:59:50 +02:00
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QWidget *VApplication::getMainWindow() const
|
|
|
|
|
{
|
|
|
|
|
return mainWindow;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::setMainWindow(QWidget *value)
|
|
|
|
|
{
|
|
|
|
|
SCASSERT(value != nullptr)
|
|
|
|
|
mainWindow = value;
|
|
|
|
|
}
|
|
|
|
|
|
2014-07-08 13:26:13 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
bool VApplication::getOpeningPattern() const
|
|
|
|
|
{
|
|
|
|
|
return openingPattern;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::setOpeningPattern()
|
|
|
|
|
{
|
|
|
|
|
openingPattern = !openingPattern;
|
|
|
|
|
}
|
|
|
|
|
|
2014-07-10 11:36:46 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
/**
|
|
|
|
|
* @brief VApplication::OpenSettings get acsses to application settings.
|
|
|
|
|
*
|
|
|
|
|
* Because we can create object in constructor we open file separately.
|
|
|
|
|
*/
|
|
|
|
|
void VApplication::OpenSettings()
|
|
|
|
|
{
|
|
|
|
|
settings = new QSettings(QSettings::IniFormat, QSettings::UserScope, QApplication::organizationName(),
|
|
|
|
|
QApplication::applicationName(), this);
|
|
|
|
|
}
|
2014-07-08 13:26:13 +02:00
|
|
|
|
|
2014-07-10 11:36:46 +02:00
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
/**
|
|
|
|
|
* @brief VApplication::getSettings hide settings constructor.
|
|
|
|
|
* @return pointer to class for acssesing to settings in ini file.
|
|
|
|
|
*/
|
|
|
|
|
QSettings *VApplication::getSettings()
|
|
|
|
|
{
|
|
|
|
|
SCASSERT(settings != nullptr);
|
|
|
|
|
return settings;
|
|
|
|
|
}
|
2014-07-15 15:51:15 +02:00
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
VMainGraphicsScene *VApplication::getCurrentScene() const
|
|
|
|
|
{
|
|
|
|
|
SCASSERT(currentScene != nullptr);
|
|
|
|
|
return currentScene;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::setCurrentScene(VMainGraphicsScene *value)
|
|
|
|
|
{
|
|
|
|
|
currentScene = value;
|
|
|
|
|
}
|
2014-09-08 13:02:14 +02:00
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
void VApplication::setOverrideCursor(const QString &pixmapPath, int hotX, int hotY)
|
|
|
|
|
{
|
|
|
|
|
#ifndef QT_NO_CURSOR
|
|
|
|
|
QPixmap oldPixmap;
|
|
|
|
|
if (QCursor *oldCursor = QGuiApplication::overrideCursor())
|
|
|
|
|
{
|
|
|
|
|
oldPixmap = oldCursor->pixmap();
|
|
|
|
|
}
|
|
|
|
|
QPixmap newPixmap(pixmapPath);
|
|
|
|
|
|
|
|
|
|
QImage oldImage = oldPixmap.toImage();
|
|
|
|
|
QImage newImage = newPixmap.toImage();
|
|
|
|
|
|
|
|
|
|
if (oldImage != newImage )
|
|
|
|
|
{
|
|
|
|
|
QApplication::setOverrideCursor(QCursor(newPixmap, hotX, hotY));
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
2014-09-11 18:52:02 +02:00
|
|
|
|
void VApplication::restoreOverrideCursor(const QString &pixmapPath)
|
2014-09-08 13:02:14 +02:00
|
|
|
|
{
|
|
|
|
|
#ifndef QT_NO_CURSOR
|
|
|
|
|
QPixmap oldPixmap;
|
|
|
|
|
if (QCursor *oldCursor = QGuiApplication::overrideCursor())
|
|
|
|
|
{
|
|
|
|
|
oldPixmap = oldCursor->pixmap();
|
|
|
|
|
}
|
|
|
|
|
QPixmap newPixmap(pixmapPath);
|
|
|
|
|
|
|
|
|
|
QImage oldImage = oldPixmap.toImage();
|
|
|
|
|
QImage newImage = newPixmap.toImage();
|
|
|
|
|
|
|
|
|
|
if (oldImage == newImage )
|
|
|
|
|
{
|
|
|
|
|
QApplication::restoreOverrideCursor();
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
2014-09-09 15:11:50 +02:00
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QStringList VApplication::LabelLanguages()
|
|
|
|
|
{
|
2014-09-10 19:57:08 +02:00
|
|
|
|
QStringList list{"de", // German
|
|
|
|
|
"en", // English
|
|
|
|
|
"fr", // French
|
|
|
|
|
"ru", // Russian
|
|
|
|
|
"uk", // Ukrainian
|
|
|
|
|
"hr", // Croatian
|
|
|
|
|
"sr", // Serbian
|
2014-09-09 15:11:50 +02:00
|
|
|
|
"bs" // Bosnian
|
|
|
|
|
};
|
|
|
|
|
return list;
|
|
|
|
|
}
|
2014-09-18 11:30:33 +02:00
|
|
|
|
|
|
|
|
|
//---------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
QString VApplication::STDescription(const QString &id) const
|
|
|
|
|
{
|
|
|
|
|
if (stDescriptions.contains(id))
|
|
|
|
|
{
|
|
|
|
|
return stDescriptions.value(id).translate();
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
qWarning()<<"Unknown id number. Got"<<id;
|
|
|
|
|
}
|
|
|
|
|
return QString();
|
|
|
|
|
}
|