Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libdap-qt-ui
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
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
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
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
cellframe
libdap-qt-ui
Commits
e2a25616
Commit
e2a25616
authored
5 years ago
by
konstantin.kukharenko
Browse files
Options
Downloads
Patches
Plain Diff
[+]New property Custom button
parent
a40f4165
No related branches found
No related tags found
7 merge requests
!26
Feature 3349
,
!25
Features 3332
,
!24
Features 3168
,
!23
Features 3167
,
!21
Features 3259
,
!20
Features 3257
,
!19
Features 3176
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
controls/CustomPlacementButton.cpp
+18
-0
18 additions, 0 deletions
controls/CustomPlacementButton.cpp
controls/CustomPlacementButton.h
+4
-0
4 additions, 0 deletions
controls/CustomPlacementButton.h
with
22 additions
and
0 deletions
controls/CustomPlacementButton.cpp
+
18
−
0
View file @
e2a25616
...
...
@@ -179,3 +179,21 @@ void CustomPlacementButton::setObjectName(const QString &name)
if
(
m_styledShadow
)
m_styledShadow
->
updateStyleProperties
();
}
void
CustomPlacementButton
::
spacerActivate
(
ButtonSpaicer
a_spacer
)
{
switch
(
a_spacer
)
{
case
ButtonSpaicer
::
Left
:
m_lbLeftSpacing
.
setVisible
(
true
);
break
;
case
ButtonSpaicer
::
Right
:
m_lbRightSpacing
.
setVisible
(
true
);
break
;
case
ButtonSpaicer
::
Both
:
m_lbRightSpacing
.
setVisible
(
true
);
m_lbLeftSpacing
.
setVisible
(
true
);
break
;
}
}
This diff is collapsed.
Click to expand it.
controls/CustomPlacementButton.h
+
4
−
0
View file @
e2a25616
...
...
@@ -11,6 +11,7 @@
#include
<QFontMetrics>
enum
class
ImagePos
{
Left
,
Right
};
enum
class
ButtonSpaicer
{
Left
,
Right
,
Both
};
/** @brief QPushButton with subControls "text" and "image"
*
...
...
@@ -76,6 +77,9 @@ public:
void
setImagePosition
(
ImagePos
a_position
=
ImagePos
::
Left
);
void
setGraphicsEffect
(
StyledDropShadowEffect
*
a_effect
);
///Makes widgets visible on the sides
/// @param a_spacer
void
spacerActivate
(
ButtonSpaicer
a_spacer
);
private:
///For effect.
...
...
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