From e85e6ec7fcb4d2d542059feb63b18553d1470694 Mon Sep 17 00:00:00 2001 From: Yuri Sizov Date: Thu, 18 Nov 2021 18:55:43 +0300 Subject: Add methods to get position from column and line in TextEdit --- doc/classes/TextEdit.xml | 18 ++++++++++++++++++ doc/classes/TextServer.xml | 8 ++++++++ doc/classes/TextServerExtension.xml | 8 ++++++++ 3 files changed, 34 insertions(+) (limited to 'doc/classes') diff --git a/doc/classes/TextEdit.xml b/doc/classes/TextEdit.xml index 400fae4aad..16d8595b4e 100644 --- a/doc/classes/TextEdit.xml +++ b/doc/classes/TextEdit.xml @@ -362,6 +362,24 @@ Returns OpenType feature [code]tag[/code]. + + + + + + Returns the local position for the given [code]line[/code] and [code]column[/code]. If [code]x[/code] or [code]y[/code] of the returned vector equal [code]-1[/code], the position is outside of the viewable area of the control. + [b]Note:[/b] The Y position corresponds to the bottom side of the line. Use [method get_rect_at_line_column] to get the top side position. + + + + + + + + Returns the local position and size for the grapheme at the given [code]line[/code] and [code]column[/code]. If [code]x[/code] or [code]y[/code] position of the returned rect equal [code]-1[/code], the position is outside of the viewable area of the control. + [b]Note:[/b] The Y position of the returned rect corresponds to the top side of the line, unlike [method get_pos_at_line_column] which returns the bottom side. + + diff --git a/doc/classes/TextServer.xml b/doc/classes/TextServer.xml index e1c05165de..512078c56c 100644 --- a/doc/classes/TextServer.xml +++ b/doc/classes/TextServer.xml @@ -1028,6 +1028,14 @@ Returns text glyphs in the visual order. + + + + + + Returns composite character's bounds as offsets from the start of the line. + + diff --git a/doc/classes/TextServerExtension.xml b/doc/classes/TextServerExtension.xml index 684a1aa755..32f8107e0a 100644 --- a/doc/classes/TextServerExtension.xml +++ b/doc/classes/TextServerExtension.xml @@ -1037,6 +1037,14 @@ Copies text glyphs in the visual order, into preallocated array of the size returned by [method _shaped_text_get_glyph_count]. + + + + + + Returns composite character's bounds as offsets from the start of the line. + + -- cgit v1.2.3