translations

classic Classic list List threaded Threaded
Assigned to fschmidt at priority
 5 
(Lowest)
3 messages Options
Reply | Threaded
Open this post in threaded view
|

translations

fschmidt
Administrator
I suggest processing translations at compile time.  Each output statement would be matched against a translation at compile time and if a match is found, the output statement would be translated into a function call.  For example:

in App.luan:
function App.congratulations_notice() %>
	<div class="big-title second-font"><%%>Congratulations!<%%></div>
	<%%>Your <%=page_node.lower_case_view_name()%> has been successfully created.<%%><br/>
	...
<% end

in Spanish.luan
module "Spanish"

function tu_ha_sido_creado(what)
	...
end

Spanish["Congratulations!"] = function() %>¡Felicidades!<% end
Spanish["Your <%=%> has been successfully created."] = tu_ha_sido_creado

Package.loaded.Translation = Spanish
Woe to those who call bad good and good bad -- Isaiah 5:20
Following the Old Testament, not evil modern culture
Reply | Threaded
Open this post in threaded view
|

Re: translations

Hugo <Nabble>
We discussed this. We should look at other options and then make a decision.
Reply | Threaded
Open this post in threaded view
|

Re: translations

fschmidt
Administrator
I looked at a few other implementations but didn't see anything better.
Woe to those who call bad good and good bad -- Isaiah 5:20
Following the Old Testament, not evil modern culture