diff options
author | Karl Berry <karl@freefriends.org> | 2011-09-07 23:33:27 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2011-09-07 23:33:27 +0000 |
commit | f1cddb2ae051713a3d0b9efa1251d8f85d8131fc (patch) | |
tree | 47b6a38de15329b2ffd3a196e7d85e7ad1e93032 /Master/texmf-dist/source/latex/l3kernel/l3color.dtx | |
parent | ea06cd2704b8ed1c5278b20798ab9e3811e0ca4e (diff) |
l3kernel 2729 (5sep11)
git-svn-id: svn://tug.org/texlive/trunk@23865 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/l3kernel/l3color.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/l3kernel/l3color.dtx | 152 |
1 files changed, 152 insertions, 0 deletions
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3color.dtx b/Master/texmf-dist/source/latex/l3kernel/l3color.dtx new file mode 100644 index 00000000000..0570e50a575 --- /dev/null +++ b/Master/texmf-dist/source/latex/l3kernel/l3color.dtx @@ -0,0 +1,152 @@ +% \iffalse meta-comment +% +%% File: l3color.dtx Copyright(C) 2011 The LaTeX3 Project +%% +%% It may be distributed and/or modified under the conditions of the +%% LaTeX Project Public License (LPPL), either version 1.3c of this +%% license or (at your option) any later version. The latest version +%% of this license is in the file +%% +%% http://www.latex-project.org/lppl.txt +%% +%% This file is part of the "l3kernel bundle" (The Work in LPPL) +%% and all files in that bundle must be distributed together. +%% +%% The released version of this bundle is available from CTAN. +%% +%% ----------------------------------------------------------------------- +%% +%% The development version of the bundle can be found at +%% +%% http://www.latex-project.org/svnroot/experimental/trunk/ +%% +%% for those people who are interested. +%% +%%%%%%%%%%% +%% NOTE: %% +%%%%%%%%%%% +%% +%% Snapshots taken from the repository represent work in progress and may +%% not work or may contain conflicting material! We therefore ask +%% people _not_ to put them into distributions, archives, etc. without +%% prior consultation with the LaTeX Project Team. +%% +%% ----------------------------------------------------------------------- +%% +% +%<*driver|package> +\RequirePackage{l3names} +\GetIdInfo$Id: l3color.dtx 2717 2011-09-03 13:40:31Z joseph $ + {L3 Experimental colour support} +%</driver|package> +%<*driver> +\documentclass[full]{l3doc} +\begin{document} + \DocInput{\jobname.dtx} +\end{document} +%</driver> +% \fi +% +% \title{^^A +% The \textsf{l3drivers} package\\ Colour support^^A +% \thanks{This file describes v\ExplFileVersion, +% last revised \ExplFileDate.}^^A +% } +% +% \author{^^A +% The \LaTeX3 Project\thanks +% {^^A +% E-mail: +% \href{mailto:latex-team@latex-project.org} +% {latex-team@latex-project.org}^^A +% }^^A +% } +% +% \date{Released \ExplFileDate} +% +% \maketitle +% +% \begin{documentation} +% +% This module provides support for colour in \LaTeX3{}. At present, the +% material here is mainly intended to support a small number of low-level +% requirements in other \pkg{l3kernel} modules. +% +% \section{Colour in boxes} +% +% Controlling the colour of text in boxes requires a small number of control +% functions, so that the boxed material uses the colour at the point where +% it is set, rather than where it is used. +% +% \begin{function}{\color_group_begin:, \color_group_end:} +% \begin{syntax} +% \cs{color_group_begin:} +% \ldots +% \cs{color_group_end:} +% \end{syntax} +% Creates a colour group: one used to \enquote{trap} colour settings. +% \end{function} +% +% \begin{function}{\color_ensure_current:} +% \begin{syntax} +% \cs{color_ensure_current:} +% \end{syntax} +% Ensures that material inside a box will use the foreground colour +% at the point where the box is set, rather than that in force when the +% box is used. This function should usually be used within a +% \cs{color_group_begin:} \ldots \cs{color_group_end:} group. +% \end{function} +% +% \end{documentation} +% +% \begin{implementation} +% +% \section{\pkg{l3color} Implementation} +% +% \begin{macrocode} +%<*initex|package> +% \end{macrocode} +% +% \begin{macrocode} +%<*package> +\ProvidesExplPackage + {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} +\package_check_loaded_expl: +%</package> +% \end{macrocode} +% +% \begin{macro}{\color_group_begin:, \color_group_end:} +% Grouping for colour is almost the same as using the basic \cs{group_begin:} +% and \cs{group_end:} functions. However, in vertical mode the end-of-group +% needs a \cs{tex_par:D}, which in horizontal mode does nothing. +% \begin{macrocode} +\cs_new_eq:NN \color_group_begin: \group_begin: +\cs_new_protected_nopar:Npn \color_group_end: + { + \tex_par:D + \group_end: + } +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\color_ensure_current:} +% A driver-independent wrapper for setting the foreground colour to the +% current colour \enquote{now}. +% \begin{macrocode} +%<*initex> +\cs_new_protected_nopar:Npn \color_ensure_current: + { \driver_color_ensure_current: } +%</initex> +%<*package> +\cs_new_protected_nopar:Npn \color_ensure_current: { \set@color } +%</package> +% \end{macrocode} +% \end{macro} +% +% \begin{macrocode} +%</initex|package> +% \end{macrocode} +% +% \end{implementation} +% +% \PrintIndex
\ No newline at end of file |