Opened 11 years ago
Last modified 11 years ago
#580 assigned enhancement
Add msgctxt support to genshi i18n filters
Reported by: | eric.oconnell@… | Owned by: | hodgestar |
---|---|---|---|
Priority: | major | Milestone: | 0.8 |
Component: | Internationalization | Version: | 0.6 |
Keywords: | context, msgcontext | Cc: |
Description
It is often desirable to be able to translate the same source text into two or more translated texts, e.g. "volunteer" is both a noun and a verb in English. This patch adds an i18n:ctxt directive to genshi which uses the msgctxt/pgettext family of functions.
Attachments (3)
Change History (7)
Changed 11 years ago by eric.oconnell@…
comment:1 Changed 11 years ago by hodgestar
- Owner changed from cmlenz to hodgestar
- Status changed from new to assigned
Generally looks really good -- thanks!
Couple of comments (also mentioned on IRC):
- The if func not in contexted.values(): should be if func is not None:.
- We'll need a documentation update before landing this.
comment:2 Changed 11 years ago by eric.oconnell@…
@hodgestar, I've added some documentation and fixed the other issue you mentioned, but I believe you meant if func is None: rather than if func is not None:
comment:3 Changed 11 years ago by hodgestar
- Milestone changed from 0.7 to 0.8
I realized that since this adds a new feature it probably only makes sense for it to go into 0.8.x. Does that work for you?
comment:4 Changed 11 years ago by eric.oconnell@…
I have no objections.
msgctxt patch