summaryrefslogtreecommitdiff
path: root/doc/bugs/ikiwiki_is_not_truly_localizable.mdwn
diff options
context:
space:
mode:
authorJoey Hess <joey@kodama.kitenet.net>2008-10-02 17:42:33 -0400
committerJoey Hess <joey@kodama.kitenet.net>2008-10-02 17:42:33 -0400
commit0b89d442331bd62b4dc2da4f7fcbca59d5ca21eb (patch)
treee564949aca3fa8c3f6f130a431a82f6d7f849ff2 /doc/bugs/ikiwiki_is_not_truly_localizable.mdwn
parentde235168153178e148a9a474f609c3fb043bd1ea (diff)
rename
Diffstat (limited to 'doc/bugs/ikiwiki_is_not_truly_localizable.mdwn')
-rw-r--r--doc/bugs/ikiwiki_is_not_truly_localizable.mdwn47
1 files changed, 0 insertions, 47 deletions
diff --git a/doc/bugs/ikiwiki_is_not_truly_localizable.mdwn b/doc/bugs/ikiwiki_is_not_truly_localizable.mdwn
deleted file mode 100644
index a1b38257a..000000000
--- a/doc/bugs/ikiwiki_is_not_truly_localizable.mdwn
+++ /dev/null
@@ -1,47 +0,0 @@
-A lot of strings in ikiwiki are hardcoded and not taken for locales resources through gettext. This is bad because ikiwiki is thus difficult to spread for non-english users.
-
-I mean that, for instance in CGI.pm, line like:
-
-`my @buttons=("Save Page", "Preview", "Cancel");`
-
-should be written as
-
-`my @buttons=(gettext("Save Page"), gettext("Preview"), gettext("Cancel"));`
-
-> Yes, these need to be fixed. But note that the localised texts come back
-> into ikiwiki and are used in various places, including plugins.
-> Including, possibly, third-party plugins. So localising the buttons would
-> seem to require converting from the translations back into the C locale
-> when the form is posted. --[[Joey]]
-
->> Wouldn't it be more easy to change all calls to the corrects ones (including in plugins) ?
->> For instance in the same file (CGI.pm): `elsif ($form->submitted eq gettext("Save Page")) {`.
->> That way no conversion to the C locale is needed.
->> gettext use should just be publicized in documentation (at least in [[plugins/write]]). --[[bbb]]
-
->>> It would be easy, but it could break third-party plugins that hardcode
->>> the english strings. It's also probably less efficient to run gettext
->>> over and over. --[[Joey]]
-
-In standards templates things seems wrongly written too. For instance in page.tmpl line like:
-
-`<li><a href="<TMPL_VAR EDITURL>" rel="nofollow">Edit</a></li>`
-
-should be written as
-
-`<li><a href="<TMPL_VAR EDITURL>" rel="nofollow"><TMPL_VAR EDITURL_TEXT</a></li>`
-
-with EDITURL_TEXT variable initialized in Render.pm through a gettext call.
-
-Am I wrong ?
-
-> No, that's not a sane way to localise the templates. The templates can be
-> translated by making a copy and modifying it, or by using a tool to
-> generate .mo files from the templates, and generate translated templates
-> from .po files. (See [[todo/l10n]] for one attempt.) But pushing the
-> localisation of random strings in the templates through the ikiwiki
-> program defeats the purpose of having templates at all. --[[Joey]]
-
-If not I can spend some time preparing patches for such corrections if it can help.
-
--- [[/users/bbb]]