[referencer] Compose, dialogue logic and translatable strings

John Spray jcspray at icculus.org
Wed Mar 14 20:00:05 EDT 2007


On Wed, 2007-03-14 at 07:55 +1000, Kai Willadsen wrote:
> * It marks some strings as translatable (everything I could find in
> TagWindow.C).
> * It moves some stuff around to avoid including markup in translatable
> messages, like:
>     <b>All</b>
>   is now
>     String::ucompose ("<b>%1</b>", _("All"))
> * Where possible, it changes GtkMessageDialogs to use the automatic
> markup scheme by removing markup on the primary message and using
> set_secondary_text().
> * It cleans up some of the dialogue logic for single/multiple cases.
> As best as I can tell, the logic is identical, except for a
> "docselectionignore_ = false;" statement, which to my reading has no
> effect. However, these parts would benefit from someone else reading
> them over.

Have reviewed this and committed it with one or two tweaks.

I couldn't see your patch doing anything to the docselectionignore
lines, but anyway I read it over and nothing leaps out at me as being
wrong.

> It *doesn't* fix other things:
> * I haven't ucompose-d or marked anything not in TagWindow.C. I know
> that Transfer.C, Library.C and DocumentProperties.C contain 1 or 2
> translatable strings each, but nothing big.

Indeed.

> * The functions Utility::exceptionDialog and TagWindow::ensureSaved
> will need to change significantly in order to not break translation.
> At the moment, they assume English-like grammar. Therefore, I haven't
> ucompose-ified them, and haven't marked any of their strings (or
> strings passed to them) for translation.

Yes, I kind of realised this was going to be a problem eventually (I'm
pleasantly surprised by how soon I've had interest from translators!).
What can I say, I was in a hurry when I wrote it ;-)

> * There are several situations where ngettext should probably be used,
> but by i18n-foo isn't really good enough to understand that properly.

Mine neither.

> I realise that the patch does several only-slightly-related things, so
> if you want it broken up, let me know.

In general I'd prefer if logic changes such as those for the dialogs
were in isolated patches, but I'm not picky enough to send it back.

Thanks for the patch.

John




More information about the referencer mailing list