[latex3-commits] [git/LaTeX3-latex3-pdfresources] splitting: use prefix for local/global dict (db979a4)

Ulrike Fischer fischer at troubleshooting-tex.de
Mon Jul 6 17:19:53 CEST 2020


Repository : https://github.com/latex3/pdfresources
On branch  : splitting
Link       : https://github.com/latex3/pdfresources/commit/db979a4df1b89946b2ecd7a486d18c4ff8a407cf

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

commit db979a4df1b89946b2ecd7a486d18c4ff8a407cf
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date:   Mon Jul 6 17:19:53 2020 +0200

    use prefix for local/global dict


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

db979a4df1b89946b2ecd7a486d18c4ff8a407cf
 hgeneric-experimental.def   |   2 +-
 l3backend-pdf-extra.dtx     |  38 +++----
 l3pdfcoredict.dtx           |  82 +++++++--------
 l3pdfdict.dtx               | 244 ++++++++++++++++----------------------------
 l3pdffile.dtx               |  24 ++---
 pdfresources.dtx            |  46 ++++-----
 testfiles/dict_if_empty.lvt |  12 +--
 testfiles/show.lvt          |   6 +-
 8 files changed, 191 insertions(+), 263 deletions(-)

diff --git a/hgeneric-experimental.def b/hgeneric-experimental.def
index 0eafc86..42f8372 100644
--- a/hgeneric-experimental.def
+++ b/hgeneric-experimental.def
@@ -1584,7 +1584,7 @@
            \keys_set:nn { hyp / trans }{style=R,#1}
            \pdf_object_now:nx { dict }
              {
-               \pdfdict_use:n {page/Trans}
+               \pdfdict_use:nn { l } {page/Trans}
              }
            \pdfcoredict_gput:nnx {Page}{Trans}{\pdf_object_last:}
            \group_end:
diff --git a/l3backend-pdf-extra.dtx b/l3backend-pdf-extra.dtx
index a3e85ef..bd63697 100644
--- a/l3backend-pdf-extra.dtx
+++ b/l3backend-pdf-extra.dtx
@@ -262,9 +262,9 @@
             {pdf at abspage}
             {0}
         }
