[recorder] add project metadata action
This commit is contained in:
parent
b1f49966c4
commit
d16b00bb9c
@ -422,11 +422,17 @@ void PylonRecorder::createActions() {
|
|||||||
storeSettingsAction->setStatusTip(tr("store current settings as defaults"));
|
storeSettingsAction->setStatusTip(tr("store current settings as defaults"));
|
||||||
connect(storeSettingsAction, &QAction::triggered, this, &PylonRecorder::storeSettings);
|
connect(storeSettingsAction, &QAction::triggered, this, &PylonRecorder::storeSettings);
|
||||||
|
|
||||||
|
projectSettingsAction = new QAction(tr("set project name"), this);
|
||||||
|
projectSettingsAction->setStatusTip(tr("Set the project name"));
|
||||||
|
connect(projectSettingsAction, &QAction::triggered, this, &PylonRecorder::editProjectMetadata);
|
||||||
|
|
||||||
QMenu *settingsMenu = menuBar()->addMenu(tr("&Settings"));
|
QMenu *settingsMenu = menuBar()->addMenu(tr("&Settings"));
|
||||||
settingsMenu->addAction(selectStorageAction);
|
settingsMenu->addAction(selectStorageAction);
|
||||||
settingsMenu->addAction(storeSettingsAction);
|
settingsMenu->addAction(projectSettingsAction);
|
||||||
|
settingsMenu->addSeparator();
|
||||||
settingsMenu->setToolTipsVisible(true);
|
settingsMenu->setToolTipsVisible(true);
|
||||||
|
settingsMenu->addAction(storeSettingsAction);
|
||||||
|
|
||||||
QMenu *helpMenu = menuBar()->addMenu(tr("&Help"));
|
QMenu *helpMenu = menuBar()->addMenu(tr("&Help"));
|
||||||
helpMenu->addAction(tr("&About"), this, &PylonRecorder::about);
|
helpMenu->addAction(tr("&About"), this, &PylonRecorder::about);
|
||||||
helpMenu->addAction(tr("About &Qt"), &QApplication::aboutQt);
|
helpMenu->addAction(tr("About &Qt"), &QApplication::aboutQt);
|
||||||
@ -713,6 +719,7 @@ void PylonRecorder::grabStillFromPylon() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void PylonRecorder::selectStorageLocation() {
|
void PylonRecorder::selectStorageLocation() {
|
||||||
QString dir = QFileDialog::getExistingDirectory(this, tr("Open Directory"),
|
QString dir = QFileDialog::getExistingDirectory(this, tr("Open Directory"),
|
||||||
"/home",
|
"/home",
|
||||||
@ -724,3 +731,8 @@ void PylonRecorder::selectStorageLocation() {
|
|||||||
selectStorageAction->setStatusTip(tr("Storage location: ") + storageLocation);
|
selectStorageAction->setStatusTip(tr("Storage location: ") + storageLocation);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void PylonRecorder::editProjectMetadata(){
|
||||||
|
std::cerr << "EditProjectSettings" << std::endl;
|
||||||
|
}
|
||||||
|
@ -69,6 +69,10 @@ private:
|
|||||||
void updateActions();
|
void updateActions();
|
||||||
void applySettings();
|
void applySettings();
|
||||||
void storeSettings();
|
void storeSettings();
|
||||||
|
void editProjectMetadata();
|
||||||
|
void setExperimentName();
|
||||||
|
void setExperimenterName();
|
||||||
|
void setSubjectID();
|
||||||
QColor progressColor(int value);
|
QColor progressColor(int value);
|
||||||
std::string createFilename();
|
std::string createFilename();
|
||||||
|
|
||||||
@ -99,6 +103,7 @@ private:
|
|||||||
QString inactiveLabelStyle = ("QLabel { font-size: 10pt;font-family: Arial; color :gray; }");
|
QString inactiveLabelStyle = ("QLabel { font-size: 10pt;font-family: Arial; color :gray; }");
|
||||||
QSpinBox *framerateSpinner, *buffersizeSpinner, *exposureSpinner, *gainSpinner;
|
QSpinBox *framerateSpinner, *buffersizeSpinner, *exposureSpinner, *gainSpinner;
|
||||||
QAction *selectStorageAction, *storeSettingsAction;
|
QAction *selectStorageAction, *storeSettingsAction;
|
||||||
|
QAction *projectSettingsAction;
|
||||||
QString storageLocation = "";
|
QString storageLocation = "";
|
||||||
|
|
||||||
#if defined(QT_PRINTSUPPORT_LIB) && QT_CONFIG(printer)
|
#if defined(QT_PRINTSUPPORT_LIB) && QT_CONFIG(printer)
|
||||||
|
Loading…
Reference in New Issue
Block a user