diff --git a/src/petrack.cpp b/src/petrack.cpp index eb5e0c6120f09e4cec4aed502058a42268ac9cfd..8f1362822426563a24c391da149757a139fda1b9 100644 --- a/src/petrack.cpp +++ b/src/petrack.cpp @@ -278,6 +278,12 @@ Petrack::Petrack() : createMenus(); createStatusBar(); + auto *exportShortCut = new QShortcut{QKeySequence("Ctrl+e"), this}; + connect(exportShortCut, &QShortcut::activated, this, [=]() { exportTracker(); }); + + auto *toggleOnlineTracking = new QShortcut{QKeySequence("Shift+t"), this}; + connect(toggleOnlineTracking, &QShortcut::activated, this, [=]() { mControlWidget->trackOnlineCalc->toggle(); }); + // TODO delete once we get Options to be value only (i.e. no Pointer/Ref anymore) mReco.getCodeMarkerOptions().setControlWidget(mControlWidget); mReco.getCodeMarkerOptions().setCodeMarkerItem(mCodeMarkerItem); @@ -1638,7 +1644,8 @@ void Petrack::keyBindings() "<dt><kbd>Shift + double-click left mouse button</kbd></dt><dd>inserts new or moves near trackpoint and " "enables showing only the modified trajectory</dd>" "<dt><kbd>Alt + double-click left mouse button</kbd></dt><dd>jumps to frame of trackpoint under cursor</dd>" - "<dt><kbd>Alt + holding left mouse button</kbd></dt><dd>moves trackpoint under cursor</dd></dl>" + "<dt><kbd>Alt + holding left mouse button</kbd></dt><dd>moves trackpoint under cursor</dd>" + "<dt><kbd>Ctrl + E</kbd></dt><dd>export trajectories</dd></dl>" "<p>Further key bindings you will find next to the entries of the menus.</p>"); PMessageBox *mb = new PMessageBox(this, tr("Key Bindings"), out, QIcon()); @@ -1754,12 +1761,10 @@ void Petrack::createActions() connect(mOpenMoCapAct, &QAction::triggered, this, &Petrack::openMoCapFile); mSaveSeqVidAct = new QAction(tr("Save Video"), this); - // mSaveSeqVidAct->setShortcut(tr("Ctrl+E")); mSaveSeqVidAct->setEnabled(false); connect(mSaveSeqVidAct, SIGNAL(triggered()), this, SLOT(saveVideo())); mSaveSeqVidViewAct = new QAction(tr("Save Video View"), this); - mSaveSeqVidViewAct->setShortcut(tr("Ctrl+E")); mSaveSeqVidViewAct->setEnabled(false); connect(mSaveSeqVidViewAct, SIGNAL(triggered()), this, SLOT(saveVideoView())); diff --git a/ui/control.ui b/ui/control.ui index 615ff47774decf25e0eb90b81ed82b5f6c3d1777..1ce085afb45e9e59bc1822e358ac00869382f44f 100644 --- a/ui/control.ui +++ b/ui/control.ui @@ -4839,9 +4839,6 @@ <property name="text"> <string>online calculation</string> </property> - <property name="shortcut"> - <string extracomment="tracking while playing">Shift+T</string> - </property> <property name="checked"> <bool>false</bool> </property> @@ -6250,15 +6247,6 @@ <property name="palette"> <palette> <active> - <colorrole role="WindowText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Button"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -6304,42 +6292,6 @@ </color> </brush> </colorrole> - <colorrole role="Text"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="BrightText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> - <colorrole role="ButtonText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="Base"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> <colorrole role="Window"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -6367,24 +6319,6 @@ </color> </brush> </colorrole> - <colorrole role="ToolTipBase"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>220</blue> - </color> - </brush> - </colorrole> - <colorrole role="ToolTipText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="PlaceholderText"> <brush brushstyle="NoBrush"> <color alpha="128"> @@ -6396,15 +6330,6 @@ </colorrole> </active> <inactive> - <colorrole role="WindowText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Button"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -6450,42 +6375,6 @@ </color> </brush> </colorrole> - <colorrole role="Text"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="BrightText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> - <colorrole role="ButtonText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="Base"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> <colorrole role="Window"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -6513,24 +6402,6 @@ </color> </brush> </colorrole> - <colorrole role="ToolTipBase"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>220</blue> - </color> - </brush> - </colorrole> - <colorrole role="ToolTipText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="PlaceholderText"> <brush brushstyle="NoBrush"> <color alpha="128"> @@ -6542,15 +6413,6 @@ </colorrole> </inactive> <disabled> - <colorrole role="WindowText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>127</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Button"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -6596,42 +6458,6 @@ </color> </brush> </colorrole> - <colorrole role="Text"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>127</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="BrightText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> - <colorrole role="ButtonText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>127</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="Base"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Window"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -6659,24 +6485,6 @@ </color> </brush> </colorrole> - <colorrole role="ToolTipBase"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>220</blue> - </color> - </brush> - </colorrole> - <colorrole role="ToolTipText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="PlaceholderText"> <brush brushstyle="NoBrush"> <color alpha="128"> @@ -6920,15 +6728,6 @@ <property name="palette"> <palette> <active> - <colorrole role="WindowText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Button"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -6974,42 +6773,6 @@ </color> </brush> </colorrole> - <colorrole role="Text"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="BrightText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> - <colorrole role="ButtonText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="Base"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> <colorrole role="Window"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -7037,24 +6800,6 @@ </color> </brush> </colorrole> - <colorrole role="ToolTipBase"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>220</blue> - </color> - </brush> - </colorrole> - <colorrole role="ToolTipText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="PlaceholderText"> <brush brushstyle="NoBrush"> <color alpha="128"> @@ -7066,15 +6811,6 @@ </colorrole> </active> <inactive> - <colorrole role="WindowText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Button"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -7120,42 +6856,6 @@ </color> </brush> </colorrole> - <colorrole role="Text"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="BrightText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> - <colorrole role="ButtonText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="Base"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> <colorrole role="Window"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -7183,24 +6883,6 @@ </color> </brush> </colorrole> - <colorrole role="ToolTipBase"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>220</blue> - </color> - </brush> - </colorrole> - <colorrole role="ToolTipText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="PlaceholderText"> <brush brushstyle="NoBrush"> <color alpha="128"> @@ -7212,15 +6894,6 @@ </colorrole> </inactive> <disabled> - <colorrole role="WindowText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>127</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Button"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -7266,42 +6939,6 @@ </color> </brush> </colorrole> - <colorrole role="Text"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>127</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="BrightText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>255</blue> - </color> - </brush> - </colorrole> - <colorrole role="ButtonText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>127</green> - <blue>0</blue> - </color> - </brush> - </colorrole> - <colorrole role="Base"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>255</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="Window"> <brush brushstyle="SolidPattern"> <color alpha="255"> @@ -7329,24 +6966,6 @@ </color> </brush> </colorrole> - <colorrole role="ToolTipBase"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>255</red> - <green>255</green> - <blue>220</blue> - </color> - </brush> - </colorrole> - <colorrole role="ToolTipText"> - <brush brushstyle="SolidPattern"> - <color alpha="255"> - <red>0</red> - <green>0</green> - <blue>0</blue> - </color> - </brush> - </colorrole> <colorrole role="PlaceholderText"> <brush brushstyle="NoBrush"> <color alpha="128">