Skip to content

Commit

Permalink
Back to "scope" for states
Browse files Browse the repository at this point in the history
This longer name doesn't really help.
  • Loading branch information
josephwright committed Mar 2, 2018
1 parent 834b821 commit 0a51dfe
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 15 deletions.
6 changes: 3 additions & 3 deletions l3experimental/l3draw/l3draw-scopes.dtx
Expand Up @@ -177,19 +177,19 @@
% \end{variable}
% \end{variable}
%
% \begin{macro}{\draw_scope_state_begin:, \draw_scope_state_begin:}
% \begin{macro}{\draw_scope_begin:, \draw_scope_begin:}
% As well as the graphics (and \TeX{}) scope, also deal with global
% data structures.
% \begin{macrocode}
\cs_new_protected:Npn \draw_scope_state_begin:
\cs_new_protected:Npn \draw_scope_begin:
{
\driver_draw_scope_begin:
\group_begin:
\dim_set_eq:NN \l_@@_linewidth_dim \g_@@_linewidth_dim
\tl_set_eq:NN \l_@@_fill_color_tl \g_@@_fill_color_tl
\tl_set_eq:NN \l_@@_stroke_color_tl \g_@@_stroke_color_tl
}
\cs_new_protected:Npn \draw_scope_state_end:
\cs_new_protected:Npn \draw_scope_end:
{
\dim_gset_eq:NN \g_@@_linewidth_dim \l_@@_linewidth_dim
\tl_gset_eq:NN \g_@@_fill_color_tl \l_@@_fill_color_tl
Expand Down
10 changes: 5 additions & 5 deletions l3experimental/l3draw/l3draw.dtx
Expand Up @@ -246,27 +246,27 @@
% group (\cs{groupd_being:}/\cs{group_end:} pair): as such, they must be
% nested correctly.
%
% \begin{function}{\draw_scope_state_begin:, \draw_scope_state_end:}
% \begin{function}{\draw_scope_begin:, \draw_scope_end:}
% \begin{syntax}
% \cs{draw_scope_state_begin:}
% \cs{draw_scope_begin:}
% ...
% \cs{draw_scope_state_end:}
% \cs{draw_scope_end:}
% \end{syntax}
% Creates a scope for localisation of state settings within a drawing.
% A scope forms a \TeX{} group but will also localise global state
% variables (such as \cs{g_draw_linewidth_default_dim}), and driver-level
% concepts such as the termination of lines.
% \begin{demo}
% \draw_begin:
% \draw_scope_state_begin:
% \draw_scope_begin:
% \group_begin:
% \draw_linewidth:n { 2pt }
% \draw_path_rectangle:nn { 0 , 0 } { 2ex , 2ex }
% \draw_path_use:n { stroke }
% \group_end:
% \draw_path_rectangle:nn { 3ex , 0ex } { 2ex , 2ex }
% \draw_path_use:n { stroke }
% \draw_scope_state_end:
% \draw_scope_end:
% \draw_path_rectangle:nn { 6ex , 0ex } { 2ex , 2ex }
% \draw_path_use_clear:n { stroke }
% \draw_end:
Expand Down
6 changes: 3 additions & 3 deletions l3experimental/l3draw/testfiles/m3draw005.lvt
Expand Up @@ -31,16 +31,16 @@

\START

\TEST { \draw_scope_state_begin: }
\TEST { \draw_scope_begin: }
{
\test:n
{
\draw_scope_state_begin:
\draw_scope_begin:
\draw_linewidth:n { 1pt }
\draw_path_lineto:n { 1cm, 10cm }
\draw_path_lineto:n { 2cm , 20cm }
\draw_path_use_clear:n { stroke }
\draw_scope_state_end:
\draw_scope_end:
}
}

Expand Down
2 changes: 1 addition & 1 deletion l3experimental/l3draw/testfiles/m3draw005.ptex.tlg
@@ -1,7 +1,7 @@
This is a generated file for the LaTeX (2e + expl3) validation system.
Don't change this file in any respect.
============================================================
TEST 1: \draw_scope_state_begin:
TEST 1: \draw_scope_begin:
============================================================
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!
Expand Down
2 changes: 1 addition & 1 deletion l3experimental/l3draw/testfiles/m3draw005.tlg
@@ -1,7 +1,7 @@
This is a generated file for the LaTeX (2e + expl3) validation system.
Don't change this file in any respect.
============================================================
TEST 1: \draw_scope_state_begin:
TEST 1: \draw_scope_begin:
============================================================
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!
Expand Down
2 changes: 1 addition & 1 deletion l3experimental/l3draw/testfiles/m3draw005.uptex.tlg
@@ -1,7 +1,7 @@
This is a generated file for the LaTeX (2e + expl3) validation system.
Don't change this file in any respect.
============================================================
TEST 1: \draw_scope_state_begin:
TEST 1: \draw_scope_begin:
============================================================
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!
Expand Down
2 changes: 1 addition & 1 deletion l3experimental/l3draw/testfiles/m3draw005.xetex.tlg
@@ -1,7 +1,7 @@
This is a generated file for the LaTeX (2e + expl3) validation system.
Don't change this file in any respect.
============================================================
TEST 1: \draw_scope_state_begin:
TEST 1: \draw_scope_begin:
============================================================
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!
Expand Down

0 comments on commit 0a51dfe

Please sign in to comment.