Skip to content

Commit

Permalink
fix(languages): Load default en language support if none explitly req…
Browse files Browse the repository at this point in the history
…uested
  • Loading branch information
alerque committed May 28, 2024
1 parent 61f1f2a commit 0e45246
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions classes/base.lua
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ function class:_init (options)
self:setOptions(options)
self:declareFrames(self.defaultFrameset)
self:registerPostinit(function (self_)
-- In the event no packages have called \language explicitly or otherwise triggerend the language loader, at this
-- point we'll have a language *setting* but not actually have loaded the language. We put it off as long as we
-- could in case the user changed the default document language and we didn't need to load the system default one,
-- but that time has come at gone at this point. Make sure we've loaded somethnig...
local lang = SILE.settings:get("document.language")
SILE.languageSupport.loadLanguage(lang)
if type(self.firstContentFrame) == "string" then
self_.pageTemplate.firstContentFrame = self_.pageTemplate.frames[self_.firstContentFrame]
end
Expand Down

0 comments on commit 0e45246

Please sign in to comment.