Can you get the character count from a specific line/paragraph?
Asked Answered
M

1

0

For Labels/RichTextLabels, is there a way to get the amount of characters only in a specific line/paragraph? So instead of get_total_character_count(), something like get_character_count_from_line(2)?

There doesn't seem to be a built-in function for this, can't find anything in the docs anyway.

Mord answered 15/3 at 16:34 Comment(0)
R
0

Mord You can use regex to extract the wanted line as a separate string. Or, simpler, split the string into lines using String::rsplit()

Radie answered 15/3 at 16:45 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.