editor icon indicating copy to clipboard operation
editor copied to clipboard

Translation for templates and forms

Open johnyoonh opened this issue 5 years ago • 1 comments

I found two <blocktrans> tags in the templates, but they were not done extensively. I was about to undertake the task of tagging more of these texts with {% trans%} tags, as well as using ugettext_lazy in python files. I am thinking about using _ notation:

from django.utils.translation import ugettext_lazy as _

I was wondering how the maintainer wants to handle the resulting .po files. They will diverge from the json files that Numbas compiler generates. If kept separate, it will result in a diverged effort in translating on poeditor.com; combining them could be a maintenance hassle and an extra dependency. Two repositories are already coupled, and perhaps guidance on how de-coupled they need to be would be helpful.

The primary motivation behind the effort is how I disagree with the term "Group," "Exam," "Question." I want to use "Section," "Deck," and "Slide" instead. I think they are more generic. For URL endpoints, LocalMiddleware can be used, but this is not a priority.

If there are other details I should read over, let me know! I will catch up with the documentation soon.

johnyoonh avatar Jun 06 '20 06:06 johnyoonh

Yes, there isn't any real translation at the moment. I haven't prioritised it, but it should be done at some point. I think the Numbas runtime translation can be considered completely separate to the editor. I certainly don't want to have to include strings that are only to do with the editor in the Numbas runtime.

christianp avatar Jun 08 '20 12:06 christianp