Move all translation into the main locale directory.
This is for consistency reason as the lib/dtutils/file.lua use this directory. Also all translation into contrib where not usable as not checked into this directory which was expected to be just lua. All in all using locale directory will avoid clutter the main directory with all possible languages and fixes the current scripts.
This commit is contained in:
@@ -46,7 +46,7 @@ dt.configuration.check_version(...,{3,0,0},{4,0,0})
|
||||
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("clear_GPS",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("clear_GPS",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("clear_GPS", msgid)
|
||||
|
||||
@@ -43,7 +43,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{3,0,0},{4,0,0},{5,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("copy_attach_detach_tags",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("copy_attach_detach_tags",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("copy_attach_detach_tags", msgid)
|
||||
|
||||
@@ -39,7 +39,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{3,0,0},{4,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("geoJSON_export",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("geoJSON_export",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("geoJSON_export", msgid)
|
||||
|
||||
@@ -32,7 +32,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{3,0,0},{4,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("geoToolbox",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("geoToolbox",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("geoToolbox", msgid)
|
||||
|
||||
@@ -71,7 +71,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{3,0,0},{4,0,0},{5,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("gimp",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("gimp",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function split_filepath(str)
|
||||
local result = {}
|
||||
|
||||
@@ -42,7 +42,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{2,0,0},{3,0,0},{4,0,0},{5,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("hugin",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("hugin",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("hugin", msgid)
|
||||
|
||||
@@ -43,7 +43,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{3,0,0},{4,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("kml_export",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("kml_export",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("kml_export", msgid)
|
||||
|
||||
@@ -45,7 +45,7 @@ require "official/yield"
|
||||
local gettext = dt.gettext
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("pdf_slideshow",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("pdf_slideshow",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("pdf_slideshow", msgid)
|
||||
|
||||
@@ -52,7 +52,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{3,0,0},{4,0,0},{5,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("quicktag",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("quicktag",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("quicktag", msgid)
|
||||
|
||||
@@ -31,7 +31,7 @@ local gettext = dt.gettext
|
||||
dt.configuration.check_version(...,{2,0,2},{3,0,0},{4,0,0})
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
gettext.bindtextdomain("slideshowMusic",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("slideshowMusic",dt.configuration.config_dir.."/lua/locale/")
|
||||
|
||||
local function _(msgid)
|
||||
return gettext.dgettext("slideshowMusic", msgid)
|
||||
|
||||
@@ -64,7 +64,7 @@ dt.print_error(gettext.gettext("image"))
|
||||
|
||||
-- Tell gettext where to find the .mo file translating messages for a particular domain
|
||||
|
||||
gettext.bindtextdomain("gettextExample",dt.configuration.config_dir.."/lua/")
|
||||
gettext.bindtextdomain("gettextExample",dt.configuration.config_dir.."/lua/locale/")
|
||||
-- Translate a string using the specified textdomain
|
||||
dt.print_error(gettext.dgettext("gettextExample", 'Hello World!'))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user