[latex3-commits] [git/LaTeX3-latex3-latex3] master: Use @@ syntax for main color tl (ebcb4f8)

Joseph Wright joseph.wright at morningstar2.co.uk
Tue Feb 20 19:25:10 CET 2018


Repository : https://github.com/latex3/latex3
On branch  : master
Link       : https://github.com/latex3/latex3/commit/ebcb4f8d7d9b9cd03ae0dabf4392e6982a8ba8de

>---------------------------------------------------------------

commit ebcb4f8d7d9b9cd03ae0dabf4392e6982a8ba8de
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Mon Feb 19 22:27:41 2018 +0000

    Use @@ syntax for main color tl


>---------------------------------------------------------------

ebcb4f8d7d9b9cd03ae0dabf4392e6982a8ba8de
 l3experimental/l3color/l3color.dtx |   14 +++++++-------
 l3kernel/l3color-base.dtx          |   18 +++++++++++-------
 2 files changed, 18 insertions(+), 14 deletions(-)

diff --git a/l3experimental/l3color/l3color.dtx b/l3experimental/l3color/l3color.dtx
index 179abfe..568447c 100644
--- a/l3experimental/l3color/l3color.dtx
+++ b/l3experimental/l3color/l3color.dtx
@@ -446,7 +446,7 @@
       }
       {
         \__kernel_msg_error:nnn { color } { unknown-color } {#3}
-        \tl_set_eq:NN \l__color_current_tl \l_@@_named_black_tl
+        \tl_set_eq:NN \l_@@_current_tl \l_@@_named_black_tl
       }
   }
 %    \end{macrocode}
@@ -631,9 +631,9 @@
 %    \begin{macrocode}
 \cs_new_protected:Npn \@@_select:
   {
-    \@@_finalise:N \l__color_current_tl
-    \tl_set_eq:cN { l_@@_named_ . _tl } \l__color_current_tl
-    \__driver_color_select:V \l__color_current_tl
+    \@@_finalise:N \l_@@_current_tl
+    \tl_set_eq:cN { l_@@_named_ . _tl } \l_@@_current_tl
+    \__driver_color_select:V \l_@@_current_tl
   }
 \cs_new_protected:Npn \@@_finalise:N #1
   {
@@ -665,12 +665,12 @@
 %    \begin{macrocode}
 \cs_new_protected:Npn \color_select:n #1
   {
-    \@@_parse:nN {#1} \l__color_current_tl
+    \@@_parse:nN {#1} \l_@@_current_tl
     \@@_select:
   }
 \cs_new_protected:Npn \color_select:nn #1#2
   {
-    \@@_direct:nnN {#1} {#2} \l__color_current_tl
+    \@@_direct:nnN {#1} {#2} \l_@@_current_tl
     \@@_select:
   }
 %    \end{macrocode}
@@ -741,7 +741,7 @@
       {
         \tl_clear_new:c { l_@@_named_ #1 _tl }
         \str_if_eq:nnTF {#2} { . }
-          { \tl_set_eq:cN { l_@@_named_ #1 _tl } \l__color_current_tl }
+          { \tl_set_eq:cN { l_@@_named_ #1 _tl } \l_@@_current_tl }
           { \tl_set_eq:cc { l_@@_named_ #1 _tl } { l_@@_named_ #2 _tl } }
       }
       {
diff --git a/l3kernel/l3color-base.dtx b/l3kernel/l3color-base.dtx
index d3352bf..869c106 100644
--- a/l3kernel/l3color-base.dtx
+++ b/l3kernel/l3color-base.dtx
@@ -79,7 +79,7 @@
 % \subsection{Internal functions}
 %
 % \begin{variable}[added = 2017-06-15, updated = 2017-10-02]
-%   {\l__color_current_tl}
+%   {\l_@@_current_tl}
 %   The color currently active for foreground (text, \emph{etc.}) material.
 %   This is stored in the form of a color model followed by one or more
 %   values. There are four pre-defined models, three of which take numerical
@@ -102,7 +102,7 @@
 %   number of data entries these require will depend on the number of
 %   colors to be mixed.
 %   \begin{texnote}
-%     The content of \cs{l__color_current_tl} is space-separated as
+%     The content of \cs{l_@@_current_tl} is space-separated as
 %     this allows it to be used directly in specials in many common cases.
 %     This internal representation is close to that used by the \texttt{dvips}
 %     program.
@@ -119,6 +119,10 @@
 %<*initex|package>
 %    \end{macrocode}
 %
+%    \begin{macrocode}
+%<@@=color>
+%    \end{macrocode}
+%
 % \begin{macro}{\color_group_begin:, \color_group_end:}
 %   Grouping for color is almost the same as using the basic \cs{group_begin:}
 %   and \cs{group_end:} functions.  However, in vertical mode the end-of-group
@@ -140,23 +144,23 @@
 \cs_new_protected:Npn \color_ensure_current:
   {
 %<*package>
-    \__driver_color_pickup:N \l__color_current_tl
+    \__driver_color_pickup:N \l_@@_current_tl
 %</package>
-    \__driver_color_select:V \l__color_current_tl
+    \__driver_color_select:V \l_@@_current_tl
     \group_insert_after:N \__driver_color_reset:
   }
 %    \end{macrocode}
 % \end{macro}
 %
-% \begin{variable}{\l__color_current_tl}
+% \begin{variable}{\l_@@_current_tl}
 %   As the setting data is used only
 %   for specials, and those are always space-separated, it makes most sense to
 %   hold the internal information in that form. Any splitting is done by a
 %   delimited function but often the entire \texttt{tl} can be used as-is:
 %   see \texttt{l3drivers.dtx}.
 %    \begin{macrocode}
-\tl_new:N \l__color_current_tl
-\tl_set:Nn \l__color_current_tl { gray~0 }
+\tl_new:N \l_@@_current_tl
+\tl_set:Nn \l_@@_current_tl { gray~0 }
 %    \end{macrocode}
 % \end{variable}
 %





More information about the latex3-commits mailing list