-      \pdfdict_if_gexist:nF {Core/backend_Page\l_@@_tmpa_tl}
+      \pdfdict_if_exist:nnF { g } {Core/backend_Page\l_@@_tmpa_tl}
         {
-          \pdfdict_gnew:n          {Core/backend_Page\l_@@_tmpa_tl}
+          \pdfdict_new:nn { g }   {Core/backend_Page\l_@@_tmpa_tl}
         }
       %\__pdfcoredict_handler_gput:nnn {backend_Page\l_@@_tmpa_tl}{ #1 }{ #2 }
       %backend_Page has no handler.
@@ -276,10 +276,10 @@
   %issues the values stored in the global prop with dvi
   \cs_new_protected:Npn \@@_backend_ThisPage_gpush:n #1
     {
-      \prop_gset_eq:Nc \g_@@_tmpa_prop { \pdfdict_gname:n  { Core/Page } }
-      \prop_if_exist:cT  { \pdfdict_gname:n  { Core/backend_Page#1 } }
+      \prop_gset_eq:Nc \g_@@_tmpa_prop { \pdfdict_name:nn { g }  { Core/Page } }
+      \prop_if_exist:cT  { \pdfdict_name:nn { g }  { Core/backend_Page#1 } }
         {
-          \prop_map_inline:cn { \pdfdict_gname:n  { Core/backend_Page#1 } }
+          \prop_map_inline:cn { \pdfdict_name:nn { g }  { Core/backend_Page#1 } }
             {
               \prop_gput:Nnn \g_@@_tmpa_prop { ##1 }{ ##2 }
             }
@@ -397,7 +397,7 @@
 \cs_new_protected:Npn \@@_backend_ThisPage_gpush:n #1
   {
     \exp_args:Nx \@@_backend_Page_primitive:n
-      { \pdfdict_guse:n {Core/Page} }
+      { \pdfdict_use:nn { g } {Core/Page} }
   }
 %</dvipdfmx|xdvipdfmx>
 %<*dvips>
@@ -436,7 +436,7 @@
 \cs_new_protected:Npn \@@_backend_ThisPage_gpush:n #1
   {
     \exp_args:Nx \@@_backend_Page_primitive:n
-          { \pdfdict_guse:n {Core/Page} }
+          { \pdfdict_use:nn { g } {Core/Page} }
   }
 %</dvips>
 %    \end{macrocode}
@@ -470,7 +470,7 @@
 
 \clist_map_inline:Nn \c_@@_backend_PageResources_clist
       {
-        \pdfdict_gnew:n {Core/Page/Resources/#1}
+        \pdfdict_new:nn { g } {Core/Page/Resources/#1}
       }
 %</drivers>
 % pdftex and luatex
@@ -517,11 +517,11 @@
     \clist_map_inline:Nn \c_@@_backend_PageResources_clist
       {
         \prop_if_empty:cF
-          { \pdfdict_gname:n {Core/Page/Resources/##1} }
+          { \pdfdict_name:nn { g } {Core/Page/Resources/##1} }
           {
             \@@_backend_object_write:nx
               { Page/Resources/##1 }
-              { \pdfdict_guse:n {Core/Page/Resources/##1} }
+              { \pdfdict_use:nn { g } {Core/Page/Resources/##1} }
           }
      }
   }
@@ -546,7 +546,7 @@
 \cs_new_protected:Npn \@@_backend_PageResources_gput:nnn #1 #2 #3
   {
    % this is not used for output, but there is a test if the resource is empty
-   \prop_gput:cnn { \pdfdict_gname:n {Core/Page/Resources/#1} } { #2 }{ #3 }
+   \prop_gput:cnn { \pdfdict_name:nn { g } {Core/Page/Resources/#1} } { #2 }{ #3 }
    %objects are not filled with \pdf_object_write as this is not additive!
     \@@_backend:x
       {
@@ -699,7 +699,7 @@
   {
     \clist_map_inline:Nn \c_@@_backend_PageResources_clist
       {
-        \prop_if_empty:cF { \pdfdict_gname:n {Core/Page/Resources/##1} }
+        \prop_if_empty:cF { \pdfdict_name:nn { g } {Core/Page/Resources/##1} }
           {
             \__kernel_backend_literal:x
               {
@@ -819,9 +819,9 @@
                   {pdf at abspage}
                   {0}
               }
-            \pdfdict_if_gexist:nF { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
+            \pdfdict_if_exist:nnF { g } { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
               {
-                \pdfdict_gnew:n  { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
+                \pdfdict_new:nn { g }  { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
               }
             \exp_args:Nnxx\pdfdict_gput:nnn
               { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
@@ -854,9 +854,9 @@
                   {pdf at abspage}
                   {0}
               }
-            \pdfdict_if_gexist:nF { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
+            \pdfdict_if_exist:nnF { g } { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
               {
-                \pdfdict_gnew:n { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
+                \pdfdict_new:nn { g } { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
               }
             \exp_args:Nnxx\pdfdict_gput:nnn
               { Core/backend_Page\l_@@_tmpa_tl/Resources/Properties }
@@ -893,7 +893,7 @@
   \cs_new:Npn \@@_backend_PageResources_gpush_aux:n #1 %#1 ExtGState etc
     {
       \prop_if_empty:cF
-        { \pdfdict_gname:n {Core/Page/Resources/#1} }
+        { \pdfdict_name:nn { g } {Core/Page/Resources/#1} }
         {
           \@@_dict_item:ne { #1 }{ \pdf_object_ref:n {Page/Resources/#1}}
         }
@@ -904,12 +904,12 @@
        \exp_args:NNx \tex_global:D \tex_pdfpageresources:D
          {
            \prop_if_exist:cT
-             { \pdfdict_gname:n  { Core/backend_Page#1/Resources/Properties } }
+             { \pdfdict_name:nn { g }  { Core/backend_Page#1/Resources/Properties } }
              {
                /Properties~
                  <<
                    \prop_map_function:cN
-                     { \pdfdict_gname:n  { Core/backend_Page#1/Resources/Properties } }
+                     { \pdfdict_name:nn { g }  { Core/backend_Page#1/Resources/Properties } }
                      \@@_dict_item:ne
                  >>
              }
diff --git a/l3pdfcoredict.dtx b/l3pdfcoredict.dtx
index 6facce8..e4a6838 100644
--- a/l3pdfcoredict.dtx
+++ b/l3pdfcoredict.dtx
@@ -504,7 +504,7 @@
 %    \begin{macrocode}
 \cs_new_protected:Npn \pdfcoredict_gput:nnn #1 #2 #3
   {
-    \pdfdict_if_gexist:nTF { Core/#1 }
+    \pdfdict_if_exist:nnTF { g }{ Core/#1 }
       {
         \@@_handler_gput:nnn { #1 }{ #2 }{ #3 }
       }
@@ -615,7 +615,7 @@
         \msg_none:nnn { pdfcoredict }{ empty-value }{ /#1/#2 }
       }
       {
-        \pdfdict_if_gexist:nTF { Core/#1 }
+        \pdfdict_if_exist:nnTF { g } { Core/#1 }
           {
             \cs_if_exist:cTF
               { @@_handler/#1/?_gput:nn } %general, name independant handler
@@ -626,7 +626,7 @@
                   { \use:c {@@_handler/#1/#2_gput:n} {#3} } %special handler
                   {
                     \prop_gput:cnn
-                      { \pdfdict_gname:n { Core/#1 } }{ #2 } { #3 }
+                      { \pdfdict_name:nn { g } { Core/#1 } }{ #2 } { #3 }
                   }
               }
           }
@@ -642,14 +642,14 @@
 \cs_new_protected:Npn \@@_get:nnN  #1 #2 #3 %path,key,macro
   {
     \prop_get:cnN
-      { \pdfdict_gname:n { Core/#1 } }
+      { \pdfdict_name:nn { g } { Core/#1 } }
       { #2 } #3
   }
 
 
 \cs_new_protected:Npn \@@_handler_gremove:nn #1 #2 %path,key
   {
-    \pdfdict_if_gexist:nTF { Core/#1 }
+    \pdfdict_if_exist:nnTF { g } { Core/#1 }
           {
             \cs_if_exist:cTF
               { @@_handler/#1/?_gremove:n } %general, name independant handler
@@ -660,7 +660,7 @@
                   { \use:c {@@_handler/#1/#2_gremove:} } %special handler
                   {
                     \prop_gremove:cn
-                      { \pdfdict_gname:n { Core/#1 } }{ #2 }
+                      { \pdfdict_name:nn { g } { Core/#1 } }{ #2 }
                   }
               }
           }
@@ -671,10 +671,10 @@
 
 \cs_new_protected:Npn \@@_gremove:nn #1 #2 %path,key
   {
-    \pdfdict_if_gexist:nTF { Core/#1 }
+    \pdfdict_if_exist:nnTF { g } { Core/#1 }
           {
             \prop_gremove:cn
-              { \pdfdict_gname:n { Core/#1 } }{ #2 }
+              { \pdfdict_name:nn { g } { Core/#1 } }{ #2 }
           }
           {
             \msg_error:nnn { pdfcoredict } { unknown-dict } { #1 }
@@ -688,12 +688,12 @@
       { @@_handler/#2/?_show: } %general, name independant handler
       { \use:c {@@_handler/#2/?_show:} }
       {
-        \prop_if_exist:cTF { \pdfdict_gname:n { Core/#2 } }
+        \prop_if_exist:cTF { \pdfdict_name:nn { g } { Core/#2 } }
           {
              #1
                { pdfcoredict } { show-dict }
                { \tl_to_str:n {#2} }
-               { \prop_map_function:cN {\pdfdict_gname:n { Core/#2 }} \msg_show_item:nn }
+               { \prop_map_function:cN {\pdfdict_name:nn { g } { Core/#2 }} \msg_show_item:nn }
                { } { }
           }
           {
@@ -704,7 +704,7 @@
 
 \cs_new_protected:Npn \@@_show:n #1  %path
   {
-    \prop_show:c { \pdfdict_gname:n { Core/#1 } }
+    \prop_show:c { \pdfdict_name:nn { g } { Core/#1 } }
   }
 %    \end{macrocode}
 % \end{macro}
@@ -719,7 +719,7 @@
 %    \begin{macrocode}
 \cs_new_protected:Npn \pdfcoredict_gremove:nn #1 #2
   {
-    \pdfdict_if_gexist:nTF { Core/#1 }
+    \pdfdict_if_exist:nnTF { g } { Core/#1 }
       {
         \@@_handler_gremove:nn { #1 }{ #2 }
       }
@@ -731,7 +731,7 @@
 % \subsection{The Info dictionary}
 % Initialization of the dictionary:
 %    \begin{macrocode}
-\pdfdict_gnew:n {Core/Info}
+\pdfdict_new:nn { g } {Core/Info}
 %    \end{macrocode}
 %
 % \begin{macro}{\@@_Info_gpush:}
@@ -741,15 +741,15 @@
 % push to the register command / issue the special
 \cs_new_protected:Npn \@@_Info_gpush:
   {
-    \prop_map_function:cN  { \pdfdict_gname:n {Core/Info} } \__pdf_backend_info_gput:nn
-    \prop_gclear:c { \pdfdict_gname:n {Core/Info} }
+    \prop_map_function:cN  { \pdfdict_name:nn { g } {Core/Info} } \__pdf_backend_info_gput:nn
+    \prop_gclear:c { \pdfdict_name:nn { g } {Core/Info} }
   }
 %    \end{macrocode}
 % \end{macro}
 % \subsection{The Pages dictionary code}
 % At first the initialisation
 %     \begin{macrocode}
-\pdfdict_gnew:n {Core/Pages}
+\pdfdict_new:nn { g } {Core/Pages}
 %    \end{macrocode}
 %
 % \begin{macro}{\@@_Pages_gpush:}
@@ -761,7 +761,7 @@
   {
     \exp_args:Nx \__pdf_backend_Pages_primitive:n
       {
-        \pdfdict_guse:n {Core/Pages}
+        \pdfdict_use:nn { g } {Core/Pages}
       }
   }
 
@@ -770,8 +770,8 @@
 % \subsection{The Page and ThisPage dictionary}
 % At first the initialisation.
 %    \begin{macrocode}
-\pdfdict_gnew:n { Core/Page }
-\pdfdict_gnew:n { Core/ThisPage }
+\pdfdict_new:nn { g } { Core/Page }
+\pdfdict_new:nn { g } { Core/ThisPage }
 
 %handler for pdfcoredict
 \cs_new_protected:cpn { @@_handler/Page/?_gput:nn } #1 #2
@@ -787,7 +787,7 @@
 % handler for pdfcoredict
 \cs_new_protected:cpn { @@_handler/ThisPage/?_gput:nn } #1 #2
   {
-    \prop_gput:cnn  { \pdfdict_gname:n { Core/ThisPage } }{ #1 } { #2 }
+    \prop_gput:cnn  { \pdfdict_name:nn { g } { Core/ThisPage } }{ #1 } { #2 }
     \bool_if:NT \g__pdf_Core_active_bool
       {
         \__pdf_backend_ThisPage_gput:nn { #1 }{ #2 }
@@ -841,7 +841,7 @@
 %  \begin{macro}{ \@@_catalog_XX_gput:n }
 % Various commands to handle subentries and special cases.
 %    \begin{macrocode}
-\pdfdict_gnew:n {Core/Catalog}
+\pdfdict_new:nn { g } {Core/Catalog}
 
 \clist_const:Nn \c_@@_Catalog_toplevel_clist
   {
@@ -878,7 +878,7 @@
 
 \clist_map_inline:Nn \c_@@_Catalog_sub_clist
   {
-    \pdfdict_gnew:n {Core/Catalog/#1}
+    \pdfdict_new:nn { g } {Core/Catalog/#1}
   }
 
 
@@ -926,7 +926,7 @@
     \use:c { @@_/Catalog/Requirements_gpush: }
     \use:c { @@_/Catalog/ViewerPreferences_gpush: }
     % output the single values:
-    \prop_map_function:cN { \pdfdict_gname:n {Core/Catalog} }  \__pdf_backend_catalog_gput:nn
+    \prop_map_function:cN { \pdfdict_name:nn { g } {Core/Catalog} }  \__pdf_backend_catalog_gput:nn
     % output names tree:
     \use:c { @@_/Catalog/Names/EmbeddedFiles_gpush: }
   }
@@ -938,12 +938,12 @@
 \cs_new_protected:cpn { @@_/Catalog/AA_gpush: }
   {
     \prop_if_empty:cF
-     { \pdfdict_gname:n { Core/Catalog/AA } }
+     { \pdfdict_name:nn { g } { Core/Catalog/AA } }
      {
        \__pdf_backend_object_new:nn  { g_@@_/Catalog/AA_obj } { dict }
        \__pdf_backend_object_write:nx
             { g_@@_/Catalog/AA_obj }
-            { \pdfdict_guse:n { Core/Catalog/AA } }
+            { \pdfdict_use:nn { g } { Core/Catalog/AA } }
        \exp_args:Nnx
          \__pdf_backend_catalog_gput:nn
            {AA}
@@ -976,7 +976,7 @@
             { \seq_use:cn { g_@@_/Catalog/AcroForm/Fields_seq } {~} }
         \exp_args:Nnnx
           \prop_gput:cnn %we have to use \prop here to avoid the handler ..
-            { \pdfdict_gname:n { Core/Catalog/AcroForm } }
+            { \pdfdict_name:nn { g } { Core/Catalog/AcroForm } }
             { Fields }
             { \__pdf_backend_object_ref:n { g_@@_/Catalog/AcroForm/Fields_obj } }
       }
@@ -989,43 +989,43 @@
             { \seq_use:cn { g_@@_/Catalog/AcroForm/CO_seq } {~} }
         \exp_args:Nnnx
           \prop_gput:cnn %we have to use \prop here to avoid the handler ..
-            { \pdfdict_gname:n { Core/Catalog/AcroForm } }
+            { \pdfdict_name:nn { g } { Core/Catalog/AcroForm } }
             { CO }
             { \__pdf_backend_object_ref:n { g_@@_/Catalog/AcroForm/CO_obj } }
       }
-     \prop_if_empty:cF { \pdfdict_gname:n { Core/Catalog/AcroForm/DR/Font}}
+     \prop_if_empty:cF { \pdfdict_name:nn { g } { Core/Catalog/AcroForm/DR/Font}}
        {
          \__pdf_backend_object_new:nn { g_@@_/Catalog/AcroForm/DR/Font_obj } {dict}
          \exp_args:Nnx
            \__pdf_backend_object_write:nn
              { g_@@_/Catalog/AcroForm/DR/Font_obj }
-             { \pdfdict_guse:n { Core/Catalog/AcroForm/DR/Font } }
+             { \pdfdict_use:nn { g } { Core/Catalog/AcroForm/DR/Font } }
          \exp_args:Nnnx
            \prop_gput:cnn %we have to use \prop here to avoid the handler ..
-             { \pdfdict_gname:n { Core/Catalog/AcroForm/DR } }
+             { \pdfdict_name:nn { g } { Core/Catalog/AcroForm/DR } }
              { Font }
              { \__pdf_backend_object_ref:n { g_@@_/Catalog/AcroForm/DR/Font_obj } }
        }
-     \prop_if_empty:cF { \pdfdict_gname:n { Core/Catalog/AcroForm/DR}}
+     \prop_if_empty:cF { \pdfdict_name:nn { g } { Core/Catalog/AcroForm/DR}}
        {
          \__pdf_backend_object_new:nn { g_@@_/Catalog/AcroForm/DR_obj } {dict}
          \exp_args:Nnx
            \__pdf_backend_object_write:nn
              { g_@@_/Catalog/AcroForm/DR_obj }
-             { \pdfdict_guse:n { Core/Catalog/AcroForm/DR } }
+             { \pdfdict_use:nn { g } { Core/Catalog/AcroForm/DR } }
          \exp_args:Nnnx
            \prop_gput:cnn %we have to use \prop here to avoid the handler ..
-             { \pdfdict_gname:n {Core/Catalog/AcroForm } }
+             { \pdfdict_name:nn { g } {Core/Catalog/AcroForm } }
              { DR }
              { \__pdf_backend_object_ref:n { g_@@_/Catalog/AcroForm/DR_obj } }
        }
-     \prop_if_empty:cF { \pdfdict_gname:n { Core/Catalog/AcroForm} }
+     \prop_if_empty:cF { \pdfdict_name:nn { g } { Core/Catalog/AcroForm} }
        {
          \__pdf_backend_object_new:nn { g_@@_/Catalog/AcroForm_obj } {dict}
          \exp_args:Nnx
            \__pdf_backend_object_write:nn
              { g_@@_/Catalog/AcroForm_obj }
-             { \pdfdict_guse:n { Core/Catalog/AcroForm } }
+             { \pdfdict_use:nn { g } { Core/Catalog/AcroForm } }
          \exp_args:Nnnx
            \@@_handler_gput:nnn
              { Catalog }
@@ -1068,13 +1068,13 @@
 \cs_new_protected:cpn { @@_/Catalog/MarkInfo_gpush: }
   {
     \prop_if_empty:cF
-     { \pdfdict_gname:n { Core/Catalog/MarkInfo } }
+     { \pdfdict_name:nn { g } { Core/Catalog/MarkInfo } }
      {
        \__pdf_backend_object_new:nn  { g_@@_/Catalog/MarkInfo_obj } { dict }
        \exp_args:Nnx
          \__pdf_backend_object_write:nn
             { g_@@_/Catalog/MarkInfo_obj }
-            { \pdfdict_guse:n {Core/Catalog/MarkInfo } }
+            { \pdfdict_use:nn { g } {Core/Catalog/MarkInfo } }
        \exp_args:Nnx
          \__pdf_backend_catalog_gput:nn
            {MarkInfo}
@@ -1190,13 +1190,13 @@
 \cs_new_protected:cpn { @@_/Catalog/ViewerPreferences_gpush: }
   {
     \prop_if_empty:cF
-     { \pdfdict_gname:n { Core/Catalog/ViewerPreferences } }
+     { \pdfdict_name:nn { g } { Core/Catalog/ViewerPreferences } }
      {
        \__pdf_backend_object_new:nn  { g_@@_/Catalog/ViewerPreferences_obj } { dict }
        \exp_args:Nnx
          \__pdf_backend_object_write:nn
             { g_@@_/Catalog/ViewerPreferences_obj }
-            { \pdfdict_guse:n {Core/Catalog/ViewerPreferences } }
+            { \pdfdict_use:nn { g } {Core/Catalog/ViewerPreferences } }
        \exp_args:Nnx
          \__pdf_backend_catalog_gput:nn
            {ViewerPreferences}
@@ -1214,7 +1214,7 @@
 % \begin{macro}{ Handler}
 % EmbeddedFiles is an array and needs a special handler to add values.
 %    \begin{macrocode}
-\pdfdict_gnew:n { Core/Catalog/Names }
+\pdfdict_new:nn { g } { Core/Catalog/Names }
 
 \cs_new_protected:cpn { @@_handler/Catalog/Names/EmbeddedFiles_gput:n } #1
   {
@@ -1241,7 +1241,7 @@
 % \end{macro}
 % \subsection{ xform / Properties }
 %    \begin{macrocode}
-\pdfdict_gnew:n {Core/Xform/Resources/Properties}
+\pdfdict_new:nn { g } {Core/Xform/Resources/Properties}
 %    \end{macrocode}
 %    \begin{macrocode}
 %</package>
diff --git a/l3pdfdict.dtx b/l3pdfdict.dtx
index 19e2b6c..9c732f7 100644
--- a/l3pdfdict.dtx
+++ b/l3pdfdict.dtx
@@ -64,14 +64,18 @@
 % a local and a global version exists.
 
 % \subsection{User Commands}
-% \begin{function}[added = 2020-04-21]
-%   {\pdfdict_new:n,\pdfdict_gnew:n}
+% \begin{function}[updated = 2020-07-06]
+%   {\pdfdict_new:nn}
 %   \begin{syntax}
-%     \cs{pdfdict_new:n}  \Arg{local dictionary name}\\
-%     \cs{pdfdict_gnew:n} \Arg{global dictionary name}\\
+%     \cs{pdfdict_new:nn} \Arg{type prefix}  \Arg{dictionary name}\\
 %   \end{syntax}
-% This function create a new local or global dictionary. The commands are only
-% small wrappers around \cs{prop_new:c}, but use a special name space.
+% \begin{NOTE}{UF}
+% perhaps the type prefix will be extended to |g_module| at some time.
+% Leaving this open for now
+% \end{NOTE}
+% This function create a new local or global dictionary. \Arg{type prefix} should
+% be either \texttt{l} for a local or \texttt{g} for a global dictionary.
+% The commands are only small wrappers around \cs{prop_new:c}, but use a special name space.
 % It is possible to create a local and a global with the same name, but it is
 % recommended to use lowercase for global and uppercase for global dictionaries.
 % \end{function}
@@ -87,16 +91,15 @@
 % If \Arg{local/global dictionary name_2} doesn't exist yet, an error will be raised.
 %
 % \end{function}
-% \begin{function}[EXP,added = 2020-06-14]
-%   {\pdfdict_name:n,\pdfdict_gname:n}
+% \begin{function}[EXP,updated = 2020-07-06]
+%   {\pdfdict_name:nn}
 %   \begin{syntax}
-%     \cs{pdfdict_name:n}  \Arg{local dictionary name}\\
-%     \cs{pdfdict_gname:n} \Arg{global dictionary name}
+%     \cs{pdfdict_name:n} \Arg{type prefix} \Arg{dictionary name}\\
 %   \end{syntax}
 % These command expand to the internal name. With these commands
 % it is possible to use standard commands of the \texttt{prop} module
 % to deal with the dictionaries. For example\\
-% |\prop_clear:c { \pdfdict_name:n { name }}|
+% |\prop_clear:c { \pdfdict_name:nn {l} { name }}|
 % \end{function}
 % \begin{function}[added = 2020-04-06]
 %   {\pdfdict_put:nnn, \pdfdict_gput:nnn}
@@ -105,7 +108,7 @@
 %     \cs{pdfdict_gput:nnn} \Arg{global dictionary} \Arg{name} \Arg{value}
 %   \end{syntax}
 % This function puts \Arg{name} \Arg{value} locally or globally in the
-% \Arg{dictionary} created with \cs{pdfdict_new:n} or \cs{pdfdict_gnew:n}.
+% \Arg{dictionary} created with \cs{pdfdict_new:nn}.
 % \Arg{name} should be a PDF Name without the starting slash. It will be stored
 % with \cs{str_convert_pdfname}, so will be automatically correctly escaped in case
 % it contains slashes, spaces or other chars not allowed in a PDF name.
@@ -120,10 +123,9 @@
 % \Arg{value} to be expanded nor not expanded by the backend commands.
 % \end{function}
 % \begin{function}[EXP,added = 2020-04-21]
-%   {\pdfdict_use:n , \pdfdict_guse:n }
+%   {\pdfdict_use:nn  }
 %   \begin{syntax}
-%     \cs{pdfdict_use:n}   \Arg{local dictionary}\\
-%     \cs{pdfdict_guse:n}  \Arg{global dictionary}
+%     \cs{pdfdict_use:nn}  \Arg{type prefix} \Arg{local dictionary}\\
 %   \end{syntax}
 %   This outputs the property list of the dictionary as a list of
 %   \texttt{/key value} pairs.
@@ -139,30 +141,27 @@
 %   If both a local and a global dictionary with the name \Arg{dictionary}
 %   exists it will show both.
 %\end{function}
-%\begin{function}[EXP, pTF,added = 2020-04-08]
-%   { \pdfdict_if_exist:n, \pdfdict_if_gexist:n  }
+%\begin{function}[EXP, pTF,updated = 2020-07-06]
+%   { \pdfdict_if_exist:nn  }
 %   \begin{syntax}
-%     \cs{pdfdict_if_exist:n}   \Arg{local dictionary}\\
-%     \cs{pdfdict_if_gexist:n}  \Arg{global dictionary}
+%     \cs{pdfdict_if_exist:n} \Arg{type prefix}  \Arg{dictionary}\\
 %   \end{syntax}
 %   This tests if the dictionary exists.
 % \end{function}
-% \begin{function}[EXP, pTF,added = 2020-04-08]
-%   { \pdfdict_if_empty:n, \pdfdict_if_gempty:n }
+% \begin{function}[EXP, pTF,updated = 2020-07-06]
+%   { \pdfdict_if_empty:nn }
 %   \begin{syntax}
-%     \cs{pdfdict_if_empty:n}  \Arg{local dictionary}\\
-%     \cs{pdfdict_if_gempty:n}  \Arg{global dictionary}
+%     \cs{pdfdict_if_empty:nn}  \Arg{type prefix} \Arg{dictionary}\\
 %   \end{syntax}
 %   This tests if the dictionary is empty. The result is false if the
 %   dictionary doesn't exist.
 % \end{function}
-% \begin{function}[added = 2020-04-07]
-%   {\pdfdict_get:nn, \pdfdict_gget:nn  }
+% \begin{function}[added = 2020-07-06]
+%   {\pdfdict_get:nnnN }
 %   \begin{syntax}
-%     \cs{pdfdict_get:nnN}  \Arg{local dictionary}  \Arg{name} \meta{tl var}\\
-%     \cs{pdfdict_gget:nnN} \Arg{global dictionary} \Arg{name} \meta{tl var}
+%     \cs{pdfdict_get:nnnN} \Arg{type prefix} \Arg{dictionary}  \Arg{name} \meta{tl var}\\
 %   \end{syntax}
-%   Recovers the \meta{value} stored by \cs{pdfdict_put:nnn} and
+%   Recovers the \meta{value} stored by \cs{pdfdict_put:nnn} or
 %   \cs{pdfdict_gput:nnn}
 %   for \meta{name} and places this in the \meta{token list
 %   variable}. If \meta{name} is not found
@@ -274,7 +273,7 @@
 % Two seq to store the used names for diagnostics.
 %    \begin{macrocode}
 %<*package>
-\seq_new:N \g_@@_names_seq
+\seq_new:N \g_@@_lnames_seq
 \seq_new:N \g_@@_gnames_seq
 %</package>
 %    \end{macrocode}
@@ -282,66 +281,41 @@
 %
 % \begin{macro}
 %   {
-%    \@@_name:n, \pdfdict_name:n,
-%    \@@_gname:n,\pdfdict_gname:n,
-%    \@@_new:n,  \pdfdict_new:n,
-%    \@@_gnew:n, \pdfdict_gnew:n
+%    \@@_name:nn, \pdfdict_name:nn,
+%    \@@_new:nn,  \pdfdict_new:nn,
 %   }
 %
 %   This are the commands to create new dictionaries and to access their internal
 %   name.
 %    \begin{macrocode}
 %<*package>
-%local
-\cs_new:Npn \@@_name:n #1  % #1 dictionary name
-  {
-    l_@@_/#1_prop
-  }
-\cs_set_eq:NN \pdfdict_name:n \@@_name:n
-
-%global
-\cs_new:Npn \@@_gname:n #1 % #1 dictionary name
+\cs_new:Npn \@@_name:nn #1 #2  % #1 l or g, #2 dictionary name
   {
-    g_@@_/#1_prop
+    #1_@@_/#2_prop
   }
-\cs_set_eq:NN \pdfdict_gname:n \@@_gname:n
+\cs_set_eq:NN \pdfdict_name:nn \@@_name:nn
 
-%local
-\cs_new_protected:Npn \@@_new:n #1
+\cs_new_protected:Npn \@@_new:nn #1 #2
   {
-    \@@_if_exist:nTF { #1 }
+    \@@_if_exist:nnTF { #1 } { #2 }
       {
         \msg_error:nnxx
           { pdfdict }
           { dict-already-defined }
           { \tl_to_str:n {#1}}
-          { local }
+          { #1-type }
        }
        {
-         \prop_new:c  { \@@_name:n { #1 } }
-         \seq_gput_right:Nn \g_@@_names_seq { #1 }
+         \prop_new:c  { \@@_name:nn { #1 } { #2 } }
+         \seq_if_exist:cT {g_@@_#1names_seq}
+           {
+            \seq_gput_right:cn {g_@@_#1names_seq} { #2 }
+           }
        }
   }
 
-\cs_set_eq:NN \pdfdict_new:n \@@_new:n
+\cs_set_eq:NN \pdfdict_new:nn \@@_new:nn
 
-%global
-\cs_new_protected:Npn \@@_gnew:n #1
-  {
-    \@@_if_gexist:nTF { #1 }
-      {
-        \msg_error:nnxx
-          { pdfdict }
-          { dict-already-defined }
-          { \tl_to_str:n {#1}}
-          { global }
-       }
-      {
-        \prop_new:c  { \@@_gname:n { #1 } }
-        \seq_gput_right:Nn \g_@@_gnames_seq { #1 }
-      }
-  }
-\cs_set_eq:NN \pdfdict_gnew:n \@@_gnew:n
 %</package>
 %    \end{macrocode}
 % \end{macro}
@@ -354,13 +328,13 @@
 %<*package>
 \cs_new_protected:Npn \@@_set_eq:nn #1 #2
   {
-    \@@_if_exist:nTF { #2 }
+    \@@_if_exist:nnTF { l } { #2 }
       {
-        \@@_if_exist:nF { #1 }
+        \@@_if_exist:nnF { l } { #1 }
           {
-            \@@_new:n { #1 }
+            \@@_new:nn { l } { #1 }
           }
-        \prop_set_eq:cc { \@@_name:n {#1} }{ \@@_name:n {#2} }
+        \prop_set_eq:cc { \@@_name:nn { l } {#1} }{ \@@_name:nn { l } {#2} }
       }
       {
          \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } { local }
@@ -371,13 +345,13 @@
 
 \cs_new_protected:Npn \@@_gset_eq:nn #1 #2
   {
-    \@@_if_gexist:nTF { #2 }
+    \@@_if_exist:nnTF { g } { #2 }
       {
-        \@@_if_gexist:nF { #1 }
+        \@@_if_exist:nnF { g } { #1 }
           {
-            \@@_gnew:n { #1 }
+            \@@_new:nn { g } { #1 }
           }
-        \prop_set_eq:cc { \@@_gname:n {#1} }{ \@@_gname:n {#2} }
+        \prop_set_eq:cc { \@@_name:nn { g } {#1} }{ \@@_name:nn { g } {#2} }
       }
       {
          \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } { global }
@@ -390,68 +364,44 @@
 % \end{macro}
 % \begin{macro}
 %   {
-%     \@@_if_exist:n,  \pdfdict_if_exist:n,
-%     \@@_if_gexist:n, \pdfdict_if_gexist:n,
+%     \@@_if_exist:nn,  \pdfdict_if_exist:nn,
 %   }
 %
 % Existence tests.
 %    \begin{macrocode}
 %<*package>
 %local
-\prg_new_conditional:Npnn \@@_if_exist:n #1 { p , T , F , TF }
+\prg_new_conditional:Npnn \@@_if_exist:nn #1 #2 { p , T , F , TF }
   {
     \prop_if_exist:cTF
-      { \@@_name:n { #1 }  }
+      { \@@_name:nn { #1 } { #2 }  }
       { \prg_return_true:  }
       { \prg_return_false: }
   }
 \prg_set_eq_conditional:NNn
-  \pdfdict_if_exist:n \@@_if_exist:n { p , T , F , TF }
-
-%global
-\prg_new_conditional:Npnn \@@_if_gexist:n #1 { p , T , F , TF }
-  {
-    \prop_if_exist:cTF
-      { \@@_gname:n { #1 } }
-      { \prg_return_true:  }
-      { \prg_return_false: }
-  }
+  \pdfdict_if_exist:nn \@@_if_exist:nn { p , T , F , TF }
 
-\prg_set_eq_conditional:NNn
-  \pdfdict_if_gexist:n \@@_if_gexist:n { p , T , F , TF }
 %</package>
 %    \end{macrocode}
 % \end{macro}
 % \begin{macro}
 %   {
-%     \@@_if_empty:n,  \pdfdict_if_empty:n,
-%     \@@_if_gempty:n, \pdfdict_if_gempty:n,
+%     \@@_if_empty:nn,  \pdfdict_if_empty:nn,
 %   }
 %
 % Tests for emptiness.
 %    \begin{macrocode}
 %<*package>
-\prg_new_conditional:Npnn \@@_if_empty:n #1 { p , T , F , TF }
-  {
-    \prop_if_empty:cTF
-      { \@@_name:n { #1 }  }
-      { \prg_return_true:  }
-      { \prg_return_false: }
-  }
-
-\prg_set_eq_conditional:NNn
-  \pdfdict_if_empty:n \@@_if_empty:n { p , T , F , TF }
-
-\prg_new_conditional:Npnn \@@_if_gempty:n #1 { p , T , F , TF }
+\prg_new_conditional:Npnn \@@_if_empty:nn #1 #2 { p , T , F , TF }
   {
     \prop_if_empty:cTF
-      { \@@_gname:n { #1 } }
+      { \@@_name:nn { #1 } { #2 }  }
       { \prg_return_true:  }
       { \prg_return_false: }
   }
 
 \prg_set_eq_conditional:NNn
-  \pdfdict_if_gempty:n \@@_if_gempty:n { p , T , F , TF }
+  \pdfdict_if_empty:nn \@@_if_empty:nn { p , T , F , TF }
 
 %</package>
 %    \end{macrocode}
@@ -468,17 +418,17 @@
 % and that empty values are ignored.
 %    \begin{macrocode}
 %<*package>
-\cs_new_protected:Npn \@@_put:nnn #1 #2 #3  %#1 dict, #2 name, #3 value
+\cs_new_protected:Npn \@@_put:nnn #1 #2 #3  %#1 (local) dict, #2 name, #3 value
   {
     \tl_if_blank:nTF { #3 }
       {
         \msg_none:nnnn { pdfdict }{ empty-value }{ #2 } { #1 }
       }
       {
-        \@@_if_exist:nTF { #1 }
+        \@@_if_exist:nnTF { l } { #1 }
           {
             \exp_args:Nnx \prop_put:cnn
-              { \@@_name:n { #1 } }{ \str_convert_pdfname:n { #2 } } { #3 }
+              { \@@_name:nn { l } { #1 } }{ \str_convert_pdfname:n { #2 } } { #3 }
           }
           {
             \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } { local }
@@ -490,17 +440,17 @@
 \cs_set_eq:NN \pdfdict_put:nnn \@@_put:nnn
 \cs_generate_variant:Nn \pdfdict_put:nnn {nnx,nno}
 
-\cs_new_protected:Npn \@@_gput:nnn #1 #2 #3  %#1 dict, #2 name, #3 value
+\cs_new_protected:Npn \@@_gput:nnn #1 #2 #3  %#1 global dict, #2 name, #3 value
   {
     \tl_if_empty:nTF { #3 }
       {
         \msg_none:nnn { pdfdict }{ empty-value }{ #2 } { #1 }
       }
       {
-        \@@_if_gexist:nTF { #1 }
+        \@@_if_exist:nnTF { g } { #1 }
           {
             \exp_args:Nnx \prop_gput:cnn
-              { \@@_gname:n { #1 } }{ \str_convert_pdfname:n { #2 } } { #3 }
+              { \@@_name:nn { g }{ #1 } }{ \str_convert_pdfname:n { #2 } } { #3 }
           }
           {
             \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } { global }
@@ -516,41 +466,25 @@
 
 % \begin{macro}
 %   {
-%     \@@_get:nnN, \pdfdict_get:nnN,
-%     \@@_gget:nnN,\pdfdict_gget:nnN
+%     \@@_get:nnnN, \pdfdict_get:nnnN,
 %   }
 % Recover the values. The name must be first escaped to match the stored name.
 %    \begin{macrocode}
 %<*package>
-\cs_new_protected:Npn \@@_get:nnN  #1 #2 #3 %dict,key,macro
+\cs_new_protected:Npn \@@_get:nnnN  #1 #2 #3 #4 %type,dict,key,macro
   {
-    \@@_if_exist:nTF { #1 }
+    \@@_if_exist:nnTF { #1 } { #2 }
       {
         \exp_args:Nnx \prop_get:cnN
-          { \@@_name:n { #1 } }
-          { \str_convert_pdfname:n { #2 } } #3
+          { \@@_name:nn { #1 } { #2 }}
+          { \str_convert_pdfname:n { #3 } } #4
       }
       {
-        \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } { local }
+        \msg_error:nnnn { pdfdict } { unknown-dict } { #2 } { #1-type }
       }
   }
 
-\cs_set_eq:NN \pdfdict_get:nnN \@@_get:nnN
-
-\cs_new_protected:Npn \@@_gget:nnN  #1 #2 #3 %dict,key,macro
-  {
-    \@@_if_gexist:nTF { #1 }
-      {
-        \exp_args:Nnx \prop_get:cnN
-          { \@@_gname:n { #1 } }
-          { \str_convert_pdfname:n { #2 } } #3
-      }
-      {
-        \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } { global }
-      }
-  }
-
-\cs_set_eq:NN \pdfdict_gget:nnN \@@_gget:nnN
+\cs_set_eq:NN \pdfdict_get:nnnN \@@_get:nnnN
 
 %</package>
 %    \end{macrocode}
@@ -568,10 +502,10 @@
 
 \cs_new_protected:Npn \@@_remove:nn #1 #2 %dict,name
   {
-    \@@_if_exist:nTF { #1 }
+    \@@_if_exist:nnTF { l } { #1 }
       {
         \exp_args:Nnx \prop_remove:cn
-          { \@@_name:n { #1 } }{ \str_convert_pdfname:n { #2 } }
+          { \@@_name:nn { l } { #1 } }{ \str_convert_pdfname:n { #2 } }
       }
       {
         \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } {local}
@@ -581,10 +515,10 @@
 
 \cs_new_protected:Npn \@@_gremove:nn #1 #2 %dict,name
   {
-    \@@_if_gexist:nTF { #1 }
+    \@@_if_exist:nnTF { g } { #1 }
        {
          \exp_args:Nnx \prop_gremove:cn
-           { \@@_gname:n { #1 } }{ \str_convert_pdfname:n { #2 } }
+           { \@@_name:nn { g } { #1 } }{ \str_convert_pdfname:n { #2 } }
        }
        {
          \msg_error:nnnn { pdfdict } { unknown-dict } { #1 } {global}
@@ -603,27 +537,27 @@
 %<*package>
 \cs_new_protected:Npn \@@_show:Nn #1#2 %#1 message command, #2 dict
   {
-    \prop_if_exist:cT { \@@_name:n { #2 } }
+    \prop_if_exist:cT { \@@_name:nn { l } { #2 } }
        {
          #1
             { pdfdict }
             { show-dict }
             { \tl_to_str:n {#2} }
-            { \prop_map_function:cN {\@@_name:n { #2 }} \msg_show_item:nn }
+            { \prop_map_function:cN {\@@_name:nn { l } { #2 }} \msg_show_item:nn }
             { local }
             { }
        }
-    \prop_if_exist:cT { \@@_gname:n { #2 } }
+    \prop_if_exist:cT { \@@_name:nn { g } { #2 } }
        {
          #1
             { pdfdict }
             { show-dict }
             { \tl_to_str:n {#2} }
-            { \prop_map_function:cN {\@@_gname:n { #2 }} \msg_show_item:nn }
+            { \prop_map_function:cN {\@@_name:nn { g } { #2 }} \msg_show_item:nn }
             { global }
             { }
        }
-    \bool_if:nF {\prop_if_exist_p:c {\@@_gname:n { #2 }} || \prop_if_exist_p:c {\@@_name:n { #2 }} }
+    \bool_if:nF {\prop_if_exist_p:c {\@@_name:nn { g } { #2 }} || \prop_if_exist_p:c {\@@_name:nn { l } { #2 }} }
        {
          #1 { pdfdict } { unknown-dict } { #2 } { global~or~local }{}{}
        }
@@ -638,28 +572,22 @@
 %
 % \begin{macro}
 %   {
-%     \@@_use:n, \@@_guse:n
+%     \@@_use:nn
 %   }
-% \cs{@@_use:n} and \cs{@@_guse:n} output a prop as needed in a dictionary:
+% \cs{@@_use:nn} outputs a prop as needed in a dictionary:
 %  as a list of /\meta{key} \meta{value} pairs.
 % \begin{NOTE}{UF}
 %  !! is e-expansion the right thing?
 % \end{NOTE}
 %    \begin{macrocode}
 %<*package>
-\cs_new:Npn \@@_use:n #1 %dict
+\cs_new:Npn \@@_use:nn #1 #2  %#1 type, #2 dict
   {
-    \prop_map_function:cN { \@@_name:n { #1 } } \__pdf_dict_item:ne
+    \prop_map_function:cN { \@@_name:nn { #1 } { #2 } } \__pdf_dict_item:ne
   }
 
-\cs_set_eq:NN \pdfdict_use:n \@@_use:n
-
-\cs_new:Npn \@@_guse:n #1 %dict
-  {
-    \prop_map_function:cN { \@@_gname:n { #1 } } \__pdf_dict_item:ne
-  }
+\cs_set_eq:NN \pdfdict_use:nn \@@_use:nn
 
-\cs_set_eq:NN \pdfdict_guse:n \@@_guse:n
 %</package>
 %    \end{macrocode}
 % \end{macro}
@@ -668,7 +596,7 @@
 % \begin{variable}{page/Trans}
 %     \begin{macrocode}
 %<*package>
-\pdfdict_new:n {page/Trans}
+\pdfdict_new:nn  { l } {page/Trans}
 \pdfdict_put:nnn {page/Trans}{Type}{/Trans}
 % keys: /S (name), /D integer, /Dm (name), /M (name), /SS number /B boolean.
 % decribes transition *to* the page.
diff --git a/l3pdffile.dtx b/l3pdffile.dtx
index 7ed9cee..970db02 100644
--- a/l3pdffile.dtx
+++ b/l3pdffile.dtx
@@ -461,17 +461,17 @@
 %    \end{macrocode}
 % Here we define and setup the local dictionaries.
 %    \begin{macrocode}
-\pdfdict_new:n   { file }
+\pdfdict_new:nn { l }   { file }
 \pdfdict_put:nnn { file }{Type}{/EmbeddedFile}
-\pdfdict_new:n   { file/Params }
+\pdfdict_new:nn { l }   { file/Params }
 \pdfdict_put:nnn { file/Params }
   {ModDate}  { (\file_timestamp:n { \l_pdffile_source_name_str }) }
 \pdfdict_put:nnn { file/Params }
   {Size}     { \file_size:n { \l_pdffile_source_name_str } }
 \pdfdict_put:nnn { file/Params }
   {CheckSum} { (\file_mdfive_hash:n { \l_pdffile_source_name_str }) }
-\pdfdict_new:n   { file/streamParams }
-\pdfdict_new:n   { file/FileSpec }
+\pdfdict_new:nn { l }   { file/streamParams }
+\pdfdict_new:nn { l }   { file/FileSpec }
 \pdfdict_put:nnn { file/FileSpec }
   {Type} { /FileSpec }
 \pdfdict_put:nnn { file/FileSpec }
@@ -517,7 +517,7 @@
           \l_@@_tmpb_str %unused
           \l_@@_ext_str
         %check if Subtype has been set
-        \pdfdict_get:nnN {file}{Subtype}\l_@@_tmpa_tl
+        \pdfdict_get:nnnN { l } {file}{Subtype}\l_@@_tmpa_tl
         %if not look up in the prop:
         \quark_if_no_value:NT \l_@@_tmpa_tl
           {
@@ -546,12 +546,12 @@
       {
         {
           #2
-          \pdfdict_use:n {file}
-          \pdfdict_if_empty:nF {file/Params}
+          \pdfdict_use:nn { l } {file}
+          \pdfdict_if_empty:nnF { l } {file/Params}
             {
               /Params
                 <<
-                  \pdfdict_use:n {file/Params}
+                  \pdfdict_use:nn { l } {file/Params}
                 >>
             }
         }
@@ -571,12 +571,12 @@
       {
         {
           #2
-          \pdfdict_use:n {file}
-          \pdfdict_if_empty:nF {file/streamParams}
+          \pdfdict_use:nn { l } {file}
+          \pdfdict_if_empty:nnF { l } {file/streamParams}
             {
               /Params
                 <<
-                  \pdfdict_use:n {file/streamParams}
+                  \pdfdict_use:nn { l } {file/streamParams}
                 >>
             }
         }
@@ -604,7 +604,7 @@
           \pdfdict_put:nnx {file/FileSpec}{UF}{ \l_@@_tmpa_str }
           \pdf_object_write:nx { #1 }
             {
-              \pdfdict_use:n {file/FileSpec}
+              \pdfdict_use:nn { l } {file/FileSpec}
               \tl_if_empty:nF { #3 }
                 {
                   /EF <</F~#3 /UF~#3>>
diff --git a/pdfresources.dtx b/pdfresources.dtx
index c85edf5..9997f5f 100644
--- a/pdfresources.dtx
+++ b/pdfresources.dtx
@@ -392,7 +392,7 @@
         \hbox_set:Nn \l_@@_tmpa_box
           {
             \bool_set_true:N \l_@@_backend_xform_bool
-            \prop_gclear:c {\pdfdict_gname:n { Core/Xform/Resources/Properties }}
+            \prop_gclear:c {\pdfdict_name:nn { g } { Core/Xform/Resources/Properties }}
             #4
           }
         %store the dimensions
@@ -413,33 +413,33 @@
           {
             #3
             \int_compare:nNnT
-              { \prop_count:c { \pdfdict_gname:n { Core/Xform/Resources/Properties } } }
+              { \prop_count:c { \pdfdict_name:nn { g } { Core/Xform/Resources/Properties } } }
               >
               { 0 }
               {
                 /Properties~
                   <<
-                    \pdfdict_guse:n { Core/Xform/Resources/Properties }
+                    \pdfdict_use:nn { g } { Core/Xform/Resources/Properties }
                   >>
               }
 
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/ExtGState } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/ExtGState } }
               {
                 /ExtGState~ \pdf_object_ref:n { Page/Resources/ExtGState }
               }
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/Pattern } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/Pattern } }
               {
                 /Pattern~ \pdf_object_ref:n { Page/Resources/Pattern }
               }
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/Shading } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/Shading } }
               {
                 /Shading~ \pdf_object_ref:n { Page/Resources/Shading }
               }
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/ColorSpace } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/ColorSpace } }
               {
                 /ColorSpace~ \pdf_object_ref:n { Page/Resources/ColorSpace }
               }
@@ -476,7 +476,7 @@
         \hbox_set:Nn \l_@@_tmpa_box
           {
             \bool_set_true:N \l_@@_backend_xform_bool
-            \prop_gclear:c { \pdfdict_gname:n { Core/Xform/Resources/Properties } }
+            \prop_gclear:c { \pdfdict_name:nn { g } { Core/Xform/Resources/Properties } }
             #4
           }
         \tl_const:cx
@@ -496,32 +496,32 @@
           {
             #3
             \int_compare:nNnT
-              {\prop_count:c { \pdfdict_gname:n { Core/Xform/Resources/Properties } }}
+              {\prop_count:c { \pdfdict_name:nn { g } { Core/Xform/Resources/Properties } }}
               >
               { 0 }
               {
                 /Properties~
                   <<
-                    \pdfdict_guse:n { Core/Xform/Resources/Properties }
+                    \pdfdict_use:nn { g } { Core/Xform/Resources/Properties }
                   >>
               }
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/ExtGState } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/ExtGState } }
               {
                 /ExtGState~ \pdf_object_ref:n { Page/Resources/ExtGState }
               }
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/Pattern } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/Pattern } }
               {
                 /Pattern~ \pdf_object_ref:n { Page/Resources/Pattern }
               }
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/Shading } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/Shading } }
               {
                 /Shading~ \pdf_object_ref:n { Page/Resources/Shading }
               }
             \prop_if_empty:cF
-              { \pdfdict_gname:n { Core/Page/Resources/ColorSpace } }
+              { \pdfdict_name:nn { g } { Core/Page/Resources/ColorSpace } }
               {
                 /ColorSpace~ \pdf_object_ref:n { Page/Resources/ColorSpace }
               }
@@ -750,9 +750,9 @@
     \exp_args:Nx
     \@@_backend_annotation:nnnn {#2}{#3}{#4}
       {
-        \pdfdict_if_exist:nT { annot/#1 }
+        \pdfdict_if_exist:nnT { l } { annot/#1 }
           {
-            \pdfdict_use:n {annot/#1}
+            \pdfdict_use:nn { l } {annot/#1}
           }
         #5
       }
@@ -859,7 +859,7 @@
 % the subtype setting (the /Type is added by the backend).
 %    \begin{macrocode}
 %<*package>
-\pdfdict_new:n   {annot/Widget}
+\pdfdict_new:nn { l }   {annot/Widget}
 \pdfdict_put:nnn {annot/Widget}{Subtype}{/Widget}
 %</package>
 %    \end{macrocode}
@@ -912,7 +912,7 @@
 
 \seq_map_inline:Nn \c_pdfannot_link_types_seq
   {
-    \pdfdict_new:n   { annot/Link/#1 }
+    \pdfdict_new:nn { l }   { annot/Link/#1 }
     \pdfdict_put:nnn { annot/Link/#1}{ F }{ \pdf_flag_use:n { annot/Link} }
     \hook_new_pair:nn
       {pdf/annot/Link/#1/before}
@@ -964,9 +964,9 @@
     \exp_args:Nxx %xetex needs expansion
     \@@_backend_link_begin_user:nnw
       {
-         \pdfdict_if_exist:nT { annot/Link/#1 }
+         \pdfdict_if_exist:nnT { l } { annot/Link/#1 }
           {
-            \pdfdict_use:n {annot/Link/#1}
+            \pdfdict_use:nn { l } {annot/Link/#1}
           }
       }
       {
@@ -1020,9 +1020,9 @@
     \exp_args:Nxx %xetex needs expansion
       \@@_backend_link_begin_user:nnw
         {
-           \pdfdict_if_exist:nT { annot/Link/#1 }
+           \pdfdict_if_exist:nnT { l } { annot/Link/#1 }
             {
-              \pdfdict_use:n {annot/Link/#1}
+              \pdfdict_use:nn { l } {annot/Link/#1}
             }
         }
         { #2 }
@@ -1053,7 +1053,7 @@
     \exp_args:Nxx %xetex needs expansion
     \@@_backend_link_begin_goto:nnw
       {
-        \pdfdict_use:n {annot/Link/GoTo}
+        \pdfdict_use:nn { l } {annot/Link/GoTo}
 
       }
       { #1 }
diff --git a/testfiles/dict_if_empty.lvt b/testfiles/dict_if_empty.lvt
index 3fd934d..b2c53bb 100644
--- a/testfiles/dict_if_empty.lvt
+++ b/testfiles/dict_if_empty.lvt
@@ -7,15 +7,15 @@
 \showoutput
 
 \ExplSyntaxOn
-\pdfdict_if_empty:nTF{test}{empty}{not empty}\par
-\pdfdict_new:n {test}
-\pdfdict_if_empty:nTF{test}{empty}{not empty}\par
+\pdfdict_if_empty:nnTF { l }{test}{empty}{not empty}\par
+\pdfdict_new:nn {l} {test}
+\pdfdict_if_empty:nnTF { l }{test}{empty}{not empty}\par
 \pdfdict_put:nnn {test}{key}{value}
-\pdfdict_if_empty:nTF{test}{empty}{not empty}\par
+\pdfdict_if_empty:nnTF { l }{test}{empty}{not empty}\par
 
-\pdfdict_if_gempty:nTF{Core/Page}{empty}{not empty}\par
+\pdfdict_if_empty:nnTF { g }{Core/Page}{empty}{not empty}\par
 \pdfcoredict_gput:nnn {Page}{Rotate}{90}
-\pdfdict_if_gempty:nTF{Core/Page}{empty}{not empty}\par
+\pdfdict_if_empty:nnTF { g } {Core/Page}{empty}{not empty}\par
 \ExplSyntaxOff
 
 \end{document}
diff --git a/testfiles/show.lvt b/testfiles/show.lvt
index 7136b53..9cd8ca8 100644
--- a/testfiles/show.lvt
+++ b/testfiles/show.lvt
@@ -11,12 +11,12 @@ abbb
 \ExplSyntaxOn
 \pdfdict_show:n{Core/Catalog}
 \pdfdict_show:n{Core/Info}
-\pdfdict_new:n {Core/Catalog}
+\pdfdict_new:nn { l } {Core/Catalog}
 \pdfdict_put:nnn{Core/Catalog}{abc }{blub}
 \pdfdict_show:n{Core/Catalog}
 \pdfcoredict_show:n{Catalog}
 \pdfdict_show:n{blub}
-\pdfdict_if_exist:nTF {blub}{true}{false}
-\pdfdict_if_gexist:nTF {Core/Info}{true}{false}
+\pdfdict_if_exist:nnTF { l } {blub}{true}{false}
+\pdfdict_if_exist:nnTF { g }{Core/Info}{true}{false}
 \ExplSyntaxOff
 \end{document}





More information about the latex3-commits mailing list.