Skip to content
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

Matching tr() in built-in scripts #5

Open
h0lley opened this issue Oct 8, 2020 · 2 comments · May be fixed by #8
Open

Matching tr() in built-in scripts #5

h0lley opened this issue Oct 8, 2020 · 2 comments · May be fixed by #8
Labels
enhancement New feature or request

Comments

@h0lley
Copy link

h0lley commented Oct 8, 2020

In built-in scripts, the code is stored in the tscn file and the " are escaped like so:

func _ready():
	print(tr(\"lalala\"))

would be cool if pybabel-godot could pick up those tr's as well.

@remram44
Copy link
Owner

remram44 commented Oct 8, 2020

I've never used those but maybe we can support them. The problem is that we'd have to replicate a lot of work Babel already knows how to do for source files...

I don't know if this is worth it, but thanks for bringing those to my attention! I had actually never noticed this option at all.

@remram44 remram44 added the enhancement New feature or request label Oct 8, 2020
@h0lley
Copy link
Author

h0lley commented Oct 8, 2020

I see. I imagined it might be an easy fix like adding a \ to a regular expression, but if it's something more complex it's probably not worth it. I encountered this issue while testing my pybabel setup, but haven't actually been in a situation yet where I'd need support for built-in scripts myself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants