Stephan Richter wrote:
On Wednesday 31 May 2006 04:29, Chris Withers wrote:
- Can my existing .pot and .po files be used?

Yes, the PO file format is totally independent of Zope and Python.

But with PTS, I don't need to build .mo's myself, right? ;-)

- How would I mark up constant and computers strings in zodb-based
Python Scripts?

That issue has not been addressed at all, since we are not supporting TTW development.

That doesn't answer my question ;-)

- How do I ask the translation service what the currently negotiated
language is?

There are other interfaces for this; I believe ILanguageNegotiator.

Will that let me find out what the currently negotiated language is?

- How do I ask the translation service what all the available languages
are for a particular domain?

I do not think there is an API for that, but you could certainly develop one.

Where and how would I do this? I'd suggest this is an oversight in the existing API's and it'd be better to add to an existing API rather than come up with a new one...

- How do a write/register a negotiator that choose a language based on
an attribute of the user object and then falls back to normal browser
negotiation if that attribute isn't present?

Just implement the right interface and register it. This is not too hard and I think there are code examples out there.

Can you point me at some? I reckon I'll be okay writing the actual python, it's just going through the torture of zcml to find the right goat to sacrifice that I'm worried about, particularly as this is Five, not "just Zope 3"...

- How do I generate .pot files from ZPTs, Python Scipts and External
Methods? I used to use PTS' .missing functionality and just spider the
whole app. Is something similar available in Zope 2.9/3 land?

In Zope 3 you can simply call utilities/; it will extract all message strings from Python, ZPT and ZCML files.

Yeah, but not ones in the ZODB, right?


Simplistix - Content Management, Zope & Python Consulting
Zope3-users mailing list

Reply via email to