nops_language {exams} | R Documentation |
Read NOPS Language Specifciation
Description
Read a NOPS language specification from a DCF file and optionally convert the language text to HTML.
Usage
nops_language(file, converter = c("none", "tth", "pandoc"), ...)
Arguments
file |
character. Path to a DCF file with a language specification.
See |
converter |
character. The HTML converter to be used for the language
text elements. Can be |
... |
further arguments passed to the |
Details
The NOPS exams infrastructure is internationalized and can be customized through
DCF files (borrowing the format from Debian configuration files). For a detailed
description see: https://www.R-exams.org/tutorials/nops_language/.
The DCF files typically either contain special characters as LaTeX commands or
in UTF-8 encoding. To handle the former case, a converter
can be applied
to convert the language texts to HTML.
Value
A list with all language components provided by the DCF file.
See Also
Examples
## English
en <- nops_language("en")
names(en)
en$NoChanges
## French (LaTeX vs. HTML)
nops_language("fr", converter = "none")$NoChanges
nops_language("fr", converter = "tth")$NoChanges
## French (HTML or Markdown via pandoc)
nops_language("fr", converter = "pandoc")$NoChanges
nops_language("fr", converter = "pandoc", to = "markdown_strict")$NoChanges