From 4586357ddef6f650974b915132790bf4ed5187f6 Mon Sep 17 00:00:00 2001 From: PouleyKetchoupp Date: Thu, 11 Feb 2021 09:33:45 -0700 Subject: Expose RichTextLabel selection to script Expose existing get_selection_text and add methods to get the current selection index from and index to. --- doc/classes/RichTextLabel.xml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'doc/classes') diff --git a/doc/classes/RichTextLabel.xml b/doc/classes/RichTextLabel.xml index fd32e86d7e..7ca70f5a7a 100644 --- a/doc/classes/RichTextLabel.xml +++ b/doc/classes/RichTextLabel.xml @@ -80,6 +80,27 @@ Returns the total number of paragraphs (newlines or [code]p[/code] tags in the tag stack's text tags). Considers wrapped text as one paragraph. + + + + + Returns the current selection text. Does not include BBCodes. + + + + + + + Returns the current selection first character index if a selection is active, [code]-1[/code] otherwise. Does not include BBCodes. + + + + + + + Returns the current selection last character index if a selection is active, [code]-1[/code] otherwise. Does not include BBCodes. + + -- cgit v1.2.3