Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Tobias Hunger
qt-creator
Commits
ce0cde83
Commit
ce0cde83
authored
Aug 04, 2010
by
Thomas Hartmann
Browse files
QtQuickToolBar: Bo not allow negative border margins
While editing BorderImage margins I do not allow negative margins anymore.
parent
b59962eb
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/plugins/qmldesigner/components/propertyeditor/contextpanewidgetimage.cpp
View file @
ce0cde83
...
...
@@ -520,11 +520,14 @@ void PreviewLabel::paintEvent(QPaintEvent *event)
pen
.
setColor
(
"#F0F0F0"
);
p
.
setPen
(
pen
);
p
.
drawLine
(
m_left
*
m_zoom
,
4
,
m_left
*
m_zoom
,
height
()
-
4
);
p
.
drawLine
(
width
()
-
m_right
*
m_zoom
,
4
,
width
()
-
m_right
*
m_zoom
,
height
()
-
4
);
p
.
drawLine
(
4
,
m_top
*
m_zoom
,
width
()
-
4
,
m_top
*
m_zoom
);
p
.
drawLine
(
4
,
height
()
-
m_bottom
*
m_zoom
,
width
()
-
4
,
height
()
-
m_bottom
*
m_zoom
);
if
(
m_left
>=
0
)
p
.
drawLine
(
m_left
*
m_zoom
,
4
,
m_left
*
m_zoom
,
height
()
-
4
);
if
(
m_right
>=
0
)
p
.
drawLine
(
width
()
-
m_right
*
m_zoom
,
4
,
width
()
-
m_right
*
m_zoom
,
height
()
-
4
);
if
(
m_top
>=
0
)
p
.
drawLine
(
4
,
m_top
*
m_zoom
,
width
()
-
4
,
m_top
*
m_zoom
);
if
(
m_bottom
>=
0
)
p
.
drawLine
(
4
,
height
()
-
m_bottom
*
m_zoom
,
width
()
-
4
,
height
()
-
m_bottom
*
m_zoom
);
}
{
...
...
@@ -534,11 +537,14 @@ void PreviewLabel::paintEvent(QPaintEvent *event)
pen
.
setColor
(
"#101010"
);
p
.
setPen
(
pen
);
p
.
drawLine
(
m_left
*
m_zoom
,
4
,
m_left
*
m_zoom
,
height
()
-
4
);
p
.
drawLine
(
width
()
-
m_right
*
m_zoom
,
4
,
width
()
-
m_right
*
m_zoom
,
height
()
-
4
);
p
.
drawLine
(
4
,
m_top
*
m_zoom
,
width
()
-
4
,
m_top
*
m_zoom
);
p
.
drawLine
(
4
,
height
()
-
m_bottom
*
m_zoom
,
width
()
-
4
,
height
()
-
m_bottom
*
m_zoom
);
if
(
m_left
>=
0
)
p
.
drawLine
(
m_left
*
m_zoom
,
4
,
m_left
*
m_zoom
,
height
()
-
4
);
if
(
m_right
>=
0
)
p
.
drawLine
(
width
()
-
m_right
*
m_zoom
,
4
,
width
()
-
m_right
*
m_zoom
,
height
()
-
4
);
if
(
m_top
>=
0
)
p
.
drawLine
(
4
,
m_top
*
m_zoom
,
width
()
-
4
,
m_top
*
m_zoom
);
if
(
m_bottom
>=
0
)
p
.
drawLine
(
4
,
height
()
-
m_bottom
*
m_zoom
,
width
()
-
4
,
height
()
-
m_bottom
*
m_zoom
);
}
}
}
...
...
Write
Preview
Supports
Markdown
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