-
-
Notifications
You must be signed in to change notification settings - Fork 691
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Format tags count towards truncating text #531
Comments
Possibly related to this, formatting tags that define actions are disabled on truncated content:
Is not clickable and sonata is never launched. However if:
everything works as expected, unless the song title is really long. I propose relabeling as a |
Yeah indeed, if the string is truncated then the |
@Lomadriel what did you have in mind? The only way I think this could be done is by truncating text in the parser instead of when we are generating the intermediate content string |
Hum, maybe I missed something, but this can be solved by modifying this function: If I am not wrong, the only tags that are in the label when this function is called are the formatting ones. |
Well, you'd need to do comprehensive tag parsing inside This would mean we completely parse formatting tags both here and in the parser. We also do parsing of user specified raw tags in the builder currently, but I removed that in 2504f0d because it was buggy. There is a discussion to be had about whether or not it makes sense to parse tokens both before adding them to the output string and afterwards in the parser. In some cases it might make sense for example here or when fixing #1701. But if we already parse it beforehand it might make sense to actually store the output string in a more structured way that makes the second parsing unnecessary. |
Indeed this is bugged :/
It might be a good idea to store the output string in a more structured way and could greatly simplify the manipulation of these strings. |
Consider the following module:
It shows the following:
I believe the format tags shouldn't be considered when truncating the text.
The text was updated successfully, but these errors were encountered: