From 41a20171eb81a7850dd96ec31da4b40c619538a2 Mon Sep 17 00:00:00 2001 From: Nathan Franke Date: Wed, 24 Nov 2021 20:58:47 -0600 Subject: align to horizontal_alignment, valign to vertical_alignment, related --- doc/classes/@GlobalScope.xml | 55 +++++++++++++++++++----------------- doc/classes/AspectRatioContainer.xml | 10 +++---- doc/classes/BoxContainer.xml | 13 ++++----- doc/classes/Button.xml | 19 +++---------- doc/classes/CanvasItem.xml | 8 +++--- doc/classes/CheckBox.xml | 2 +- doc/classes/CheckButton.xml | 2 +- doc/classes/Font.xml | 6 ++-- doc/classes/Label.xml | 34 ++++------------------ doc/classes/LineEdit.xml | 16 ++--------- doc/classes/OptionButton.xml | 2 +- doc/classes/RichTextLabel.xml | 18 ++---------- doc/classes/SpinBox.xml | 7 ++--- doc/classes/TabBar.xml | 15 ++++------ doc/classes/TabContainer.xml | 12 +++----- doc/classes/TextLine.xml | 7 ++--- doc/classes/TextParagraph.xml | 6 ++-- doc/classes/TextServer.xml | 4 +-- doc/classes/TextServerExtension.xml | 4 +-- doc/classes/TreeItem.xml | 19 ++++--------- 20 files changed, 90 insertions(+), 169 deletions(-) (limited to 'doc/classes') diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml index 41cc043a74..161e6278a2 100644 --- a/doc/classes/@GlobalScope.xml +++ b/doc/classes/@GlobalScope.xml @@ -1210,56 +1210,59 @@ - + Horizontal left alignment, usually for text-derived classes. - + Horizontal center alignment, usually for text-derived classes. - + Horizontal right alignment, usually for text-derived classes. - + Expand row to fit width, usually for text-derived classes. - + Vertical top alignment, usually for text-derived classes. - + Vertical center alignment, usually for text-derived classes. - + Vertical bottom alignment, usually for text-derived classes. - - Aligns the top of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGN_TO_*[/code] constant. + + Expand rows to fit height, usually for text-derived classes. - - Aligns the center of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGN_TO_*[/code] constant. + + Aligns the top of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGNMENT_TO_*[/code] constant. - - Aligns the bottom of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGN_TO_*[/code] constant. + + Aligns the center of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGNMENT_TO_*[/code] constant. - - Aligns the position of the inline object (e.g. image, table) specified by [code]INLINE_ALIGN_*_TO[/code] constant to the top of the text. + + Aligns the bottom of the inline object (e.g. image, table) to the position of the text specified by [code]INLINE_ALIGNMENT_TO_*[/code] constant. - - Aligns the position of the inline object (e.g. image, table) specified by [code]INLINE_ALIGN_*_TO[/code] constant to the center of the text. + + Aligns the position of the inline object (e.g. image, table) specified by [code]INLINE_ALIGNMENT_*_TO[/code] constant to the top of the text. - - Aligns the position of the inline object (e.g. image, table) specified by [code]INLINE_ALIGN_*_TO[/code] constant to the baseline of the text. + + Aligns the position of the inline object (e.g. image, table) specified by [code]INLINE_ALIGNMENT_*_TO[/code] constant to the center of the text. - + + Aligns the position of the inline object (e.g. image, table) specified by [code]INLINE_ALIGNMENT_*_TO[/code] constant to the baseline of the text. + + Aligns inline object (e.g. image, table) to the bottom of the text. - - Aligns top of the inline object (e.g. image, table) to the top of the text. Equvalent to [code]INLINE_ALIGN_TOP_TO | INLINE_ALIGN_TO_TOP[/code]. + + Aligns top of the inline object (e.g. image, table) to the top of the text. Equvalent to [code]INLINE_ALIGNMENT_TOP_TO | INLINE_ALIGNMENT_TO_TOP[/code]. - - Aligns center of the inline object (e.g. image, table) to the center of the text. Equvalent to [code]INLINE_ALIGN_CENTER_TO | INLINE_ALIGN_TO_CENTER[/code]. + + Aligns center of the inline object (e.g. image, table) to the center of the text. Equvalent to [code]INLINE_ALIGNMENT_CENTER_TO | INLINE_ALIGNMENT_TO_CENTER[/code]. - - Aligns bottom of the inline object (e.g. image, table) to the bottom of the text. Equvalent to [code]INLINE_ALIGN_BOTTOM_TO | INLINE_ALIGN_TO_BOTTOM[/code]. + + Aligns bottom of the inline object (e.g. image, table) to the bottom of the text. Equvalent to [code]INLINE_ALIGNMENT_BOTTOM_TO | INLINE_ALIGNMENT_TO_BOTTOM[/code]. Keycodes with this bit applied are non-printable. diff --git a/doc/classes/AspectRatioContainer.xml b/doc/classes/AspectRatioContainer.xml index 4c0af0b997..237bec4e61 100644 --- a/doc/classes/AspectRatioContainer.xml +++ b/doc/classes/AspectRatioContainer.xml @@ -9,10 +9,10 @@ - + Specifies the horizontal relative position of child controls. - + Specifies the vertical relative position of child controls. @@ -36,13 +36,13 @@ The width and height of child controls is automatically adjusted to make their bounding rectangle cover the entire area of the container while keeping the aspect ratio. When the bounding rectangle of child controls exceed the container's size and [member Control.rect_clip_content] is enabled, this allows to show only the container's area restricted by its own bounding rectangle. - + Aligns child controls with the beginning (left or top) of the container. - + Aligns child controls with the center of the container. - + Aligns child controls with the end (right or bottom) of the container. diff --git a/doc/classes/BoxContainer.xml b/doc/classes/BoxContainer.xml index ec81b866f6..a968e855a5 100644 --- a/doc/classes/BoxContainer.xml +++ b/doc/classes/BoxContainer.xml @@ -18,19 +18,16 @@ - - The alignment of the container's children (must be one of [constant ALIGN_BEGIN], [constant ALIGN_CENTER], or [constant ALIGN_END]). + + The alignment of the container's children (must be one of [constant ALIGNMENT_BEGIN], [constant ALIGNMENT_CENTER], or [constant ALIGNMENT_END]). - - Aligns children with the beginning of the container. + - - Aligns children with the center of the container. + - - Aligns children with the end of the container. + diff --git a/doc/classes/Button.xml b/doc/classes/Button.xml index 3145756511..d1a19861e4 100644 --- a/doc/classes/Button.xml +++ b/doc/classes/Button.xml @@ -64,8 +64,8 @@ - - Text alignment policy for the button's text, use one of the [enum TextAlign] constants. + + Text alignment policy for the button's text, use one of the [enum @GlobalScope.HorizontalAlignment] constants. When this property is enabled, text that is too large to fit the button is clipped, when disabled the Button will always be wide enough to hold the text. @@ -80,8 +80,8 @@ Button's icon, if text is present the icon will be placed before the text. To edit margin and spacing of the icon, use [theme_item hseparation] theme property and [code]content_margin_*[/code] properties of the used [StyleBox]es. - - Specifies if the icon should be aligned to the left, right, or center of a button. Uses the same [enum TextAlign] constants as the text alignment. If centered, text will draw on top of the icon. + + Specifies if the icon should be aligned to the left, right, or center of a button. Uses the same [enum @GlobalScope.HorizontalAlignment] constants as the text alignment. If centered, text will draw on top of the icon. Language code used for line-breaking and text shaping algorithms, if left empty current locale is used instead. @@ -93,17 +93,6 @@ Base text writing direction. - - - Align the text to the left. - - - Align the text to the center. - - - Align the text to the right. - - Default text [Color] of the [Button]. diff --git a/doc/classes/CanvasItem.xml b/doc/classes/CanvasItem.xml index 98437ef296..cf6a8bad5e 100644 --- a/doc/classes/CanvasItem.xml +++ b/doc/classes/CanvasItem.xml @@ -143,7 +143,7 @@ - + @@ -236,7 +236,7 @@ - + @@ -253,7 +253,7 @@ # so the Control is only created once. var default_font = Control.new().get_font("font") var default_font_size = Control.new().get_font_size("font_size") - draw_string(default_font, Vector2(64, 64), "Hello world", HALIGN_LEFT, -1, font_size) + draw_string(default_font, Vector2(64, 64), "Hello world", HORIZONTAL_ALIGNMENT_LEFT, -1, font_size) [/gdscript] [csharp] // If using this method in a script that redraws constantly, move the @@ -261,7 +261,7 @@ // so the Control is only created once. Font defaultFont = new Control().GetFont("font"); int defaultFontSize = new Control().GetFontSize("font_size"); - DrawString(defaultFont, new Vector2(64, 64), "Hello world", HALIGN_LEFT, -1, defaultFontSize); + DrawString(defaultFont, new Vector2(64, 64), "Hello world", HORIZONTAL_ALIGNMENT_LEFT, -1, defaultFontSize); [/csharp] [/codeblocks] See also [method Font.draw_string]. diff --git a/doc/classes/CheckBox.xml b/doc/classes/CheckBox.xml index 7dddacf3c9..32ef70a5cf 100644 --- a/doc/classes/CheckBox.xml +++ b/doc/classes/CheckBox.xml @@ -10,7 +10,7 @@ - + diff --git a/doc/classes/CheckButton.xml b/doc/classes/CheckButton.xml index c0315b93be..cf3aa869c3 100644 --- a/doc/classes/CheckButton.xml +++ b/doc/classes/CheckButton.xml @@ -10,7 +10,7 @@ - + diff --git a/doc/classes/Font.xml b/doc/classes/Font.xml index 01bc2837f1..275d6b6577 100644 --- a/doc/classes/Font.xml +++ b/doc/classes/Font.xml @@ -96,7 +96,7 @@ - + @@ -114,7 +114,7 @@ - + @@ -202,7 +202,7 @@ - + diff --git a/doc/classes/Label.xml b/doc/classes/Label.xml index bb273bcf48..e1d8b9e9f4 100644 --- a/doc/classes/Label.xml +++ b/doc/classes/Label.xml @@ -61,15 +61,15 @@ - - Controls the text's horizontal align. Supports left, center, right, and fill, or justify. Set it to one of the [enum Align] constants. - If set to something other than [constant AUTOWRAP_OFF], the text gets wrapped inside the node's bounding rectangle. If you resize the node, it will change its height automatically to show all the text. To see how each mode behaves, see [enum AutowrapMode]. If [code]true[/code], the Label only shows the text that fits inside its bounding rectangle and will clip text horizontally. + + Controls the text's horizontal alignment. Supports left, center, right, and fill, or justify. Set it to one of the [enum HorizontalAlignment] constants. + Language code used for line-breaking and text shaping algorithms, if left empty current locale is used instead. @@ -102,38 +102,14 @@ If [code]true[/code], all the text displays as UPPERCASE. - - Controls the text's vertical align. Supports top, center, bottom, and fill. Set it to one of the [enum VAlign] constants. + + Controls the text's vertical alignment. Supports top, center, bottom, and fill. Set it to one of the [enum VerticalAlignment] constants. Restricts the number of characters to display. Set to -1 to disable. - - Align rows to the left (default). - - - Align rows centered. - - - Align rows to the right. - - - Expand row to fit the width. - - - Align the whole text to the top. - - - Align the whole text to the center. - - - Align the whole text to the bottom. - - - Align the whole text by spreading the rows. - Autowrap is disabled. diff --git a/doc/classes/LineEdit.xml b/doc/classes/LineEdit.xml index 40e1057ed0..06094300de 100644 --- a/doc/classes/LineEdit.xml +++ b/doc/classes/LineEdit.xml @@ -159,8 +159,8 @@ - - Text alignment as defined in the [enum Align] enum. + + Text alignment as defined in the [enum HorizontalAlignment] enum. If [code]true[/code], the caret (text cursor) blinks. @@ -292,18 +292,6 @@ - - Aligns the text on the left-hand side of the [LineEdit]. - - - Centers the text in the middle of the [LineEdit]. - - - Aligns the text on the right-hand side of the [LineEdit]. - - - Expand row to fit the [LineEdit]'s width. - Cuts (copies and clears) the selected text. diff --git a/doc/classes/OptionButton.xml b/doc/classes/OptionButton.xml index d914b86a33..d2f9b08fbf 100644 --- a/doc/classes/OptionButton.xml +++ b/doc/classes/OptionButton.xml @@ -164,7 +164,7 @@ - + The index of the currently selected item, or [code]-1[/code] if no item is selected. diff --git a/doc/classes/RichTextLabel.xml b/doc/classes/RichTextLabel.xml index a74b0ed812..84956805c9 100644 --- a/doc/classes/RichTextLabel.xml +++ b/doc/classes/RichTextLabel.xml @@ -22,7 +22,7 @@ - + Adds an image's opening and closing tags to the tag stack, optionally providing a [code]width[/code] and [code]height[/code] to resize the image and a [code]color[/code] to tint the image. If [code]width[/code] or [code]height[/code] is set to 0, the image size will be adjusted in order to keep the original aspect ratio. @@ -279,7 +279,7 @@ - + @@ -296,7 +296,7 @@ - + Adds a [code][table=columns,inline_align][/code] tag to the tag stack. @@ -451,18 +451,6 @@ - - Makes text left aligned. - - - Makes text centered. - - - Makes text right aligned. - - - Makes text fill width. - Each list item has a number marker. diff --git a/doc/classes/SpinBox.xml b/doc/classes/SpinBox.xml index 615f5e3586..392d4d6a65 100644 --- a/doc/classes/SpinBox.xml +++ b/doc/classes/SpinBox.xml @@ -12,14 +12,14 @@ add_child(spin_box) var line_edit = spin_box.get_line_edit() line_edit.context_menu_enabled = false - spin_box.align = LineEdit.ALIGN_RIGHT + spin_box.horizontal_alignment = LineEdit.HORIZONTAL_ALIGNMENT_RIGHT [/gdscript] [csharp] var spinBox = new SpinBox(); AddChild(spinBox); var lineEdit = spinBox.GetLineEdit(); lineEdit.ContextMenuEnabled = false; - spinBox.Align = LineEdit.AlignEnum.Right; + spinBox.AlignHorizontal = LineEdit.HorizontalAlignEnum.Right; [/csharp] [/codeblocks] The above code will create a [SpinBox], disable context menu on it and set the text alignment to right. @@ -44,8 +44,7 @@ - - Sets the text alignment of the [SpinBox]. + If [code]true[/code], the [SpinBox] will be editable. Otherwise, it will be read only. diff --git a/doc/classes/TabBar.xml b/doc/classes/TabBar.xml index a9b09fb026..f97b3e08d1 100644 --- a/doc/classes/TabBar.xml +++ b/doc/classes/TabBar.xml @@ -209,8 +209,7 @@ if [code]true[/code], the mouse's scroll wheel can be used to navigate the scroll view. - - The alignment of all tabs. See [enum TabAlign] for details. + Sets when the close button will appear on the tabs. See [enum CloseButtonDisplayPolicy] for details. @@ -264,17 +263,13 @@ - - Align the tabs to the left. + - - Align the tabs to the center. + - - Align the tabs to the right. + - - Represents the size of the [enum TabAlign] enum. + Never show the close buttons. diff --git a/doc/classes/TabContainer.xml b/doc/classes/TabContainer.xml index 2ac6549250..d6e1e13505 100644 --- a/doc/classes/TabContainer.xml +++ b/doc/classes/TabContainer.xml @@ -141,8 +141,7 @@ If [code]true[/code], tabs can be rearranged with mouse drag. - - The alignment of all tabs in the tab container. See the [enum TabAlign] constants for details. + If [code]true[/code], tabs are visible. If [code]false[/code], tabs' content and titles are hidden. @@ -171,14 +170,11 @@ - - Align the tabs to the left. + - - Align the tabs to the center. + - - Align the tabs to the right. + diff --git a/doc/classes/TextLine.xml b/doc/classes/TextLine.xml index 598d0fb859..1eaccf4604 100644 --- a/doc/classes/TextLine.xml +++ b/doc/classes/TextLine.xml @@ -13,7 +13,7 @@ - + Adds inline object to the text buffer, [code]key[/code] must be unique. In the text, object is represented as [code]length[/code] object replacement characters. @@ -122,7 +122,7 @@ - + Sets new size and alignment of embedded object. @@ -144,8 +144,7 @@ - - Text horizontal alignment. + Text writing direction. diff --git a/doc/classes/TextParagraph.xml b/doc/classes/TextParagraph.xml index a7122b827e..6a510e4a74 100644 --- a/doc/classes/TextParagraph.xml +++ b/doc/classes/TextParagraph.xml @@ -13,7 +13,7 @@ - + Adds inline object to the text buffer, [code]key[/code] must be unique. In the text, object is represented as [code]length[/code] object replacement characters. @@ -240,7 +240,7 @@ - + Sets new size and alignment of embedded object. @@ -275,7 +275,7 @@ - + Paragraph horizontal alignment. diff --git a/doc/classes/TextServer.xml b/doc/classes/TextServer.xml index 512078c56c..6da45fdd4a 100644 --- a/doc/classes/TextServer.xml +++ b/doc/classes/TextServer.xml @@ -886,7 +886,7 @@ - + Adds inline object to the text buffer, [code]key[/code] must be unique. In the text, object is represented as [code]length[/code] object replacement characters. @@ -1213,7 +1213,7 @@ - + Sets new size and alignment of embedded object. diff --git a/doc/classes/TextServerExtension.xml b/doc/classes/TextServerExtension.xml index 32f8107e0a..af558150e2 100644 --- a/doc/classes/TextServerExtension.xml +++ b/doc/classes/TextServerExtension.xml @@ -893,7 +893,7 @@ - + Adds inline object to the text buffer, [code]key[/code] must be unique. In the text, object is represented as [code]length[/code] object replacement characters. @@ -1222,7 +1222,7 @@ - + Sets new size and alignment of embedded object. diff --git a/doc/classes/TreeItem.xml b/doc/classes/TreeItem.xml index b997d87ac0..7da98788bb 100644 --- a/doc/classes/TreeItem.xml +++ b/doc/classes/TreeItem.xml @@ -293,8 +293,8 @@ Returns the given column's text. - - + + Returns the given column's text alignment. @@ -623,12 +623,12 @@ Sets the given column's text value. - + - + - Sets the given column's text alignment. See [enum TextAlign] for possible values. + Sets the given column's text alignment. See [enum HorizontalAlignment] for possible values. @@ -679,14 +679,5 @@ - - Align text to the left. See [code]set_text_align()[/code]. - - - Center text. See [code]set_text_align()[/code]. - - - Align text to the right. See [code]set_text_align()[/code]. - -- cgit v1.2.3