Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
878ba466
Commit
878ba466
authored
Oct 23, 2013
by
Thomas Gubler
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add keyboard shortcut for plot filtering
parent
6e882d95
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
1 deletion
+9
-1
Linechart.ui
src/ui/Linechart.ui
+1
-1
LinechartWidget.cc
src/ui/linechart/LinechartWidget.cc
+6
-0
LinechartWidget.h
src/ui/linechart/LinechartWidget.h
+2
-0
No files found.
src/ui/Linechart.ui
View file @
878ba466
...
...
@@ -221,7 +221,7 @@
<item
row=
"1"
column=
"0"
>
<widget
class=
"QLineEdit"
name=
"plotFilterLineEdit"
>
<property
name=
"placeholderText"
>
<string>
Filter...
</string>
<string>
Filter...
(Ctrl+F)
</string>
</property>
</widget>
</item>
...
...
src/ui/linechart/LinechartWidget.cc
View file @
878ba466
...
...
@@ -106,6 +106,7 @@ LinechartWidget::LinechartWidget(int systemid, QWidget *parent) : QWidget(parent
connect
(
ui
.
recolorButton
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
recolor
()));
connect
(
ui
.
shortNameCheckBox
,
SIGNAL
(
clicked
(
bool
)),
this
,
SLOT
(
setShortNames
(
bool
)));
connect
(
ui
.
plotFilterLineEdit
,
SIGNAL
(
textChanged
(
const
QString
&
)),
this
,
SLOT
(
filterCurves
(
const
QString
&
)));
new
QShortcut
(
QKeySequence
(
Qt
::
CTRL
+
Qt
::
Key_F
),
this
,
SLOT
(
setPlotFilterLineEditFocus
()));
int
labelRow
=
curvesWidgetLayout
->
rowCount
();
...
...
@@ -694,6 +695,11 @@ void LinechartWidget::recolor()
}
}
void
LinechartWidget
::
setPlotFilterLineEditFocus
()
{
ui
.
plotFilterLineEdit
->
setFocus
(
Qt
::
ShortcutFocusReason
);
}
void
LinechartWidget
::
filterCurve
(
const
QString
&
key
,
bool
match
)
{
colorIcons
[
key
]
->
setVisible
(
match
);
...
...
src/ui/linechart/LinechartWidget.h
View file @
878ba466
...
...
@@ -108,6 +108,8 @@ public slots:
void
readSettings
();
/** @brief Select all curves */
void
selectAllCurves
(
bool
all
);
/** @brief Sets the focus to the LineEdit for plot-filtering */
void
setPlotFilterLineEditFocus
();
private
slots
:
/** Called when the user changes the time scale combobox. */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment