Doc: Add anchor button images and use them in the docs

Also needed in the Qt Design Studio tutorials.

Change-Id: I3efe391660480b02d010327afd583070b1fa1a33
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
Leena Miettinen
2019-04-24 16:18:49 +02:00
parent ecd386c67b
commit ee68989e2a
11 changed files with 28 additions and 21 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 98 B

BIN
doc/images/anchor-fill.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 108 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 95 B

BIN
doc/images/anchor-left.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 B

BIN
doc/images/anchor-right.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 B

BIN
doc/images/anchor-top.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 99 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 B

View File

@@ -100,7 +100,7 @@
to reference the rectangle from other places. to reference the rectangle from other places.
\li Select the \uicontrol Layout tab, and then click \li Select the \uicontrol Layout tab, and then click
the \inlineimage anchor_fill.png the \inlineimage anchor-fill.png
(\uicontrol {Fill to Parent}) button to anchor the rectangle (\uicontrol {Fill to Parent}) button to anchor the rectangle
to the item. to the item.

View File

@@ -117,22 +117,24 @@
\li In the \uicontrol {Border color} field, set the border color to \li In the \uicontrol {Border color} field, set the border color to
\e #808080. \e #808080.
\li Click \uicontrol {Layout}, and then click the top and left \li Click \uicontrol {Layout}, and then click the
anchor buttons to anchor the rectangle to the top left corner of \inlineimage anchor-top.png
the page. (\uicontrol Top) and \inlineimage anchor-left.png
(\uicontrol Left) anchor buttons to anchor the
\image qmldesigner-tutorial-topleftrect-layout.png "Layout tab" rectangle to the top left corner of the page.
\li In the \uicontrol Margin field, select \e 20 for the top anchor \li In the \uicontrol Margin field, select \e 20 for the top anchor
and \e 10 for the left anchor. and \e 10 for the left anchor.
\image qmldesigner-tutorial-topleftrect-layout.png "Anchor margins"
\endlist \endlist
\li Drag and drop a \uicontrol {Mouse Area} type from the \li Drag and drop a \uicontrol {Mouse Area} type from the
\uicontrol Library to \e topLeftRect in the navigator. \uicontrol Library to \e topLeftRect in the navigator.
\li Click \uicontrol {Layout}, and then click the \li Click \uicontrol {Layout}, and then click the
\inlineimage anchor_fill.png \inlineimage anchor-fill.png
(\uicontrol {Fill to Parent}) button to anchor the mouse area to the (\uicontrol {Fill to Parent}) button to anchor the mouse area to the
rectangle. rectangle.
@@ -147,9 +149,12 @@
\li In the \uicontrol Id field, enter \e middleRightRect. \li In the \uicontrol Id field, enter \e middleRightRect.
\li In \uicontrol {Layout}, select the vertical center anchor button and \li In \uicontrol {Layout}, select the
then the right anchor button to \inlineimage anchor-vertical-center.png
anchor the rectangle to the middle right margin of its parent. (\uicontrol {Vertical Center} anchor button and then the
\inlineimage anchor-right.png
(\uicontrol Right) anchor button to anchor the rectangle
to the middle right margin of its parent.
\li In the \uicontrol Margin field, select \e 10 for the right \li In the \uicontrol Margin field, select \e 10 for the right
anchor and \e 0 for the vertical center anchor. anchor and \e 0 for the vertical center anchor.
@@ -162,8 +167,11 @@
\li In the \uicontrol Id field, enter \e bottomLeftRect. \li In the \uicontrol Id field, enter \e bottomLeftRect.
\li In \uicontrol {Layout}, select the bottom and left anchor buttons to \li In \uicontrol {Layout}, select the
anchor the rectangle to the bottom left margin of its parent. \inlineimage anchor-bottom.png
(\uicontrol Bottom) and \inlineimage anchor-left.png
(\uicontrol Left) anchor buttons to anchor the rectangle
to the bottom left margin of its parent.
\li In the \uicontrol Margin field, select \e 20 for the bottom \li In the \uicontrol Margin field, select \e 20 for the bottom
anchor and \e 10 for the left anchor. anchor and \e 10 for the left anchor.

View File

@@ -76,7 +76,7 @@
the rectangle and produce rounded corners for the button. the rectangle and produce rounded corners for the button.
\li Select \uicontrol {Layout}, and then select the \li Select \uicontrol {Layout}, and then select the
\inlineimage anchor_fill.png \inlineimage anchor-fill.png
(\uicontrol {Fill to Parent}) button to anchor the rectangle to (\uicontrol {Fill to Parent}) button to anchor the rectangle to
the item. the item.
@@ -208,7 +208,7 @@
for example button_up.png. for example button_up.png.
\li Click \uicontrol {Layout}, and then click the \li Click \uicontrol {Layout}, and then click the
\inlineimage anchor_fill.png \inlineimage anchor-fill.png
(\uicontrol {Fill to Parent}) button to anchor the border image to the (\uicontrol {Fill to Parent}) button to anchor the border image to the
\uicontrol Item. \uicontrol Item.
@@ -258,12 +258,11 @@
\endlist \endlist
\li Click \uicontrol {Layout}, and then click the \li Click \uicontrol {Layout}, and then click the
\inlineimage anchor_vertical.png \inlineimage anchor-vertical-center.png
(\uicontrol {Set Vertical Anchor}) and (\uicontrol {Vertical Center}) and
\inlineimage anchor_horizontal.png \inlineimage anchor-horizontal-center.png
(\uicontrol {Set Horizontal Anchor}) (\uicontrol {Horizontal Center}) buttons to inherit the
buttons to inherit the vertical and horizontal centering from vertical and horizontal centering from the parent.
the parent.
\endlist \endlist

View File

@@ -212,7 +212,7 @@
\image qmldesigner-anchor-buttons.png "Anchor buttons" \image qmldesigner-anchor-buttons.png "Anchor buttons"
For convenience, you can click the \inlineimage anchor_fill.png For convenience, you can click the \inlineimage anchor-fill.png
(\uicontrol {Fill to Parent}) toolbar button to apply fill anchors to an (\uicontrol {Fill to Parent}) toolbar button to apply fill anchors to an
item and the \inlineimage qtcreator-anchors-reset-icon.png item and the \inlineimage qtcreator-anchors-reset-icon.png
(\uicontrol {Reset Anchors}) button to reset the anchors to their saved (\uicontrol {Reset Anchors}) button to reset the anchors to their saved