Resolved issue #557. Enhance feature: Measurement menu enhancements.
--HG-- branch : develop
This commit is contained in:
parent
1b0bd37621
commit
c00a1d6e94
|
@ -1392,7 +1392,7 @@ void MainWindow::LoadIndividual()
|
|||
doc->SetPath(RelativeMPath(curFile, mPath));
|
||||
watcher->addPath(mPath);
|
||||
PatternChangesWereSaved(false);
|
||||
ui->actionShowM->setEnabled(true);
|
||||
ui->actionEditCurrent->setEnabled(true);
|
||||
helpLabel->setText(tr("Measurements loaded"));
|
||||
doc->LiteParseTree(Document::LiteParse);
|
||||
|
||||
|
@ -1432,7 +1432,7 @@ void MainWindow::LoadStandard()
|
|||
doc->SetPath(RelativeMPath(curFile, mPath));
|
||||
watcher->addPath(mPath);
|
||||
PatternChangesWereSaved(false);
|
||||
ui->actionShowM->setEnabled(true);
|
||||
ui->actionEditCurrent->setEnabled(true);
|
||||
helpLabel->setText(tr("Measurements loaded"));
|
||||
doc->LiteParseTree(Document::LiteParse);
|
||||
|
||||
|
@ -1468,7 +1468,7 @@ void MainWindow::UnloadMeasurements()
|
|||
watcher->removePath(AbsoluteMPath(curFile, doc->MPath()));
|
||||
doc->SetPath(QString());
|
||||
PatternChangesWereSaved(false);
|
||||
ui->actionShowM->setEnabled(false);
|
||||
ui->actionEditCurrent->setEnabled(false);
|
||||
ui->actionUnloadMeasurements->setDisabled(true);
|
||||
helpLabel->setText(tr("Measurements unloaded"));
|
||||
|
||||
|
@ -1518,7 +1518,7 @@ void MainWindow::ShowMeasurements()
|
|||
}
|
||||
else
|
||||
{
|
||||
ui->actionShowM->setEnabled(false);
|
||||
ui->actionEditCurrent->setEnabled(false);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2593,7 +2593,7 @@ void MainWindow::Clear()
|
|||
ui->actionLoadIndividual->setEnabled(false);
|
||||
ui->actionLoadStandard->setEnabled(false);
|
||||
ui->actionUnloadMeasurements->setEnabled(false);
|
||||
ui->actionShowM->setEnabled(false);
|
||||
ui->actionEditCurrent->setEnabled(false);
|
||||
SetEnableTool(false);
|
||||
qApp->setPatternUnit(Unit::Cm);
|
||||
qApp->setPatternType(MeasurementsType::Unknown);
|
||||
|
@ -3781,7 +3781,7 @@ void MainWindow::CreateActions()
|
|||
connect(ui->actionLoadIndividual, &QAction::triggered, this, &MainWindow::LoadIndividual);
|
||||
connect(ui->actionLoadStandard, &QAction::triggered, this, &MainWindow::LoadStandard);
|
||||
|
||||
connect(ui->actionCreateNew, &QAction::triggered, RECEIVER(this)[this]()
|
||||
connect(ui->actionOpenTape, &QAction::triggered, RECEIVER(this)[this]()
|
||||
{
|
||||
const QString tape = qApp->TapeFilePath();
|
||||
const QString workingDirectory = QFileInfo(tape).absoluteDir().absolutePath();
|
||||
|
@ -3795,7 +3795,7 @@ void MainWindow::CreateActions()
|
|||
QProcess::startDetached(tape, arguments, workingDirectory);
|
||||
});
|
||||
|
||||
connect(ui->actionShowM, &QAction::triggered, this, &MainWindow::ShowMeasurements);
|
||||
connect(ui->actionEditCurrent, &QAction::triggered, this, &MainWindow::ShowMeasurements);
|
||||
connect(ui->actionExportAs, &QAction::triggered, this, &MainWindow::ExportLayoutAs);
|
||||
connect(ui->actionPrintPreview, &QAction::triggered, this, &MainWindow::PrintPreviewOrigin);
|
||||
connect(ui->actionPrintPreviewTiled, &QAction::triggered, this, &MainWindow::PrintPreviewTiled);
|
||||
|
@ -4007,7 +4007,7 @@ bool MainWindow::LoadPattern(const QString &fileName, const QString& customMeasu
|
|||
{
|
||||
ui->actionUnloadMeasurements->setEnabled(true);
|
||||
watcher->addPath(path);
|
||||
ui->actionShowM->setEnabled(true);
|
||||
ui->actionEditCurrent->setEnabled(true);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -55,7 +55,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>100</width>
|
||||
<width>117</width>
|
||||
<height>358</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -427,7 +427,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>100</width>
|
||||
<width>130</width>
|
||||
<height>110</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -536,7 +536,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>100</width>
|
||||
<width>130</width>
|
||||
<height>248</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -798,7 +798,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>100</width>
|
||||
<width>130</width>
|
||||
<height>248</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -1063,7 +1063,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>100</width>
|
||||
<width>130</width>
|
||||
<height>58</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -1321,7 +1321,7 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>100</width>
|
||||
<width>130</width>
|
||||
<height>150</height>
|
||||
</rect>
|
||||
</property>
|
||||
|
@ -1456,8 +1456,8 @@
|
|||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>100</width>
|
||||
<height>58</height>
|
||||
<width>130</width>
|
||||
<height>326</height>
|
||||
</rect>
|
||||
</property>
|
||||
<attribute name="icon">
|
||||
|
@ -1616,13 +1616,13 @@
|
|||
<property name="title">
|
||||
<string>Measurements</string>
|
||||
</property>
|
||||
<addaction name="actionTable"/>
|
||||
<addaction name="actionOpenTape"/>
|
||||
<addaction name="actionEditCurrent"/>
|
||||
<addaction name="actionUnloadMeasurements"/>
|
||||
<addaction name="actionLoadIndividual"/>
|
||||
<addaction name="actionLoadStandard"/>
|
||||
<addaction name="actionUnloadMeasurements"/>
|
||||
<addaction name="actionCreateNew"/>
|
||||
<addaction name="actionShowM"/>
|
||||
<addaction name="actionSyncMeasurements"/>
|
||||
<addaction name="actionTable"/>
|
||||
</widget>
|
||||
<widget class="QMenu" name="menuWindow">
|
||||
<property name="title">
|
||||
|
@ -2072,10 +2072,10 @@
|
|||
<normaloff>:/icon/32x32/table.png</normaloff>:/icon/32x32/table.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Table of variables</string>
|
||||
<string>Variables Table</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Tables of variables</string>
|
||||
<string>Contains information about increments and internal variables</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true">Ctrl+T</string>
|
||||
|
@ -2475,7 +2475,10 @@
|
|||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Load Individual ...</string>
|
||||
<string>Load Individual</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Load Individual measurements file</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true"/>
|
||||
|
@ -2489,21 +2492,13 @@
|
|||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Load Standard ...</string>
|
||||
<string>Load Multisize</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
<property name="menuRole">
|
||||
<enum>QAction::NoRole</enum>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionCreateNew">
|
||||
<property name="text">
|
||||
<string>Create/Edit</string>
|
||||
<property name="iconText">
|
||||
<string>Load Multisize</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Create/edit measurements</string>
|
||||
<string>Load multisize measurements file</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true"/>
|
||||
|
@ -2512,15 +2507,29 @@
|
|||
<enum>QAction::NoRole</enum>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionShowM">
|
||||
<action name="actionOpenTape">
|
||||
<property name="text">
|
||||
<string>Open Tape</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Open Tape app for creating or editing measurements file </string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
<property name="menuRole">
|
||||
<enum>QAction::NoRole</enum>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionEditCurrent">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Show ...</string>
|
||||
<string>Edit Current</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Show measurements</string>
|
||||
<string>Edit linked to the pattern measurements</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true"/>
|
||||
|
@ -2538,7 +2547,10 @@
|
|||
<normaloff>:/icon/32x32/syncM.png</normaloff>:/icon/32x32/syncM.png</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Sync measurements</string>
|
||||
<string>Sync</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Synchronize linked to the pattern measurements after change</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true"/>
|
||||
|
@ -2552,10 +2564,10 @@
|
|||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Unload measurements</string>
|
||||
<string>Unload Current</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Unload measurements if they was not used in a pattern file.</string>
|
||||
<string>Unload measurements if they were not used in a pattern file</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string notr="true"/>
|
||||
|
@ -2574,8 +2586,8 @@
|
|||
</customwidget>
|
||||
</customwidgets>
|
||||
<resources>
|
||||
<include location="../../libs/vmisc/share/resources/icon.qrc"/>
|
||||
<include location="share/resources/toolicon.qrc"/>
|
||||
<include location="../../libs/vmisc/share/resources/icon.qrc"/>
|
||||
</resources>
|
||||
<connections/>
|
||||
</ui>
|
||||
|
|
Loading…
Reference in New Issue
Block a user