Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pymsc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
TASTE
pymsc
Commits
50944e65
Commit
50944e65
authored
Nov 21, 2014
by
Maxime Perrotin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve rendering of the Condition symbol
parent
091ca049
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
mscgraphics/basicmscgraph/mscGraphCondition.py
mscgraphics/basicmscgraph/mscGraphCondition.py
+6
-5
No files found.
mscgraphics/basicmscgraph/mscGraphCondition.py
View file @
50944e65
...
...
@@ -26,7 +26,7 @@
#
#******************************************************************************
from
PySide.QtGui
import
QPainterPath
,
QPen
from
PySide.QtCore
import
Qt
,
Slot
from
PySide.QtCore
import
Qt
,
Slot
,
QPointF
from
msccore
import
MscCondition
from
mscgraphics
import
MscGraphItem
...
...
@@ -38,8 +38,8 @@ class MscGraphCondition(MscGraphItem):
Class that draws a Condition symbol
'''
DefaultWidth
=
1
0
0
DefaultHeight
=
10
0
DefaultWidth
=
1
5
0
DefaultHeight
=
3
0
def
__init__
(
self
,
data
=
None
,
y
=
0
,
label
=
None
,
parent
=
None
):
u"""
...
...
@@ -99,8 +99,9 @@ class MscGraphCondition(MscGraphItem):
self
.
label
.
setTextLabel
(
self
.
mscData
().
getName
())
def
updateLabelPosition
(
self
):
self
.
label
.
setPos
(
self
.
width
+
10
,
-
self
.
label
.
boundingRect
().
height
()
/
2
)
self
.
label
.
setCenterPos
(
QPointF
(
0
,
15
))
#self.label.setPos(self.x() + 10,
# -self.label.boundingRect().height() / 2)
#**************************************************************************
# Item Change
...
...
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