diff --git a/src/app/tape/share/resources/diagrams.qrc b/src/app/tape/share/resources/diagrams.qrc index a12f6afa4..0f814d09f 100644 --- a/src/app/tape/share/resources/diagrams.qrc +++ b/src/app/tape/share/resources/diagrams.qrc @@ -22,6 +22,7 @@ diagrams/Gp6.png diagrams/Gp7.png diagrams/Gp8.png + diagrams/Gp9.png diagrams/Hp1.png diagrams/Hp2.png diagrams/Hp3.png @@ -34,6 +35,7 @@ diagrams/Hp10.png diagrams/Hp11.png diagrams/Hp12.png + diagrams/Hp13.png diagrams/Ip1.png diagrams/Ip2.png diagrams/Ip3.png @@ -66,6 +68,7 @@ diagrams/Lp7.png diagrams/Lp8.png diagrams/Lp9.png + diagrams/Lp10.png diagrams/Mp1.png diagrams/Mp2.png diagrams/Mp3.png @@ -73,6 +76,7 @@ diagrams/Np2.png diagrams/Np3.png diagrams/Np4.png + diagrams/Np5.png diagrams/Op1.png diagrams/Op2.png diagrams/Op3.png diff --git a/src/app/tape/share/resources/diagrams/Ap2.png b/src/app/tape/share/resources/diagrams/Ap2.png index d39de94b0..99ecac5b6 100644 Binary files a/src/app/tape/share/resources/diagrams/Ap2.png and b/src/app/tape/share/resources/diagrams/Ap2.png differ diff --git a/src/app/tape/share/resources/diagrams/Gp9.png b/src/app/tape/share/resources/diagrams/Gp9.png new file mode 100644 index 000000000..e8a7da4eb Binary files /dev/null and b/src/app/tape/share/resources/diagrams/Gp9.png differ diff --git a/src/app/tape/share/resources/diagrams/Hp13.png b/src/app/tape/share/resources/diagrams/Hp13.png new file mode 100644 index 000000000..769106665 Binary files /dev/null and b/src/app/tape/share/resources/diagrams/Hp13.png differ diff --git a/src/app/tape/share/resources/diagrams/Lp10.png b/src/app/tape/share/resources/diagrams/Lp10.png new file mode 100644 index 000000000..b5dd8e802 Binary files /dev/null and b/src/app/tape/share/resources/diagrams/Lp10.png differ diff --git a/src/app/tape/share/resources/diagrams/Np5.png b/src/app/tape/share/resources/diagrams/Np5.png new file mode 100644 index 000000000..737e6bef5 Binary files /dev/null and b/src/app/tape/share/resources/diagrams/Np5.png differ diff --git a/src/app/tape/tape.pro b/src/app/tape/tape.pro index ce79f6976..be72682c4 100644 --- a/src/app/tape/tape.pro +++ b/src/app/tape/tape.pro @@ -286,6 +286,7 @@ DIAGRAMS += \ $${PWD}/share/resources/diagrams/Gp6.png \ $${PWD}/share/resources/diagrams/Gp7.png \ $${PWD}/share/resources/diagrams/Gp8.png \ + $${PWD}/share/resources/diagrams/Gp9.png \ $${PWD}/share/resources/diagrams/Hp1.png \ $${PWD}/share/resources/diagrams/Hp2.png \ $${PWD}/share/resources/diagrams/Hp3.png \ @@ -298,6 +299,7 @@ DIAGRAMS += \ $${PWD}/share/resources/diagrams/Hp10.png \ $${PWD}/share/resources/diagrams/Hp11.png \ $${PWD}/share/resources/diagrams/Hp12.png \ + $${PWD}/share/resources/diagrams/Hp13.png \ $${PWD}/share/resources/diagrams/Ip1.png \ $${PWD}/share/resources/diagrams/Ip2.png \ $${PWD}/share/resources/diagrams/Ip3.png \ @@ -330,6 +332,7 @@ DIAGRAMS += \ $${PWD}/share/resources/diagrams/Lp7.png \ $${PWD}/share/resources/diagrams/Lp8.png \ $${PWD}/share/resources/diagrams/Lp9.png \ + $${PWD}/share/resources/diagrams/Lp10.png \ $${PWD}/share/resources/diagrams/Mp1.png \ $${PWD}/share/resources/diagrams/Mp2.png \ $${PWD}/share/resources/diagrams/Mp3.png \ @@ -337,6 +340,7 @@ DIAGRAMS += \ $${PWD}/share/resources/diagrams/Np2.png \ $${PWD}/share/resources/diagrams/Np3.png \ $${PWD}/share/resources/diagrams/Np4.png \ + $${PWD}/share/resources/diagrams/Np5.png \ $${PWD}/share/resources/diagrams/Op1.png \ $${PWD}/share/resources/diagrams/Op2.png \ $${PWD}/share/resources/diagrams/Op3.png \ diff --git a/src/libs/ifc/schema.qrc b/src/libs/ifc/schema.qrc index de7259a73..6bec8b207 100644 --- a/src/libs/ifc/schema.qrc +++ b/src/libs/ifc/schema.qrc @@ -6,12 +6,15 @@ schema/pattern/v0.1.3.xsd schema/pattern/v0.1.4.xsd schema/pattern/v0.2.0.xsd + schema/pattern/v0.2.1.xsd schema/standard_measurements/v0.3.0.xsd schema/standard_measurements/v0.4.0.xsd schema/standard_measurements/v0.4.1.xsd + schema/standard_measurements/v0.4.2.xsd schema/individual_measurements/v0.2.0.xsd schema/individual_measurements/v0.3.0.xsd schema/individual_measurements/v0.3.1.xsd schema/individual_measurements/v0.3.2.xsd + schema/individual_measurements/v0.3.3.xsd diff --git a/src/libs/ifc/schema/individual_measurements/v0.3.3.xsd b/src/libs/ifc/schema/individual_measurements/v0.3.3.xsd new file mode 100644 index 000000000..a6a241e53 --- /dev/null +++ b/src/libs/ifc/schema/individual_measurements/v0.3.3.xsd @@ -0,0 +1,72 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/libs/ifc/schema/pattern/v0.2.1.xsd b/src/libs/ifc/schema/pattern/v0.2.1.xsd new file mode 100644 index 000000000..65456be2a --- /dev/null +++ b/src/libs/ifc/schema/pattern/v0.2.1.xsd @@ -0,0 +1,329 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/libs/ifc/schema/standard_measurements/v0.4.2.xsd b/src/libs/ifc/schema/standard_measurements/v0.4.2.xsd new file mode 100644 index 000000000..788adcbb1 --- /dev/null +++ b/src/libs/ifc/schema/standard_measurements/v0.4.2.xsd @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/libs/ifc/xml/vabstractmconverter.cpp b/src/libs/ifc/xml/vabstractmconverter.cpp index bb9df7c15..268e4b2d4 100644 --- a/src/libs/ifc/xml/vabstractmconverter.cpp +++ b/src/libs/ifc/xml/vabstractmconverter.cpp @@ -94,10 +94,8 @@ QMultiMap VAbstractMConverter::OldNamesToNewNames_InV0_3_0() names.insert(QStringLiteral("lowbust_circ"), QStringLiteral("under_bust_girth")); names.insert(QStringLiteral("waist_circ"), QStringLiteral("waist_girth")); names.insert(QStringLiteral("highhip_circ"), QStringLiteral("high_hip_girth")); - - name = QStringLiteral("hip_circ"); - names.insert(name, QStringLiteral("hips_excluding_protruding_abdomen")); - names.insert(name, QStringLiteral("hip_girth")); + names.insert(QStringLiteral("hip_circ"), QStringLiteral("hips_excluding_protruding_abdomen")); + names.insert(QStringLiteral("hip_circ_with_abdomen"), QStringLiteral("hip_girth")); name = QStringLiteral("neck_arc_f"); names.insert(name, QStringLiteral("half_girth_neck")); @@ -129,16 +127,13 @@ QMultiMap VAbstractMConverter::OldNamesToNewNames_InV0_3_0() QStringLiteral("half_girth_hips_considering_protruding_abdomen")); names.insert(QStringLiteral("body_armfold_circ"), QStringLiteral("shoulder_girth")); names.insert(QStringLiteral("body_torso_circ"), QStringLiteral("trunk_length")); - - name = QStringLiteral("neck_front_to_waist_f"); - names.insert(name, QStringLiteral("front_waist_length")); - names.insert(name, QStringLiteral("center_front_waist_length")); - + names.insert(QStringLiteral("neck_front_to_waist_f"), QStringLiteral("front_waist_length")); + names.insert(QStringLiteral("neck_front_to_waist_flat_f"), QStringLiteral("center_front_waist_length")); names.insert(QStringLiteral("armpit_to_waist_side"), QStringLiteral("side_waist_length")); + names.insert(QStringLiteral("neck_side_to_waist_b"), QStringLiteral("waist_to_neck_side")); name = QStringLiteral("neck_side_to_waist_f"); names.insert(name, QStringLiteral("neck_to_front_waist_line")); - names.insert(name, QStringLiteral("waist_to_neck_side")); names.insert(name, QStringLiteral("front_shoulder_to_waist_length")); names.insert(QStringLiteral("neck_side_to_waist_b"), QStringLiteral("back_shoulder_to_waist_length")); @@ -159,10 +154,8 @@ QMultiMap VAbstractMConverter::OldNamesToNewNames_InV0_3_0() names.insert(QStringLiteral("shoulder_length"), QStringLiteral("shoulder_length")); names.insert(QStringLiteral("shoulder_tip_to_shoulder_tip_f"), QStringLiteral("across_front_shoulder_width")); names.insert(QStringLiteral("across_chest_f"), QStringLiteral("upper_front_chest_width")); - - name = QStringLiteral("armfold_to_armfold_f"); - names.insert(name, QStringLiteral("chest_width")); - names.insert(name, QStringLiteral("front_chest_width")); + names.insert(QStringLiteral("across_chest_f"), QStringLiteral("chest_width")); + names.insert(QStringLiteral("armfold_to_armfold_f"), QStringLiteral("front_chest_width")); name = QStringLiteral("shoulder_tip_to_shoulder_tip_b"); names.insert(name, QStringLiteral("arc_behind_shoulder_girdle")); @@ -199,11 +192,8 @@ QMultiMap VAbstractMConverter::OldNamesToNewNames_InV0_3_0() names.insert(QStringLiteral("armscye_circ"), QStringLiteral("armscye_girth")); names.insert(QStringLiteral("armscye_width"), QStringLiteral("anteroposterior_diameter_hands")); names.insert(QStringLiteral("arm_neck_side_to_finger_tip"), QStringLiteral("neck_to_third_finger")); - - name = QStringLiteral("arm_neck_side_to_wrist"); - names.insert(name, QStringLiteral("neck_to_radial_point")); - names.insert(name, QStringLiteral("shoulder_and_arm_length")); - + names.insert(QStringLiteral("arm_neck_side_to_outer_elbow"), QStringLiteral("neck_to_radial_point")); + names.insert(QStringLiteral("arm_neck_side_to_wrist"), QStringLiteral("shoulder_and_arm_length")); names.insert(QStringLiteral("leg_crotch_to_floor"), QStringLiteral("crotch_height")); names.insert(QStringLiteral("leg_waist_side_to_floor"), QStringLiteral("side_waist_to_floor")); names.insert(QStringLiteral("leg_waist_side_to_knee"), QStringLiteral("waist_to_knee")); @@ -218,9 +208,8 @@ QMultiMap VAbstractMConverter::OldNamesToNewNames_InV0_3_0() names.insert(name, QStringLiteral("arc_through_groin_area")); names.insert(name, QStringLiteral("crotch_length")); - name = QStringLiteral("rise_length_side"); - names.insert(name, QStringLiteral("waist_to_plane_seat")); - names.insert(name, QStringLiteral("rise_height")); + names.insert(QStringLiteral("rise_length_side_sitting"), QStringLiteral("waist_to_plane_seat")); + names.insert(QStringLiteral("rise_length_diag"), QStringLiteral("rise_height")); name = QStringLiteral("hand_length"); names.insert(name, QStringLiteral("hand_vertical_diameter")); @@ -239,6 +228,21 @@ QMultiMap VAbstractMConverter::OldNamesToNewNames_InV0_3_0() names.insert(QStringLiteral("highbust_b_over_shoulder_to_highbust_f"), QStringLiteral("strap_length")); names.insert(QStringLiteral("armscye_arc"), QStringLiteral("arc_through_shoulder_joint")); names.insert(QStringLiteral("head_circ"), QStringLiteral("head_girth")); + names.insert(QStringLiteral("arm_elbow_circ"), QStringLiteral("elbow_girth")); + names.insert(QStringLiteral("height_gluteal_fold"), QStringLiteral("height_under_buttock_folds")); + names.insert(QStringLiteral("neck_back_to_highbust_b"), QStringLiteral("scye_depth")); + names.insert(QStringLiteral("across_back_to_waist_b"), QStringLiteral("back_waist_to_upper_chest")); + + return names; +} + +//--------------------------------------------------------------------------------------------------------------------- +QMap VAbstractMConverter::OldNamesToNewNames_InV0_3_3() +{ + // new name, old name + QMap names; + + names.insert(QStringLiteral("rise_length_side_sitting"), QStringLiteral("rise_length_side")); return names; } diff --git a/src/libs/ifc/xml/vabstractmconverter.h b/src/libs/ifc/xml/vabstractmconverter.h index 3f73b6c46..24335f863 100644 --- a/src/libs/ifc/xml/vabstractmconverter.h +++ b/src/libs/ifc/xml/vabstractmconverter.h @@ -40,6 +40,7 @@ public: protected: void AddRootComment(); static QMultiMap OldNamesToNewNames_InV0_3_0(); + static QMap OldNamesToNewNames_InV0_3_3(); private: Q_DISABLE_COPY(VAbstractMConverter) diff --git a/src/libs/ifc/xml/vpatternconverter.cpp b/src/libs/ifc/xml/vpatternconverter.cpp index 258727f88..e75f854d0 100644 --- a/src/libs/ifc/xml/vpatternconverter.cpp +++ b/src/libs/ifc/xml/vpatternconverter.cpp @@ -43,8 +43,8 @@ */ const QString VPatternConverter::PatternMinVerStr = QStringLiteral("0.1.0"); -const QString VPatternConverter::PatternMaxVerStr = QStringLiteral("0.2.0"); -const QString VPatternConverter::CurrentSchema = QStringLiteral("://schema/pattern/v0.2.0.xsd"); +const QString VPatternConverter::PatternMaxVerStr = QStringLiteral("0.2.1"); +const QString VPatternConverter::CurrentSchema = QStringLiteral("://schema/pattern/v0.2.1.xsd"); //--------------------------------------------------------------------------------------------------------------------- VPatternConverter::VPatternConverter(const QString &fileName) @@ -100,6 +100,8 @@ QString VPatternConverter::XSDSchema(int ver) const case (0x000104): return QStringLiteral("://schema/pattern/v0.1.4.xsd"); case (0x000200): + return QStringLiteral("://schema/pattern/v0.2.0.xsd"); + case (0x000201): return CurrentSchema; default: { @@ -152,6 +154,13 @@ void VPatternConverter::ApplyPatches() V_FALLTHROUGH } case (0x000200): + { + ToV0_2_1(); + const QString schema = XSDSchema(0x000201); + ValidateXML(schema, fileName); + V_FALLTHROUGH + } + case (0x000201): break; default: break; @@ -215,6 +224,14 @@ void VPatternConverter::ToV0_2_0() Save(); } +//--------------------------------------------------------------------------------------------------------------------- +void VPatternConverter::ToV0_2_1() +{ + SetVersion(QStringLiteral("0.2.1")); + ConvertMeasurementsToV0_2_1(); + Save(); +} + //--------------------------------------------------------------------------------------------------------------------- void VPatternConverter::TagUnitToV0_2_0() { @@ -665,6 +682,17 @@ void VPatternConverter::TagMeasurementsToV0_2_0() ms.appendChild(newNodeText); } +//--------------------------------------------------------------------------------------------------------------------- +void VPatternConverter::ConvertMeasurementsToV0_2_1() +{ + const QMap names = OldNamesToNewNames_InV0_2_1(); + + // Structure did not change. We can use the same code. + ConvertPointExpressionsToV0_2_0(names); + ConvertArcExpressionsToV0_2_0(names); + ConvertPathPointExpressionsToV0_2_0(names); +} + //--------------------------------------------------------------------------------------------------------------------- QString VPatternConverter::MUnitV0_1_4() const { @@ -792,10 +820,8 @@ QMap VPatternConverter::OldNamesToNewNames_InV0_2_0() names.insert(QStringLiteral("under_bust_girth"), QStringLiteral("lowbust_circ")); names.insert(QStringLiteral("waist_girth"), QStringLiteral("waist_circ")); names.insert(QStringLiteral("high_hip_girth"), QStringLiteral("highhip_circ")); - - name = QStringLiteral("hip_circ"); - names.insert(QStringLiteral("hips_excluding_protruding_abdomen"), name); - names.insert(QStringLiteral("hip_girth"), name); + names.insert(QStringLiteral("hips_excluding_protruding_abdomen"), QStringLiteral("hip_circ")); + names.insert(QStringLiteral("hip_girth"), QStringLiteral("hip_circ_with_abdomen")); name = QStringLiteral("neck_arc_f"); names.insert(QStringLiteral("half_girth_neck"), name); @@ -825,19 +851,15 @@ QMap VPatternConverter::OldNamesToNewNames_InV0_2_0() names.insert(QStringLiteral("back_hip_arc"), QStringLiteral("hip_arc_b")); names.insert(QStringLiteral("half_girth_hips_considering_protruding_abdomen"), QStringLiteral("hip_with_abdomen_arc_f")); - names.insert(QStringLiteral("shoulder_girth"), QStringLiteral("body_armfold_circ")); names.insert(QStringLiteral("trunk_length"), QStringLiteral("body_torso_circ")); - - name = QStringLiteral("neck_front_to_waist_f"); - names.insert(QStringLiteral("front_waist_length"), name); - names.insert(QStringLiteral("center_front_waist_length"), name); - + names.insert(QStringLiteral("front_waist_length"), QStringLiteral("neck_front_to_waist_f")); + names.insert(QStringLiteral("center_front_waist_length"), QStringLiteral("neck_front_to_waist_flat_f")); names.insert(QStringLiteral("side_waist_length"), QStringLiteral("armpit_to_waist_side")); + names.insert(QStringLiteral("waist_to_neck_side"), QStringLiteral("neck_side_to_waist_b")); name = QStringLiteral("neck_side_to_waist_f"); names.insert(QStringLiteral("neck_to_front_waist_line"), name); - names.insert(QStringLiteral("waist_to_neck_side"), name); names.insert(QStringLiteral("front_shoulder_to_waist_length"), name); names.insert(QStringLiteral("back_shoulder_to_waist_length"), QStringLiteral("neck_side_to_waist_b")); @@ -857,10 +879,8 @@ QMap VPatternConverter::OldNamesToNewNames_InV0_2_0() names.insert(QStringLiteral("shoulder_drop"), QStringLiteral("shoulder_slope_neck_side_length")); names.insert(QStringLiteral("across_front_shoulder_width"), QStringLiteral("shoulder_tip_to_shoulder_tip_f")); names.insert(QStringLiteral("upper_front_chest_width"), QStringLiteral("across_chest_f")); - - name = QStringLiteral("armfold_to_armfold_f"); - names.insert(QStringLiteral("chest_width"), name); - names.insert(QStringLiteral("front_chest_width"), name); + names.insert(QStringLiteral("chest_width"), QStringLiteral("across_chest_f")); + names.insert(QStringLiteral("front_chest_width"), QStringLiteral("armfold_to_armfold_f")); name = QStringLiteral("shoulder_tip_to_shoulder_tip_b"); names.insert(QStringLiteral("arc_behind_shoulder_girdle"), name); @@ -897,11 +917,8 @@ QMap VPatternConverter::OldNamesToNewNames_InV0_2_0() names.insert(QStringLiteral("armscye_girth"), QStringLiteral("armscye_circ")); names.insert(QStringLiteral("anteroposterior_diameter_hands"), QStringLiteral("armscye_width")); names.insert(QStringLiteral("neck_to_third_finger"), QStringLiteral("arm_neck_side_to_finger_tip")); - - name = QStringLiteral("arm_neck_side_to_wrist"); - names.insert(QStringLiteral("neck_to_radial_point"), name); - names.insert(QStringLiteral("shoulder_and_arm_length"), name); - + names.insert(QStringLiteral("neck_to_radial_point"), QStringLiteral("arm_neck_side_to_outer_elbow")); + names.insert(QStringLiteral("shoulder_and_arm_length"), QStringLiteral("arm_neck_side_to_wrist")); names.insert(QStringLiteral("crotch_height"), QStringLiteral("leg_crotch_to_floor")); names.insert(QStringLiteral("side_waist_to_floor"), QStringLiteral("leg_waist_side_to_floor")); names.insert(QStringLiteral("waist_to_knee"), QStringLiteral("leg_waist_side_to_knee")); @@ -912,11 +929,8 @@ QMap VPatternConverter::OldNamesToNewNames_InV0_2_0() names.insert(QStringLiteral("ankle_girth"), QStringLiteral("leg_ankle_circ")); names.insert(QStringLiteral("girth_knee_flexed_feet"), QStringLiteral("leg_knee_circ_bent")); names.insert(QStringLiteral("arc_through_groin_area"), QStringLiteral("crotch_length")); - - name = QStringLiteral("rise_length_side"); - names.insert(QStringLiteral("waist_to_plane_seat"), name); - names.insert(QStringLiteral("rise_height"), name); - + names.insert(QStringLiteral("waist_to_plane_seat"), QStringLiteral("rise_length_side_sitting")); + names.insert(QStringLiteral("rise_height"), QStringLiteral("rise_length_diag")); names.insert(QStringLiteral("hand_vertical_diameter"), QStringLiteral("hand_length")); names.insert(QStringLiteral("hand_width"), QStringLiteral("hand_palm_width")); names.insert(QStringLiteral("hand_girth"), QStringLiteral("hand_circ")); @@ -929,6 +943,21 @@ QMap VPatternConverter::OldNamesToNewNames_InV0_2_0() names.insert(QStringLiteral("strap_length"), QStringLiteral("highbust_b_over_shoulder_to_highbust_f")); names.insert(QStringLiteral("arc_through_shoulder_joint"), QStringLiteral("armscye_arc")); names.insert(QStringLiteral("head_girth"), QStringLiteral("head_circ")); + names.insert(QStringLiteral("elbow_girth"), QStringLiteral("arm_elbow_circ")); + names.insert(QStringLiteral("height_under_buttock_folds"), QStringLiteral("height_gluteal_fold")); + names.insert(QStringLiteral("scye_depth"), QStringLiteral("neck_back_to_highbust_b")); + names.insert(QStringLiteral("back_waist_to_upper_chest"), QStringLiteral("across_back_to_waist_b")); + + return names; +} + +//--------------------------------------------------------------------------------------------------------------------- +QMap VPatternConverter::OldNamesToNewNames_InV0_2_1() +{ + // old name, new name + QMap names; + + names.insert(QStringLiteral("rise_length_side"), QStringLiteral("rise_length_side_sitting")); return names; } diff --git a/src/libs/ifc/xml/vpatternconverter.h b/src/libs/ifc/xml/vpatternconverter.h index 5da3b07e1..b62ef6b5b 100644 --- a/src/libs/ifc/xml/vpatternconverter.h +++ b/src/libs/ifc/xml/vpatternconverter.h @@ -60,12 +60,15 @@ private: void ToV0_1_3(); void ToV0_1_4(); void ToV0_2_0(); + void ToV0_2_1(); void TagUnitToV0_2_0(); void TagIncrementToV0_2_0(); void ConvertMeasurementsToV0_2_0(); void TagMeasurementsToV0_2_0(); + void ConvertMeasurementsToV0_2_1(); + QSet FixIncrementsToV0_2_0(); QString FixIncrementInFormulaToV0_2_0(const QString &formula, const QSet &names); void FixPointExpressionsToV0_2_0(const QSet &names); @@ -83,6 +86,7 @@ private: QStringList ListPathPointExpressionsV0_1_4() const; static QMap OldNamesToNewNames_InV0_2_0(); + static QMap OldNamesToNewNames_InV0_2_1(); }; #endif // VPATTERNCONVERTER_H diff --git a/src/libs/ifc/xml/vvitconverter.cpp b/src/libs/ifc/xml/vvitconverter.cpp index bdd3eac36..b518967aa 100644 --- a/src/libs/ifc/xml/vvitconverter.cpp +++ b/src/libs/ifc/xml/vvitconverter.cpp @@ -40,8 +40,8 @@ */ const QString VVITConverter::MeasurementMinVerStr = QStringLiteral("0.2.0"); -const QString VVITConverter::MeasurementMaxVerStr = QStringLiteral("0.3.2"); -const QString VVITConverter::CurrentSchema = QStringLiteral("://schema/individual_measurements/v0.3.2.xsd"); +const QString VVITConverter::MeasurementMaxVerStr = QStringLiteral("0.3.3"); +const QString VVITConverter::CurrentSchema = QStringLiteral("://schema/individual_measurements/v0.3.3.xsd"); //--------------------------------------------------------------------------------------------------------------------- VVITConverter::VVITConverter(const QString &fileName) @@ -93,6 +93,8 @@ QString VVITConverter::XSDSchema(int ver) const case (0x000301): return QStringLiteral("://schema/individual_measurements/v0.3.1.xsd"); case (0x000302): + return QStringLiteral("://schema/individual_measurements/v0.3.2.xsd"); + case (0x000303): return CurrentSchema; default: { @@ -131,6 +133,13 @@ void VVITConverter::ApplyPatches() V_FALLTHROUGH } case (0x000302): + { + ToV0_3_3(); + const QString schema = XSDSchema(0x000303); + ValidateXML(schema, fileName); + V_FALLTHROUGH + } + case (0x000303): break; default: break; @@ -257,6 +266,34 @@ void VVITConverter::PM_SystemV0_3_2() parent.insertBefore(pm_system, personal); } +//--------------------------------------------------------------------------------------------------------------------- +void VVITConverter::ConvertMeasurementsToV0_3_3() +{ + const QMap names = OldNamesToNewNames_InV0_3_3(); + auto i = names.constBegin(); + while (i != names.constEnd()) + { + const QDomNodeList nodeList = this->elementsByTagName(QStringLiteral("m")); + if (nodeList.isEmpty()) + { + continue; + } + + for (int ii = 0; ii < nodeList.size(); ++ii) + { + const QString attrName = QStringLiteral("name"); + QDomElement element = nodeList.at(ii).toElement(); + const QString name = GetParametrString(element, attrName); + if (name == i.value()) + { + SetAttribute(element, attrName, i.key()); + } + } + + ++i; + } +} + //--------------------------------------------------------------------------------------------------------------------- void VVITConverter::ToV0_3_0() { @@ -282,3 +319,11 @@ void VVITConverter::ToV0_3_2() PM_SystemV0_3_2(); Save(); } + +//--------------------------------------------------------------------------------------------------------------------- +void VVITConverter::ToV0_3_3() +{ + SetVersion(QStringLiteral("0.3.3")); + ConvertMeasurementsToV0_3_3(); + Save(); +} diff --git a/src/libs/ifc/xml/vvitconverter.h b/src/libs/ifc/xml/vvitconverter.h index 10c808fee..b2a265d01 100644 --- a/src/libs/ifc/xml/vvitconverter.h +++ b/src/libs/ifc/xml/vvitconverter.h @@ -61,10 +61,12 @@ private: QDomElement AddMV0_3_0(const QString &name, qreal value); void GenderV0_3_1(); void PM_SystemV0_3_2(); + void ConvertMeasurementsToV0_3_3(); void ToV0_3_0(); void ToV0_3_1(); void ToV0_3_2(); + void ToV0_3_3(); }; #endif // VVITCONVERTER_H diff --git a/src/libs/ifc/xml/vvstconverter.cpp b/src/libs/ifc/xml/vvstconverter.cpp index ea6c2d4ba..0a928e054 100644 --- a/src/libs/ifc/xml/vvstconverter.cpp +++ b/src/libs/ifc/xml/vvstconverter.cpp @@ -40,8 +40,8 @@ */ const QString VVSTConverter::MeasurementMinVerStr = QStringLiteral("0.3.0"); -const QString VVSTConverter::MeasurementMaxVerStr = QStringLiteral("0.4.1"); -const QString VVSTConverter::CurrentSchema = QStringLiteral("://schema/standard_measurements/v0.4.1.xsd"); +const QString VVSTConverter::MeasurementMaxVerStr = QStringLiteral("0.4.2"); +const QString VVSTConverter::CurrentSchema = QStringLiteral("://schema/standard_measurements/v0.4.2.xsd"); //--------------------------------------------------------------------------------------------------------------------- VVSTConverter::VVSTConverter(const QString &fileName) @@ -91,6 +91,8 @@ QString VVSTConverter::XSDSchema(int ver) const case (0x000400): return QStringLiteral("://schema/standard_measurements/v0.4.0.xsd"); case (0x000401): + return QStringLiteral("://schema/standard_measurements/v0.4.1.xsd"); + case (0x000402): return CurrentSchema; default: { @@ -122,6 +124,13 @@ void VVSTConverter::ApplyPatches() V_FALLTHROUGH } case (0x000401): + { + ToV0_4_2(); + const QString schema = XSDSchema(0x000402); + ValidateXML(schema, fileName); + V_FALLTHROUGH + } + case (0x000402): break; default: break; @@ -263,6 +272,34 @@ void VVSTConverter::PM_SystemV0_4_1() parent.insertBefore(pm_system, personal); } +//--------------------------------------------------------------------------------------------------------------------- +void VVSTConverter::ConvertMeasurementsToV0_4_2() +{ + const QMap names = OldNamesToNewNames_InV0_3_3(); + auto i = names.constBegin(); + while (i != names.constEnd()) + { + const QDomNodeList nodeList = this->elementsByTagName(QStringLiteral("m")); + if (nodeList.isEmpty()) + { + continue; + } + + for (int ii = 0; ii < nodeList.size(); ++ii) + { + const QString attrName = QStringLiteral("name"); + QDomElement element = nodeList.at(ii).toElement(); + const QString name = GetParametrString(element, attrName); + if (name == i.value()) + { + SetAttribute(element, attrName, i.key()); + } + } + + ++i; + } +} + //--------------------------------------------------------------------------------------------------------------------- void VVSTConverter::ToV0_4_0() { @@ -281,3 +318,11 @@ void VVSTConverter::ToV0_4_1() PM_SystemV0_4_1(); Save(); } + +//--------------------------------------------------------------------------------------------------------------------- +void VVSTConverter::ToV0_4_2() +{ + SetVersion(QStringLiteral("0.4.2")); + ConvertMeasurementsToV0_4_2(); + Save(); +} diff --git a/src/libs/ifc/xml/vvstconverter.h b/src/libs/ifc/xml/vvstconverter.h index f124ff3fb..bdaa74d1b 100644 --- a/src/libs/ifc/xml/vvstconverter.h +++ b/src/libs/ifc/xml/vvstconverter.h @@ -60,9 +60,11 @@ private: void ConvertMeasurementsToV0_4_0(); QDomElement AddMV0_4_0(const QString &name, qreal value, qreal sizeIncrease, qreal heightIncrease); void PM_SystemV0_4_1(); + void ConvertMeasurementsToV0_4_2(); void ToV0_4_0(); void ToV0_4_1(); + void ToV0_4_2(); }; #endif // VMEASUREMENTCONVERTER_H diff --git a/src/libs/vmisc/def.cpp b/src/libs/vmisc/def.cpp index 57a350dbd..b7886a359 100644 --- a/src/libs/vmisc/def.cpp +++ b/src/libs/vmisc/def.cpp @@ -135,6 +135,7 @@ const QString hipWithAbdomenArcF_M = QStringLiteral("hip_with_abdomen_arc_f"); / const QString bodyArmfoldCirc_M = QStringLiteral("body_armfold_circ"); // G43 const QString bodyBustCirc_M = QStringLiteral("body_bust_circ"); // G44 const QString bodyTorsoCirc_M = QStringLiteral("body_torso_circ"); // G45 +const QString hipCircWithAbdomen_M = QStringLiteral("hip_circ_with_abdomen"); // G46 // H const QString neckFrontToWaistF_M = QStringLiteral("neck_front_to_waist_f"); // H01 const QString neckFrontToWaistFlatF_M = QStringLiteral("neck_front_to_waist_flat_f"); // H02 @@ -176,6 +177,8 @@ const QString shoulderSlopeNeckSideLength_M = QStringLiteral("shoulder_slope_n const QString shoulderSlopeNeckBackAngle_M = QStringLiteral("shoulder_slope_neck_back_angle"); // H38 const QString shoulderSlopeNeckBackHeight_M = QStringLiteral("shoulder_slope_neck_back_height"); // H39 const QString shoulderSlopeShoulderTipAngle_M = QStringLiteral("shoulder_slope_shoulder_tip_angle"); // H40 +const QString neckBackToAcrossBack_M = QStringLiteral("neck_back_to_across_back"); // H41 +const QString acrossBackToWaistB_M = QStringLiteral("across_back_to_waist_b"); // H42 // I const QString shoulderLength_M = QStringLiteral("shoulder_length"); // I01 const QString shoulderTipToShoulderTipF_M = QStringLiteral("shoulder_tip_to_shoulder_tip_f"); // I02 @@ -237,6 +240,7 @@ const QString armNeckSideToFingerTip_M = QStringLiteral("arm_neck_side_to_f const QString armscyeCirc_M = QStringLiteral("armscye_circ"); // L19 const QString armscyeLength_M = QStringLiteral("armscye_length"); // L20 const QString armscyeWidth_M = QStringLiteral("armscye_width"); // L21 +const QString armNeckSideToOuterElbow_M = QStringLiteral("arm_neck_side_to_outer_elbow"); // L22 // M const QString legCrotchToFloor_M = QStringLiteral("leg_crotch_to_floor"); // M01 const QString legWaistSideToFloor_M = QStringLiteral("leg_waist_side_to_floor"); // M02 @@ -253,13 +257,14 @@ const QString legCrotchToAnkle_M = QStringLiteral("leg_crotch_to_ankle"); const QString legWaistSideToAnkle_M = QStringLiteral("leg_waist_side_to_ankle"); // M13 const QString legWaistSideToKnee_M = QStringLiteral("leg_waist_side_to_knee"); // M14 // N -const QString crotchLength_M = QStringLiteral("crotch_length"); // N01 -const QString crotchLengthB_M = QStringLiteral("crotch_length_b"); // N02 -const QString crotchLengthF_M = QStringLiteral("crotch_length_f"); // N03 -const QString riseLengthSide_M = QStringLiteral("rise_length_side"); // N04 -const QString riseLengthDiag_M = QStringLiteral("rise_length_diag"); // N05 -const QString riseLengthB_M = QStringLiteral("rise_length_b"); // N06 -const QString riseLengthF_M = QStringLiteral("rise_length_f"); // N07 +const QString crotchLength_M = QStringLiteral("crotch_length"); // N01 +const QString crotchLengthB_M = QStringLiteral("crotch_length_b"); // N02 +const QString crotchLengthF_M = QStringLiteral("crotch_length_f"); // N03 +const QString riseLengthSideSitting_M = QStringLiteral("rise_length_side_sitting"); // N04 +const QString riseLengthDiag_M = QStringLiteral("rise_length_diag"); // N05 +const QString riseLengthB_M = QStringLiteral("rise_length_b"); // N06 +const QString riseLengthF_M = QStringLiteral("rise_length_f"); // N07 +const QString riseLengthSide_M = QStringLiteral("rise_length_side"); // N08 // O const QString neckBackToWaistFront_M = QStringLiteral("neck_back_to_waist_front"); // O01 const QString waistToWaistHalter_M = QStringLiteral("waist_to_waist_halter"); // O02 @@ -662,51 +667,52 @@ QStringList ListGroupF() //--------------------------------------------------------------------------------------------------------------------- QStringList ListGroupG() { - const QStringList list = QStringList() << neckMidCirc_M // G01 - << neckCirc_M // G02 - << highbustCirc_M // G03 - << bustCirc_M // G04 - << lowbustCirc_M // G05 - << ribCirc_M // G06 - << waistCirc_M // G07 - << highhipCirc_M // G08 - << hipCirc_M // G09 - << neckArcF_M // G10 - << highbustArcF_M // G11 - << bustArcF_M // G12 - << lowbustArcF_M // G13 - << ribArcF_M // G14 - << waistArcF_M // G15 - << highhipArcF_M // G16 - << hipArcF_M // G17 - << neckArcHalfF_M // G18 - << highbustArcHalfF_M // G19 - << bustArcHalfF_M // G20 - << lowbustArcHalfF_M // G21 - << ribArcHalfF_M // G22 - << waistArcHalfF_M // G23 - << highhipArcHalfF_M // G24 - << hipArcHalfF_M // G25 - << neckArcB_M // G26 - << highbustArcB_M // G27 - << bustArcB_M // G28 - << lowbustArcB_M // G29 - << ribArcB_M // G30 - << waistArcB_M // G31 - << highhipArcB_M // G32 - << hipArcB_M // G33 - << neckArcHalfB_M // G34 - << highbustArcHalfB_M // G35 - << bustArcHalfB_M // G36 - << lowbustArcHalfB_M // G37 - << ribArcHalfB_M // G38 - << waistArcHalfB_M // G39 - << highhipArcHalfB_M // G40 - << hipArcHalfB_M // G41 - << hipWithAbdomenArcF_M // G42 - << bodyArmfoldCirc_M // G43 - << bodyBustCirc_M // G44 - << bodyTorsoCirc_M; // G45 + const QStringList list = QStringList() << neckMidCirc_M // G01 + << neckCirc_M // G02 + << highbustCirc_M // G03 + << bustCirc_M // G04 + << lowbustCirc_M // G05 + << ribCirc_M // G06 + << waistCirc_M // G07 + << highhipCirc_M // G08 + << hipCirc_M // G09 + << neckArcF_M // G10 + << highbustArcF_M // G11 + << bustArcF_M // G12 + << lowbustArcF_M // G13 + << ribArcF_M // G14 + << waistArcF_M // G15 + << highhipArcF_M // G16 + << hipArcF_M // G17 + << neckArcHalfF_M // G18 + << highbustArcHalfF_M // G19 + << bustArcHalfF_M // G20 + << lowbustArcHalfF_M // G21 + << ribArcHalfF_M // G22 + << waistArcHalfF_M // G23 + << highhipArcHalfF_M // G24 + << hipArcHalfF_M // G25 + << neckArcB_M // G26 + << highbustArcB_M // G27 + << bustArcB_M // G28 + << lowbustArcB_M // G29 + << ribArcB_M // G30 + << waistArcB_M // G31 + << highhipArcB_M // G32 + << hipArcB_M // G33 + << neckArcHalfB_M // G34 + << highbustArcHalfB_M // G35 + << bustArcHalfB_M // G36 + << lowbustArcHalfB_M // G37 + << ribArcHalfB_M // G38 + << waistArcHalfB_M // G39 + << highhipArcHalfB_M // G40 + << hipArcHalfB_M // G41 + << hipWithAbdomenArcF_M // G42 + << bodyArmfoldCirc_M // G43 + << bodyBustCirc_M // G44 + << bodyTorsoCirc_M // G45 + << hipCircWithAbdomen_M; // G46 return list; } @@ -753,7 +759,9 @@ QStringList ListGroupH() << shoulderSlopeNeckSideLength_M // H37 << shoulderSlopeNeckBackAngle_M // H38 << shoulderSlopeNeckBackHeight_M // H39 - << shoulderSlopeShoulderTipAngle_M; // H40 + << shoulderSlopeShoulderTipAngle_M // H40 + << neckBackToAcrossBack_M // H41 + << acrossBackToWaistB_M; // H42 return list; } @@ -838,7 +846,8 @@ QStringList ListGroupL() << armNeckSideToFingerTip_M // L18 << armscyeCirc_M // L19 << armscyeLength_M // L20 - << armscyeWidth_M; // L21 + << armscyeWidth_M // L21 + << armNeckSideToOuterElbow_M; // L22 return list; } @@ -867,13 +876,14 @@ QStringList ListGroupM() //--------------------------------------------------------------------------------------------------------------------- QStringList ListGroupN() { - const QStringList list = QStringList() << crotchLength_M // N01 - << crotchLengthB_M // N02 - << crotchLengthF_M // N03 - << riseLengthSide_M // N04 - << riseLengthDiag_M // N05 - << riseLengthB_M // N06 - << riseLengthF_M; // N07 + const QStringList list = QStringList() << crotchLength_M // N01 + << crotchLengthB_M // N02 + << crotchLengthF_M // N03 + << riseLengthSideSitting_M // N04 + << riseLengthDiag_M // N05 + << riseLengthB_M // N06 + << riseLengthF_M // N07 + << riseLengthSide_M; // N08 return list; } @@ -1302,6 +1312,8 @@ QString MapDiagrams(const QString &number) return QStringLiteral("Gp7"); case 44: // G45 return QStringLiteral("Gp8"); + case 45: // G46 + return QStringLiteral("Gp9"); default: break; } @@ -1389,6 +1401,10 @@ QString MapDiagrams(const QString &number) return QStringLiteral("Hp11"); case 39: // H40 return QStringLiteral("Hp12"); + case 40: // H41 + V_FALLTHROUGH + case 41: // H42 + return QStringLiteral("Hp13"); default: break; } @@ -1531,6 +1547,8 @@ QString MapDiagrams(const QString &number) return QStringLiteral("Lp8"); case 20: // L21 return QStringLiteral("Lp9"); + case 21: // L22 + return QStringLiteral("Lp10"); default: break; } @@ -1587,6 +1605,8 @@ QString MapDiagrams(const QString &number) V_FALLTHROUGH case 6: // N07 return QStringLiteral("Np4"); + case 7: // N08 + return QStringLiteral("Np5"); default: break; } diff --git a/src/libs/vmisc/def.h b/src/libs/vmisc/def.h index 39b9e889a..05247b423 100644 --- a/src/libs/vmisc/def.h +++ b/src/libs/vmisc/def.h @@ -291,6 +291,7 @@ extern const QString hipWithAbdomenArcF_M; // G42 extern const QString bodyArmfoldCirc_M; // G43 extern const QString bodyBustCirc_M; // G44 extern const QString bodyTorsoCirc_M; // G45 +extern const QString hipCircWithAbdomen_M; // G46 // H extern const QString neckFrontToWaistF_M; // H01 extern const QString neckFrontToWaistFlatF_M; // H02 @@ -332,6 +333,8 @@ extern const QString shoulderSlopeNeckSideLength_M; // H37 extern const QString shoulderSlopeNeckBackAngle_M; // H38 extern const QString shoulderSlopeNeckBackHeight_M; // H39 extern const QString shoulderSlopeShoulderTipAngle_M; // H40 +extern const QString neckBackToAcrossBack_M; // H41 +extern const QString acrossBackToWaistB_M; // H42 // I extern const QString shoulderLength_M; // I01 extern const QString shoulderTipToShoulderTipF_M; // I02 @@ -393,6 +396,7 @@ extern const QString armNeckSideToFingerTip_M; // L18 extern const QString armscyeCirc_M; // L19 extern const QString armscyeLength_M; // L20 extern const QString armscyeWidth_M; // L21 +extern const QString armNeckSideToOuterElbow_M; // L22 // M extern const QString legCrotchToFloor_M; // M01 extern const QString legWaistSideToFloor_M; // M02 @@ -409,13 +413,14 @@ extern const QString legCrotchToAnkle_M; // M12 extern const QString legWaistSideToAnkle_M; // M13 extern const QString legWaistSideToKnee_M; // M14 // N -extern const QString crotchLength_M; // N01 -extern const QString crotchLengthB_M; // N02 -extern const QString crotchLengthF_M; // N03 -extern const QString riseLengthSide_M; // N04 -extern const QString riseLengthDiag_M; // N05 -extern const QString riseLengthB_M; // N06 -extern const QString riseLengthF_M; // N07 +extern const QString crotchLength_M; // N01 +extern const QString crotchLengthB_M; // N02 +extern const QString crotchLengthF_M; // N03 +extern const QString riseLengthSideSitting_M; // N04 +extern const QString riseLengthDiag_M; // N05 +extern const QString riseLengthB_M; // N06 +extern const QString riseLengthF_M; // N07 +extern const QString riseLengthSide_M; // N08 // O extern const QString neckBackToWaistFront_M; // O01 extern const QString waistToWaistHalter_M; // O02 diff --git a/src/libs/vpatterndb/vtranslatemeasurements.cpp b/src/libs/vpatterndb/vtranslatemeasurements.cpp index 438b43f4c..ecb8e0c1b 100644 --- a/src/libs/vpatterndb/vtranslatemeasurements.cpp +++ b/src/libs/vpatterndb/vtranslatemeasurements.cpp @@ -904,6 +904,14 @@ void VTranslateMeasurements::InitGroupG() "Full measurement description."); InitMeasurement(bodyTorsoCirc_M, m, g, d, "G45"); //================================================================================================================= + m = translate("VTranslateMeasurements", "hip_circ_with_abdomen", + "Name in a formula. Don't use math symbols and space in name!!!!"); + g = translate("VTranslateMeasurements", "Hip circumference, including Abdomen", "Full measurement name."); + d = translate("VTranslateMeasurements", + "Measurement at Hip level, including the depth of the Abdomen. (Hip arc, back + Hip arc with " + "abdomen, front).", "Full measurement description."); + InitMeasurement(hipCircWithAbdomen_M, m, g, d, "G46", "(hip_arc_b + hip_with_abdomen_arc_f)"); + //================================================================================================================= } //--------------------------------------------------------------------------------------------------------------------- @@ -1195,6 +1203,20 @@ void VTranslateMeasurements::InitGroupH() "Full measurement description."); InitMeasurement(shoulderSlopeShoulderTipAngle_M, m, g, d, "H40"); //================================================================================================================= + m = translate("VTranslateMeasurements", "neck_back_to_across_back", + "Name in a formula. Don't use math symbols and space in name!!!!"); + g = translate("VTranslateMeasurements", "Neck Back to Across Back", "Full measurement name."); + d = translate("VTranslateMeasurements", "From neck back, down to level of Across Back measurement.", + "Full measurement description."); + InitMeasurement(neckBackToAcrossBack_M, m, g, d, "H41"); + //================================================================================================================= + m = translate("VTranslateMeasurements", "across_back_to_waist_b", + "Name in a formula. Don't use math symbols and space in name!!!!"); + g = translate("VTranslateMeasurements", "Across Back to Waist back", "Full measurement name."); + d = translate("VTranslateMeasurements", "From middle of Across Back down to Waist back.", + "Full measurement description."); + InitMeasurement(acrossBackToWaistB_M, m, g, d, "H42", "(neck_back_to_waist_b - neck_back_to_across_back)"); + //================================================================================================================= } //--------------------------------------------------------------------------------------------------------------------- @@ -1646,6 +1668,13 @@ void VTranslateMeasurements::InitGroupL() "Full measurement description."); InitMeasurement(armscyeWidth_M, m, g, d, "L21"); //================================================================================================================= + m = translate("VTranslateMeasurements", "arm_neck_side_to_outer_elbow", + "Name in a formula. Don't use math symbols and space in name!!!!"); + g = translate("VTranslateMeasurements", "Arm: Neck side to Elbow", "Full measurement name."); + d = translate("VTranslateMeasurements", "From Neck Side over Shoulder Tip down to Elbow. (Shoulder length + " + "Arm: Shoulder Tip to Elbow).", "Full measurement description."); + InitMeasurement(armNeckSideToOuterElbow_M, m, g, d, "L22", "(shoulder_length + arm_shoulder_tip_to_elbow)"); + //================================================================================================================= } //--------------------------------------------------------------------------------------------------------------------- @@ -1792,12 +1821,15 @@ void VTranslateMeasurements::InitGroupN() "Full measurement description."); InitMeasurement(crotchLengthF_M, m, g, d, "N03", "(crotch_length - crotch_length_b)"); //================================================================================================================= - m = translate("VTranslateMeasurements", "rise_length_side", + m = translate("VTranslateMeasurements", "rise_length_side_sitting", "Name in a formula. Don't use math symbols and space in name!!!!"); - g = translate("VTranslateMeasurements", "Rise length, side", "Full measurement name."); - d = translate("VTranslateMeasurements", "From Waist Side down to surface, while seated on hard surface.", + g = translate("VTranslateMeasurements", + "Sit on hard surface. Rise length, side, taken from waist over hip curve down to surface", + "Full measurement name."); + d = translate("VTranslateMeasurements", + "From Waist Side around hp curve down to surface, while seated on hard surface.", "Full measurement description."); - InitMeasurement(riseLengthSide_M, m, g, d, "N04"); + InitMeasurement(riseLengthSideSitting_M, m, g, d, "N04"); //================================================================================================================= m = translate("VTranslateMeasurements", "rise_length_diag", "Name in a formula. Don't use math symbols and space in name!!!!"); @@ -1820,6 +1852,13 @@ void VTranslateMeasurements::InitGroupN() "Full measurement description."); InitMeasurement(riseLengthF_M, m, g, d, "N07"); //================================================================================================================= + m = translate("VTranslateMeasurements", "rise_length_side", + "Name in a formula. Don't use math symbols and space in name!!!!"); + g = translate("VTranslateMeasurements", "Rise length, side", "Full measurement name."); + d = translate("VTranslateMeasurements", "Vertical distance from Waist side down to Crotch level. Use formula " + "(Height: Waist side - Leg: Crotch to floor).", "Full measurement description."); + InitMeasurement(riseLengthSide_M, m, g, d, "N08"); + //================================================================================================================= } //--------------------------------------------------------------------------------------------------------------------- diff --git a/src/test/ValentinaTest/tst_measurementregexp.cpp b/src/test/ValentinaTest/tst_measurementregexp.cpp index 91691d416..5a5ad7ca9 100644 --- a/src/test/ValentinaTest/tst_measurementregexp.cpp +++ b/src/test/ValentinaTest/tst_measurementregexp.cpp @@ -212,6 +212,7 @@ void TST_MeasurementRegExp::TestCorrectOrderMeasurement_data() QTest::newRow("G43") << bodyArmfoldCirc_M << "body_armfold_circ"; QTest::newRow("G44") << bodyBustCirc_M << "body_bust_circ"; QTest::newRow("G45") << bodyTorsoCirc_M << "body_torso_circ"; + QTest::newRow("G46") << hipCircWithAbdomen_M << "hip_circ_with_abdomen"; QTest::newRow("H01") << neckFrontToWaistF_M << "neck_front_to_waist_f"; QTest::newRow("H02") << neckFrontToWaistFlatF_M << "neck_front_to_waist_flat_f"; QTest::newRow("H03") << armpitToWaistSide_M << "armpit_to_waist_side"; @@ -252,6 +253,8 @@ void TST_MeasurementRegExp::TestCorrectOrderMeasurement_data() QTest::newRow("H38") << shoulderSlopeNeckBackAngle_M << "shoulder_slope_neck_back_angle"; QTest::newRow("H39") << shoulderSlopeNeckBackHeight_M << "shoulder_slope_neck_back_height"; QTest::newRow("H40") << shoulderSlopeShoulderTipAngle_M << "shoulder_slope_shoulder_tip_angle"; + QTest::newRow("H41") << neckBackToAcrossBack_M << "neck_back_to_across_back"; + QTest::newRow("H42") << acrossBackToWaistB_M << "across_back_to_waist_b"; QTest::newRow("I01") << shoulderLength_M << "shoulder_length"; QTest::newRow("I02") << shoulderTipToShoulderTipF_M << "shoulder_tip_to_shoulder_tip_f"; QTest::newRow("I03") << acrossChestF_M << "across_chest_f"; @@ -309,6 +312,7 @@ void TST_MeasurementRegExp::TestCorrectOrderMeasurement_data() QTest::newRow("L19") << armscyeCirc_M << "armscye_circ"; QTest::newRow("L20") << armscyeLength_M << "armscye_length"; QTest::newRow("L21") << armscyeWidth_M << "armscye_width"; + QTest::newRow("L22") << armNeckSideToOuterElbow_M << "arm_neck_side_to_outer_elbow"; QTest::newRow("M01") << legCrotchToFloor_M << "leg_crotch_to_floor"; QTest::newRow("M02") << legWaistSideToFloor_M << "leg_waist_side_to_floor"; QTest::newRow("M03") << legThighUpperCirc_M << "leg_thigh_upper_circ"; @@ -326,10 +330,11 @@ void TST_MeasurementRegExp::TestCorrectOrderMeasurement_data() QTest::newRow("N01") << crotchLength_M << "crotch_length"; QTest::newRow("N02") << crotchLengthB_M << "crotch_length_b"; QTest::newRow("N03") << crotchLengthF_M << "crotch_length_f"; - QTest::newRow("N04") << riseLengthSide_M << "rise_length_side"; + QTest::newRow("N04") << riseLengthSideSitting_M << "rise_length_side_sitting"; QTest::newRow("N05") << riseLengthDiag_M << "rise_length_diag"; QTest::newRow("N06") << riseLengthB_M << "rise_length_b"; QTest::newRow("N07") << riseLengthF_M << "rise_length_f"; + QTest::newRow("N08") << riseLengthSide_M << "rise_length_side"; QTest::newRow("O01") << neckBackToWaistFront_M << "neck_back_to_waist_front"; QTest::newRow("O02") << waistToWaistHalter_M << "waist_to_waist_halter"; QTest::newRow("O03") << waistNaturalCirc_M << "waist_natural_circ"; @@ -350,7 +355,8 @@ void TST_MeasurementRegExp::TestCorrectOrderMeasurement_data() QTest::newRow("P04") << highbustBackOverShoulderToArmfoldFront_M << "highbust_back_over_shoulder_to_armfold_front"; QTest::newRow("P05") << highbustBackOverShoulderToWaistFront_M << "highbust_back_over_shoulder_to_waist_front"; QTest::newRow("P06") << neckBackToArmfoldFrontToNeckBack_M << "neck_back_to_armfold_front_to_neck_back"; - QTest::newRow("P07") << acrossBackCenterToArmfoldFrontToAcrossBackCenter_M << "across_back_center_to_armfold_front_to_across_back_center"; + QTest::newRow("P07") << acrossBackCenterToArmfoldFrontToAcrossBackCenter_M + << "across_back_center_to_armfold_front_to_across_back_center"; QTest::newRow("P08") << neckBackToArmfoldFrontToHighbustBack_M << "neck_back_to_armfold_front_to_highbust_back"; QTest::newRow("P09") << armfoldToArmfoldBust_M << "armfold_to_armfold_bust"; QTest::newRow("P10") << armfoldToBustFront_M << "armfold_to_bust_front";