MCPcopy Index your code
hub / github.com/archlinux/archinstall / activate

Method activate

archinstall/lib/translationhandler.py:205–214  ·  view source on GitHub ↗

Set the provided language as the current translation

(self, language: Language, set_font: bool = True)

Source from the content-addressed store, hash-verified

203 raise ValueError(f'No language with abbreviation "{abbr}" found')
204
205 def activate(self, language: Language, set_font: bool = True) -> None:
206 """
207 Set the provided language as the current translation
208 """
209 # The install() call has the side effect of assigning GNUTranslations.gettext to builtins._
210 language.translation.install()
211 self._active_language = language
212
213 if set_font and not self._using_env_font:
214 self._set_font(language.console_font)
215
216 def apply_console_font(self) -> None:
217 """Apply console font from FONT env var or active language mapping.

Callers 2

from_configMethod · 0.80

Calls 2

_set_fontMethod · 0.95
installMethod · 0.45

Tested by

no test coverage detected