19 #include <QFileDialog>
24 #include <itksys/SystemTools.hxx>
25 #include <Poco/Path.h>
39 CreateQtPartControl(
this);
49 void QmitkMicronTrackerWidget::CreateQtPartControl(QWidget *parent)
59 void QmitkMicronTrackerWidget::CreateConnections()
70 m_Controls->m_outputTextMicronTracker->setHtml(
"<body style=\" font-family:\'MS Shell Dlg 2\'; font-size:7pt; font-weight:400; font-style:normal;\" bgcolor=black><span style=\"color:#ffffff;\"><u>output:</u>");
75 m_Controls->m_outputTextMicronTracker->setHtml(QString(s.c_str()));
76 m_Controls->m_outputTextMicronTracker->verticalScrollBar()->setValue(
m_Controls->m_outputTextMicronTracker->verticalScrollBar()->maximum());
87 m_Controls->m_MTCalibrationFile->setText(
"Calibration File: " + QString(myPath.getFileName().c_str()));
93 newDevice->SetCalibrationDir(path);
96 AddOutput(
"<br>Warning: Calibration file is not set!");
102 std::string
id =
"org.mitk.modules.igt.ui.trackingdeviceconfigurationwidget";
111 settings.beginGroup(QString::fromStdString(
id));
112 settings.setValue(
"mTCalibrationFile", QVariant(QString::fromStdString(
m_MTCalibrationFile)));
119 std::string
id =
"org.mitk.modules.igt.ui.trackingdeviceconfigurationwidget";
124 if (propList.IsNull())
126 MITK_ERROR <<
"Property list for this UI (" <<
id <<
") is not available, could not load UI settings!";
return;
135 settings.beginGroup(QString::fromStdString(
id));
150 std::string
filename = QFileDialog::getOpenFileName(NULL, tr(
"Open Calibration File"),
"/",
"*.*").toLatin1().data();
151 if (filename ==
"") {
return; }
156 m_Controls->m_MTCalibrationFile->setText(
"Calibration File: " + QString(myPath.getFileName().c_str()));
itk::SmartPointer< Self > Pointer
static const std::string filename