diff --git a/markdown.dtx b/markdown.dtx index eec1a08ca..f894ad9a2 100644 --- a/markdown.dtx +++ b/markdown.dtx @@ -14409,6 +14409,19 @@ pdflatex --shell-escape document.tex % are rendered. The rest of the interface is inherited from the plain \TeX{} % interface (see Section <#sec:texinterface>). % +% The \LaTeX{} implementation redefines the plain \TeX{} logging macros (see +% Section <#sec:texinterfacelogging>) to use the \LaTeX{} \mref{PackageInfo}, +% \mref{PackageWarning}, and \mref{PackageError} macros. +% +% \end{markdown} +% \begin{macrocode} +\newcommand\markdownInfo[1]{\PackageInfo{markdown}{#1}}% +\newcommand\markdownWarning[1]{\PackageWarning{markdown}{#1}}% +\newcommand\markdownError[2]{\PackageError{markdown}{#1}{#2.}}% +\input markdown/markdown +% \end{macrocode} +% \begin{markdown} +% % The \LaTeX{} interface is implemented by the `markdown.sty` file, which % can be loaded from the \LaTeX{} document preamble as follows: % \end{markdown} @@ -14588,9 +14601,45 @@ document: } ``` +% +%<*latex> % \fi % \par % \begin{markdown} +% +% To enable the enumeration of \LaTeX{} options, we will maintain the +% \mdef{g_\@\@_latex_options_seq} sequence. +% +% \end{markdown} +% \begin{macrocode} +\ExplSyntaxOn +\seq_new:N \g_@@_latex_options_seq +% \end{macrocode} +% \begin{markdown} +% +% To enable the reflection of default \LaTeX{} options and their types, we +% will maintain the \mdef{g_\@\@_default_latex_options_prop} and +% \mdef{g_\@\@_latex_option_types_prop} property lists, respectively. +% +% \end{markdown} +% \begin{macrocode} +\prop_new:N \g_@@_latex_option_types_prop +\prop_new:N \g_@@_default_latex_options_prop +\tl_const:Nn \c_@@_option_category_latex_tl { latex } +\seq_put_right:NV \g_@@_option_categories_seq \c_@@_option_category_latex_tl +\cs_new:Nn + \@@_add_latex_option:nnn + { + \@@_add_option:Vnnn + \c_@@_option_category_latex_tl + { #1 } + { #2 } + { #3 } + } +% \end{macrocode} +% \iffalse +% +%<*manual-options> #### No default token renderer prototypes {#latexplain} @@ -14614,6 +14663,11 @@ from being loaded: %<*latex> % \fi % \begin{macrocode} +\@@_add_latex_option:nnn + { plain } + { boolean } + { false } +\ExplSyntaxOff \newif\ifmarkdownLaTeXPlain \markdownLaTeXPlainfalse \define@key{markdownOptions}{plain}[true]{% @@ -22063,16 +22117,8 @@ end % format~[@latex17, Section 9]. As a consequence, we can directly reuse the % existing plain \TeX{} implementation. % -% The \LaTeX{} implementation redefines the plain \TeX{} logging macros (see -% Section <#sec:texinterfacelogging>) to use the \LaTeX{} \mref{PackageInfo}, -% \mref{PackageWarning}, and \mref{PackageError} macros. -% % \end{markdown} % \begin{macrocode} -\newcommand\markdownInfo[1]{\PackageInfo{markdown}{#1}}% -\newcommand\markdownWarning[1]{\PackageWarning{markdown}{#1}}% -\newcommand\markdownError[2]{\PackageError{markdown}{#1}{#2.}}% -\input markdown/markdown \def\markdownVersionSpace{ }% \ProvidesPackage{markdown}[\markdownLastModified\markdownVersionSpace v% \markdownVersion\markdownVersionSpace markdown renderer]%