Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BornAgain
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mlz
BornAgain
Commits
50d632d5
Commit
50d632d5
authored
2 years ago
by
Ludwig Jaeck
Browse files
Options
Downloads
Patches
Plain Diff
executed clang-format
parent
51143893
No related branches found
No related tags found
1 merge request
!1101
GUI: introducing single precission formatting for spinboxes with 'angle' property
Pipeline
#77495
passed
2 years ago
Stage: build
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
GUI/View/Common/DoubleSpinBox.cpp
+2
-1
2 additions, 1 deletion
GUI/View/Common/DoubleSpinBox.cpp
GUI/View/Common/DoubleSpinBox.h
+2
-2
2 additions, 2 deletions
GUI/View/Common/DoubleSpinBox.h
GUI/View/SampleDesigner/LayerEditorUtils.cpp
+3
-3
3 additions, 3 deletions
GUI/View/SampleDesigner/LayerEditorUtils.cpp
with
7 additions
and
6 deletions
GUI/View/Common/DoubleSpinBox.cpp
+
2
−
1
View file @
50d632d5
...
...
@@ -16,7 +16,8 @@
#include
"GUI/View/Tool/EditUtil.h"
#include
<QWheelEvent>
DoubleSpinBox
::
DoubleSpinBox
(
const
DoubleDescriptor
&
d
,
bool
easyScrollable
,
int
precision
,
double
stepSize
,
QWidget
*
parent
)
DoubleSpinBox
::
DoubleSpinBox
(
const
DoubleDescriptor
&
d
,
bool
easyScrollable
,
int
precision
,
double
stepSize
,
QWidget
*
parent
)
:
QDoubleSpinBox
(
parent
)
,
m_valueDescriptor
(
d
)
,
easyScrollable
(
easyScrollable
)
...
...
This diff is collapsed.
Click to expand it.
GUI/View/Common/DoubleSpinBox.h
+
2
−
2
View file @
50d632d5
...
...
@@ -27,8 +27,8 @@ public:
//! Furthermore, the spin box will prohibit accidental changes by the mouse wheel. Otherwise it
//! would be dangerous if the spin box is on a scrollable form - unintended and unnoticed
//! changes would take place when just scrolling through the form.
DoubleSpinBox
(
const
DoubleDescriptor
&
d
,
bool
easyScrollable
=
false
,
int
precision
=
2
,
double
singleStepSize
=
0.1
,
QWidget
*
parent
=
nullptr
);
DoubleSpinBox
(
const
DoubleDescriptor
&
d
,
bool
easyScrollable
=
false
,
int
precision
=
2
,
double
singleStepSize
=
0.1
,
QWidget
*
parent
=
nullptr
);
//! Set a display unit.
//!
//! The caller has to make sure that the new display unit has a conversion to/from the contained
...
...
This diff is collapsed.
Click to expand it.
GUI/View/SampleDesigner/LayerEditorUtils.cpp
+
3
−
3
View file @
50d632d5
...
...
@@ -85,10 +85,10 @@ void LayerEditorUtils::addMultiPropertyToGrid(QGridLayout* m_gridLayout, int fir
{
int
col
=
firstCol
;
for
(
const
auto
&
valueDescriptor
:
valueDescriptors
)
{
DoubleSpinBox
*
editor
;
DoubleSpinBox
*
editor
;
if
(
valueDescriptor
.
label
==
"Angle"
)
{
editor
=
new
DoubleSpinBox
(
valueDescriptor
,
false
,
1
,
1.0
);
}
else
{
editor
=
new
DoubleSpinBox
(
valueDescriptor
,
false
,
1
,
1.0
);
}
else
{
editor
=
new
DoubleSpinBox
(
valueDescriptor
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment