[latex3-commits] [git/LaTeX3-latex3-pdfresources] splitting: remove public function pdfitem_dict, looks unneeded (or add something to pdf_text (01e8e02)
Ulrike Fischer
fischer at troubleshooting-tex.de
Mon Jul 6 11:20:44 CEST 2020
Repository : https://github.com/latex3/pdfresources
On branch : splitting
Link : https://github.com/latex3/pdfresources/commit/01e8e02c3da670362704ee100865be517ab2bbda
>---------------------------------------------------------------
commit 01e8e02c3da670362704ee100865be517ab2bbda
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date: Mon Jul 6 11:20:44 2020 +0200
remove public function pdfitem_dict, looks unneeded (or add something to pdf_text
>---------------------------------------------------------------
01e8e02c3da670362704ee100865be517ab2bbda
l3backend-pdf-extra.dtx | 6 +++---
l3pdfdict.dtx | 30 ++----------------------------
l3pdftools.dtx | 17 ++++++++++++++++-
3 files changed, 21 insertions(+), 32 deletions(-)
diff --git a/l3backend-pdf-extra.dtx b/l3backend-pdf-extra.dtx
index b8ca94c..aa17843 100644
--- a/l3backend-pdf-extra.dtx
+++ b/l3backend-pdf-extra.dtx
@@ -286,7 +286,7 @@
}
\exp_args:Nx \@@_backend_Page_primitive:n
{
- \prop_map_function:NN \g_@@_tmpa_prop \pdfdict_item:ne
+ \prop_map_function:NN \g_@@_tmpa_prop \@@_dict_item:ne
}
}
}
@@ -895,7 +895,7 @@
\prop_if_empty:cF
{ \pdfdict_gname:n {Core/Page/Resources/#1} }
{
- \pdfdict_item:ne { #1 }{ \pdf_object_ref:n {Page/Resources/#1}}
+ \@@_dict_item:ne { #1 }{ \pdf_object_ref:n {Page/Resources/#1}}
}
}
@@ -910,7 +910,7 @@
<<
\prop_map_function:cN
{ \pdfdict_gname:n { Core/backend_Page#1/Resources/Properties } }
- \pdfdict_item:ne
+ \@@_dict_item:ne
>>
}
%% add ExtGState etc
diff --git a/l3pdfdict.dtx b/l3pdfdict.dtx
index bb4f457..6c60f05 100644
--- a/l3pdfdict.dtx
+++ b/l3pdfdict.dtx
@@ -456,32 +456,6 @@
%</package>
% \end{macrocode}
% \end{macro}
-% \begin{macro}
-% {
-% \@@_item:nn,\@@_item:ne,\@@_item:nx,
-% \pdfdict_item:nn, \pdfdict_item:nx, \pdfdict_item:ne
-% }
-% Commands to output dict entries: The arguments are \meta{name}\meta{value}.
-% \meta{name} should be a valid pdf name without the slash. The commands don't
-% do any escaping. (It expects that the name has been escaped then the value
-% has been stored into the dictionary).
-% The commands don't check if the arguments are valid but if the value
-% is blank nothing is output. The commands are expandable if the content is.
-
-% \begin{macrocode}
-%<*package>
-\cs_new:Npn \@@_item:nn #1 #2 %#1 name, #2 value
- {
- \tl_if_blank:nF {#2} { /#1~#2~ }
- }
-\cs_generate_variant:Nn \@@_item:nn {ne,nx}
-
-\cs_set_eq:NN \pdfdict_item:nn \@@_item:nn
-\cs_generate_variant:Nn \pdfdict_item:nn {ne,nx}
-
-%</package>
-% \end{macrocode}
-% \end{macro}
%
% \begin{macro}
% {
@@ -675,14 +649,14 @@
%<*package>
\cs_new:Npn \@@_map:n #1 %dict
{
- \prop_map_function:cN { \@@_name:n { #1 } } \@@_item:ne
+ \prop_map_function:cN { \@@_name:n { #1 } } \__pdf_dict_item:ne
}
\cs_set_eq:NN \pdfdict_map:n \@@_map:n
\cs_new:Npn \@@_gmap:n #1 %dict
{
- \prop_map_function:cN { \@@_gname:n { #1 } } \@@_item:ne
+ \prop_map_function:cN { \@@_gname:n { #1 } } \__pdf_dict_item:ne
}
\cs_set_eq:NN \pdfdict_gmap:n \@@_gmap:n
diff --git a/l3pdftools.dtx b/l3pdftools.dtx
index 1365cae..76cc1e4 100644
--- a/l3pdftools.dtx
+++ b/l3pdftools.dtx
@@ -217,7 +217,22 @@
% \begin{macrocode}
%<@@=pdf>
% \end{macrocode}
-% \subsection{Conversions}
+% \subsection{Conversions and export functions}
+% At first a simple internal command to output key-value to |/key~value|. This is
+% needed in mapping commands. The commands don't
+% do any escaping, they expect that the name has been escaped then the value
+% has been stored into the dictionary.
+% The commands don't check if the arguments are valid but if the value
+% is blank nothing is output. The commands are expandable if the content is.
+% \begin{macro}{\@@_dict_item:nn, \@@_dict_item:ne,\@@_dict_item:nx,}
+% \begin{macrocode}
+\cs_new:Npn \@@_dict_item:nn #1 #2 %#1 name, #2 value
+ {
+ \tl_if_blank:nF {#2} { /#1~#2~ }
+ }
+\cs_generate_variant:Nn \@@_dict_item:nn {ne,nx}
+% \end{macrocode}
+% \end{macro}
% \begin{macro}{\pdf_text_convert:nn,\pdf_text_convert:nV}
% \begin{macro}{\pdf_text_convert:nnN}
% \begin{macro}{\@@_text_convert_name:n}
More information about the latex3-commits
mailing list.