%%
%% This is file `l3backend-pdfmode.def',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% l3backend-basics.dtx  (with options: `package,pdfmode')
%% l3backend-color.dtx  (with options: `package,pdfmode')
%% l3backend-box.dtx  (with options: `package,pdfmode')
%% l3backend-draw.dtx  (with options: `package,pdfmode')
%% l3backend-graphics.dtx  (with options: `package,pdfmode')
%% l3backend-pdf.dtx  (with options: `package,pdfmode')
%% 
%% Copyright (C) 1990-2020 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:
%% 
%%    https://www.latex-project.org/lppl.txt
%% 
%% This file is part of the "l3backend bundle" (The Work in LPPL)
%% and all files in that bundle must be distributed together.
%% 
%% File: l3backend-basics.dtx
\ProvidesExplFile
  {l3backend-pdfmode.def}{2020-06-03}{}
  {L3 backend support: PDF mode}
\cs_new_eq:NN \__kernel_backend_literal:e \tex_special:D
\cs_new_protected:Npn \__kernel_backend_literal:n #1
  { \__kernel_backend_literal:e { \exp_not:n {#1} } }
\cs_generate_variant:Nn \__kernel_backend_literal:n { x }
\cs_new_protected:Npx \__kernel_backend_literal_pdf:n #1
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D literal }
      { \tex_pdfliteral:D }
        { \exp_not:N \exp_not:n {#1} }
  }
\cs_generate_variant:Nn \__kernel_backend_literal_pdf:n { x }
\cs_new_protected:Npx \__kernel_backend_literal_page:n #1
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D literal ~ }
      { \tex_pdfliteral:D }
        page
        { \exp_not:N \exp_not:n {#1} }
  }
\cs_new_protected:Npx \__kernel_backend_scope_begin:
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D save \scan_stop: }
      { \tex_pdfsave:D }
  }
\cs_new_protected:Npx \__kernel_backend_scope_end:
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D restore \scan_stop: }
      { \tex_pdfrestore:D }
  }
\cs_new_protected:Npx \__kernel_backend_matrix:n #1
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D setmatrix }
      { \tex_pdfsetmatrix:D }
        { \exp_not:N \exp_not:n {#1} }
  }
\cs_generate_variant:Nn \__kernel_backend_matrix:n { x }
%% File: l3backend-color.dtx
\cs_new_protected:Npn \__color_backend_pickup:N #1 { }
\AtBeginDocument
  {
    \cs_if_exist:cT { ver@color.sty }
      {
        \cs_set_protected:Npn \__color_backend_pickup:N #1
          {
            \exp_last_unbraced:Nx \__color_backend_pickup:w
              { \current@color } ~ 0 ~ 0 ~ 0 \s__color_stop #1
          }
        \cs_new_protected:Npn \__color_backend_pickup:w
          #1 ~ #2 ~ #3 ~ #4 ~ #5 ~ #6 \s__color_stop #7
          {
            \str_if_eq:nnTF {#2} { g }
              { \tl_set:Nn #7 { gray ~ #1 } }
              {
                \str_if_eq:nnTF {#4} { rg }
                  { \tl_set:Nn #7 { rgb ~ #1 ~ #2 ~ #3 } }
                  {
                     \str_if_eq:nnTF {#5} { k }
                       { \tl_set:Nn #7 { cmyk ~ #1 ~ #2 ~ #3 ~ #4 } }
                       {
                         \str_if_eq:nnTF {#2} { cs }
                           {
                             \tl_set:Nx #7 { spot ~ \use_none:n #1 ~ #5 }
                           }
                           {
                             \tl_set:Nn #7 { gray ~ 0 }
                           }
                       }
                  }
              }
          }
      }
  }
\int_new:N \l__kernel_color_stack_int
\cs_new_protected:Npn \__color_backend_cmyk:w #1 ~ #2 ~ #3 ~ #4 \s__color_stop
  {
     \use:x
       {
         \__color_backend_cmyk:nnnn
           { \fp_eval:n {#1} }
           { \fp_eval:n {#2} }
           { \fp_eval:n {#3} }
           { \fp_eval:n {#4} }
       }
  }
\cs_new_protected:Npn \__color_backend_cmyk:nnnn #1#2#3#4
  {
    \__color_backend_select:n
      { #1 ~ #2 ~ #3 ~ #4 ~ k ~ #1 ~ #2 ~ #3 ~ #4 ~ K }
  }
\cs_new_protected:Npn \__color_backend_gray:w #1 \s__color_stop
  { \exp_args:Nx \__color_backend_gray:n { \fp_eval:n {#1} } }
\cs_new_protected:Npn \__color_backend_gray:n #1
  { \__color_backend_select:n { #1 ~ g ~ #1 ~ G } }
\cs_new_protected:Npn \__color_backend_rgb:w #1~ #2 ~ #3 \s__color_stop
  {
     \use:x
       {
         \__color_backend_rgb:nnn
           { \fp_eval:n {#1} }
           { \fp_eval:n {#2} }
           { \fp_eval:n {#3} }
       }
  }
\cs_new_protected:Npn \__color_backend_rgb:nnn #1#2#3
  { \__color_backend_select:n { #1 ~ #2 ~ #3 ~ rg ~ #1 ~ #2 ~ #3 ~ RG } }
\cs_new_protected:Npn \__color_backend_spot:w #1 ~ #2 \s__color_stop
  { \__color_backend_select:n { /#1 ~ cs ~ /#1 ~ CS ~ #2 ~ sc ~ #2 ~ SC } }
\cs_new_protected:Npx \__color_backend_select:n #1
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D colorstack }
      { \tex_pdfcolorstack:D }
        \exp_not:N \l__kernel_color_stack_int push {#1}
      \group_insert_after:N \exp_not:N \__color_backend_reset:
  }
\cs_generate_variant:Nn \__color_backend_select:n { x }
\cs_new_protected:Npx \__color_backend_reset:
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D colorstack }
      { \tex_pdfcolorstack:D }
        \exp_not:N \l__kernel_color_stack_int pop \scan_stop:
  }
%% File: l3backend-box.dtx
\cs_new_protected:Npn \__box_backend_clip:N #1
  {
    \__kernel_backend_scope_begin:
    \__kernel_backend_literal_pdf:x
      {
        0~
        \dim_to_decimal_in_bp:n { -\box_dp:N #1 } ~
        \dim_to_decimal_in_bp:n { \box_wd:N #1 } ~
        \dim_to_decimal_in_bp:n { \box_ht:N #1 + \box_dp:N #1 } ~
        re~W~n
      }
    \hbox_overlap_right:n { \box_use:N #1 }
    \__kernel_backend_scope_end:
    \skip_horizontal:n { \box_wd:N #1 }
  }
\cs_new_protected:Npn \__box_backend_rotate:Nn #1#2
  { \exp_args:NNf \__box_backend_rotate_aux:Nn #1 { \fp_eval:n {#2} } }
\cs_new_protected:Npn \__box_backend_rotate_aux:Nn #1#2
  {
    \__kernel_backend_scope_begin:
    \box_set_wd:Nn #1 { 0pt }
    \fp_set:Nn \l__box_backend_cos_fp { round ( cosd ( #2 ) , 5 ) }
    \fp_compare:nNnT \l__box_backend_cos_fp = \c_zero_fp
      { \fp_zero:N \l__box_backend_cos_fp }
    \fp_set:Nn \l__box_backend_sin_fp { round ( sind ( #2 ) , 5 ) }
    \__kernel_backend_matrix:x
      {
        \fp_use:N \l__box_backend_cos_fp \c_space_tl
        \fp_compare:nNnTF \l__box_backend_sin_fp = \c_zero_fp
          { 0~0 }
          {
            \fp_use:N \l__box_backend_sin_fp
            \c_space_tl
            \fp_eval:n { -\l__box_backend_sin_fp }
          }
        \c_space_tl
        \fp_use:N \l__box_backend_cos_fp
      }
   \box_use:N #1
   \__kernel_backend_scope_end:
  }
\fp_new:N \l__box_backend_cos_fp
\fp_new:N \l__box_backend_sin_fp
\cs_new_protected:Npn \__box_backend_scale:Nnn #1#2#3
  {
    \__kernel_backend_scope_begin:
    \__kernel_backend_matrix:x
      {
        \fp_eval:n { round ( #2 , 5 ) } ~
        0~0~
        \fp_eval:n { round ( #3 , 5 ) }
      }
    \hbox_overlap_right:n { \box_use:N #1 }
    \__kernel_backend_scope_end:
  }
%% File: l3backend-draw.dtx
\cs_new_eq:NN \__draw_backend_literal:n \__kernel_backend_literal_pdf:n
\cs_generate_variant:Nn \__draw_backend_literal:n { x }
\cs_new_protected:Npn \__draw_backend_begin:
  { \__draw_backend_scope_begin: }
\cs_new_protected:Npn \__draw_backend_end:
  { \__draw_backend_scope_end: }
\cs_new_eq:NN \__draw_backend_scope_begin: \__kernel_backend_scope_begin:
\cs_new_eq:NN \__draw_backend_scope_end: \__kernel_backend_scope_end:
\cs_new_protected:Npn \__draw_backend_moveto:nn #1#2
  {
    \__draw_backend_literal:x
      { \dim_to_decimal_in_bp:n {#1} ~ \dim_to_decimal_in_bp:n {#2} ~ m }
  }
\cs_new_protected:Npn \__draw_backend_lineto:nn #1#2
  {
    \__draw_backend_literal:x
      { \dim_to_decimal_in_bp:n {#1} ~ \dim_to_decimal_in_bp:n {#2} ~ l }
  }
\cs_new_protected:Npn \__draw_backend_curveto:nnnnnn #1#2#3#4#5#6
  {
    \__draw_backend_literal:x
      {
        \dim_to_decimal_in_bp:n {#1} ~ \dim_to_decimal_in_bp:n {#2} ~
        \dim_to_decimal_in_bp:n {#3} ~ \dim_to_decimal_in_bp:n {#4} ~
        \dim_to_decimal_in_bp:n {#5} ~ \dim_to_decimal_in_bp:n {#6} ~
        c
      }
 }
\cs_new_protected:Npn \__draw_backend_rectangle:nnnn #1#2#3#4
  {
     \__draw_backend_literal:x
      {
        \dim_to_decimal_in_bp:n {#1} ~ \dim_to_decimal_in_bp:n {#2} ~
        \dim_to_decimal_in_bp:n {#3} ~ \dim_to_decimal_in_bp:n {#4} ~
        re
      }
  }
\cs_new_protected:Npn \__draw_backend_evenodd_rule:
  { \bool_gset_true:N \g__draw_draw_eor_bool }
\cs_new_protected:Npn \__draw_backend_nonzero_rule:
  { \bool_gset_false:N \g__draw_draw_eor_bool }
\bool_new:N \g__draw_draw_eor_bool
\cs_new_protected:Npn \__draw_backend_closepath:
  { \__draw_backend_literal:n { h } }
\cs_new_protected:Npn \__draw_backend_stroke:
  { \__draw_backend_literal:n { S } }
\cs_new_protected:Npn \__draw_backend_closestroke:
  { \__draw_backend_literal:n { s } }
\cs_new_protected:Npn \__draw_backend_fill:
  {
    \__draw_backend_literal:x
      { f \bool_if:NT \g__draw_draw_eor_bool * }
  }
\cs_new_protected:Npn \__draw_backend_fillstroke:
  {
    \__draw_backend_literal:x
      { B \bool_if:NT \g__draw_draw_eor_bool * }
  }
\cs_new_protected:Npn \__draw_backend_clip:
  {
    \__draw_backend_literal:x
      { W \bool_if:NT \g__draw_draw_eor_bool * }
  }
\cs_new_protected:Npn \__draw_backend_discardpath:
  { \__draw_backend_literal:n { n } }
\cs_new_protected:Npn \__draw_backend_dash_pattern:nn #1#2
  {
    \__draw_backend_literal:x
      {
        [
          \exp_args:Nf \use:n
            { \clist_map_function:nN {#1} \__draw_backend_dash:n }
        ] ~
        \dim_to_decimal_in_bp:n {#2} ~ d
      }
  }
\cs_new:Npn \__draw_backend_dash:n #1
  { ~ \dim_to_decimal_in_bp:n {#1} }
\cs_new_protected:Npn \__draw_backend_linewidth:n #1
  {
    \__draw_backend_literal:x
      { \dim_to_decimal_in_bp:n {#1} ~ w }
  }
\cs_new_protected:Npn \__draw_backend_miterlimit:n #1
  { \__draw_backend_literal:x { \fp_eval:n {#1} ~ M } }
\cs_new_protected:Npn \__draw_backend_cap_butt:
  { \__draw_backend_literal:n { 0 ~ J } }
\cs_new_protected:Npn \__draw_backend_cap_round:
  { \__draw_backend_literal:n { 1 ~ J } }
\cs_new_protected:Npn \__draw_backend_cap_rectangle:
  { \__draw_backend_literal:n { 2 ~ J } }
\cs_new_protected:Npn \__draw_backend_join_miter:
  { \__draw_backend_literal:n { 0 ~ j } }
\cs_new_protected:Npn \__draw_backend_join_round:
  { \__draw_backend_literal:n { 1 ~ j } }
\cs_new_protected:Npn \__draw_backend_join_bevel:
  { \__draw_backend_literal:n { 2 ~ j } }
\cs_new_protected:Npn \__draw_backend_color_fill_cmyk:nnnn #1#2#3#4
  {
    \__draw_backend_color_select:x
      {
        \fp_eval:n {#1} ~ \fp_eval:n {#2} ~
        \fp_eval:n {#3} ~ \fp_eval:n {#4} ~
        k
      }
  }
\cs_new_protected:Npn \__draw_backend_color_stroke_cmyk:nnnn #1#2#3#4
  {
    \__draw_backend_color_select:x
      {
        \fp_eval:n {#1} ~ \fp_eval:n {#2} ~
        \fp_eval:n {#3} ~ \fp_eval:n {#4} ~
        k
      }
  }
\cs_new_protected:Npn \__draw_backend_color_fill_gray:n #1
  { \__draw_backend_color_select:x { \fp_eval:n {#1} ~ g } }
\cs_new_protected:Npn \__draw_backend_color_stroke_gray:n #1
  { \__draw_backend_color_select:x { \fp_eval:n {#1} ~ G } }
\cs_new_protected:Npn \__draw_backend_color_fill_rgb:nnn #1#2#3
  {
    \__draw_backend_color_select:x
      { \fp_eval:n {#1} ~ \fp_eval:n {#2} ~ \fp_eval:n {#3} ~ rg }
  }
\cs_new_protected:Npn \__draw_backend_color_stroke_rgb:nnn #1#2#3
  {
    \__draw_backend_color_select:x
      { \fp_eval:n {#1} ~ \fp_eval:n {#2} ~ \fp_eval:n {#3} ~ RG }
  }
\cs_new_protected:Npx \__draw_backend_color_select:n #1
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D colorstack }
      { \tex_pdfcolorstack:D }
        \exp_not:N \l__kernel_color_stack_int push {#1}
      \group_insert_after:N \exp_not:N \__draw_backend_color_reset:
  }
\cs_new_protected:Npx \__draw_backend_color_reset:
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D colorstack }
      { \tex_pdfcolorstack:D }
        \exp_not:N \l__kernel_color_stack_int pop \scan_stop:
  }
\cs_generate_variant:Nn \__draw_backend_color_select:n { x }
\cs_new_protected:Npn \__draw_backend_cm:nnnn #1#2#3#4
  {
    \__kernel_backend_matrix:x
      {
        \fp_eval:n {#1} ~ \fp_eval:n {#2} ~
        \fp_eval:n {#3} ~ \fp_eval:n {#4}
      }
  }
\cs_new_protected:Npn \__draw_backend_box_use:Nnnnn #1#2#3#4#5
  {
    \__kernel_backend_scope_begin:
    \__draw_backend_cm:nnnn {#2} {#3} {#4} {#5}
    \hbox_overlap_right:n { \box_use:N #1 }
    \__kernel_backend_scope_end:
  }
%% File: l3backend-graphics.dtx
\tl_new:N \l__graphics_graphics_attr_tl
\cs_new_protected:Npn \__graphics_backend_getbb_jpg:n #1
  {
    \int_zero:N \l_graphics_page_int
    \tl_clear:N \l_graphics_pagebox_tl
    \tl_set:Nx \l__graphics_graphics_attr_tl
      {
        \tl_if_empty:NF \l_graphics_decodearray_tl
          { :D \l_graphics_decodearray_tl }
        \bool_if:NT \l_graphics_interpolate_bool
          { :I }
      }
    \tl_clear:N \l__graphics_graphics_attr_tl
    \__graphics_backend_getbb_auxi:n {#1}
  }
\cs_new_eq:NN \__graphics_backend_getbb_png:n \__graphics_backend_getbb_jpg:n
\cs_new_protected:Npn \__graphics_backend_getbb_pdf:n #1
  {
    \tl_clear:N \l_graphics_decodearray_tl
    \bool_set_false:N \l_graphics_interpolate_bool
    \tl_set:Nx \l__graphics_graphics_attr_tl
      {
        : \l_graphics_pagebox_tl
        \int_compare:nNnT \l_graphics_page_int > 1
          { :P \int_use:N \l_graphics_page_int }
      }
    \__graphics_backend_getbb_auxi:n {#1}
  }
\cs_new_protected:Npn \__graphics_backend_getbb_auxi:n #1
  {
    \graphics_bb_restore:xF { #1 \l__graphics_graphics_attr_tl }
      { \__graphics_backend_getbb_auxii:n {#1} }
  }
\cs_new_protected:Npn \__graphics_backend_getbb_auxii:n #1
  {
    \tex_immediate:D \tex_pdfximage:D
      \bool_lazy_or:nnT
        { \l_graphics_interpolate_bool }
        { ! \tl_if_empty_p:N \l_graphics_decodearray_tl }
        {
          attr ~
            {
              \tl_if_empty:NF \l_graphics_decodearray_tl
                { /Decode~[ \l_graphics_decodearray_tl ] }
              \bool_if:NT \l_graphics_interpolate_bool
                { /Interpolate~true }
            }
        }
      \int_compare:nNnT \l_graphics_page_int > 0
        { page ~ \int_use:N \l_graphics_page_int }
      \tl_if_empty:NF \l_graphics_pagebox_tl
        { \l_graphics_pagebox_tl }
      {#1}
    \hbox_set:Nn \l__graphics_internal_box
      { \tex_pdfrefximage:D \tex_pdflastximage:D }
    \dim_set:Nn \l_graphics_urx_dim { \box_wd:N \l__graphics_internal_box }
    \dim_set:Nn \l_graphics_ury_dim { \box_ht:N \l__graphics_internal_box }
    \int_const:cn { c__graphics_graphics_ #1 \l__graphics_graphics_attr_tl _int }
      { \tex_the:D \tex_pdflastximage:D }
    \graphics_bb_save:x { #1 \l__graphics_graphics_attr_tl }
  }
\cs_new_protected:Npn \__graphics_backend_include_jpg:n #1
  {
    \tex_pdfrefximage:D
      \int_use:c { c__graphics_graphics_ #1 \l__graphics_graphics_attr_tl _int }
  }
\cs_new_eq:NN \__graphics_backend_include_pdf:n \__graphics_backend_include_jpg:n
\cs_new_eq:NN \__graphics_backend_include_png:n \__graphics_backend_include_jpg:n
\sys_if_shell:T
  {
    \str_new:N \l__graphics_backend_dir_str
    \str_new:N \l__graphics_backend_name_str
    \str_new:N \l__graphics_backend_ext_str
    \cs_new_protected:Npn \__graphics_backend_getbb_eps:n #1
      {
        \file_parse_full_name:nNNN {#1}
          \l__graphics_backend_dir_str
          \l__graphics_backend_name_str
          \l__graphics_backend_ext_str
        \exp_args:Nx \__graphics_backend_getbb_eps:nn
          {
            \l__graphics_backend_name_str - \str_tail:N \l__graphics_backend_ext_str
            -converted-to.pdf
          }
          {#1}
     }
    \cs_new_protected:Npn \__graphics_backend_getbb_eps:nn #1#2
      {
        \file_compare_timestamp:nNnT {#2} > {#1}
          {
            \sys_shell_now:n
              { repstopdf ~ #2 ~ #1 }
          }
        \tl_set:Nn \l_graphics_name_tl {#1}
        \__graphics_backend_getbb_pdf:n {#1}
      }
    \cs_new_protected:Npn \__graphics_backend_include_eps:n #1
      {
        \file_parse_full_name:nNNN {#1}
          \l__graphics_backend_dir_str \l__graphics_backend_name_str \l__graphics_backend_ext_str
        \exp_args:Nx \__graphics_backend_include_pdf:n
          {
            \l__graphics_backend_name_str - \str_tail:N \l__graphics_backend_ext_str
            -converted-to.pdf
          }
      }
  }
%% File: l3backend-pdf.dtx
\box_new:N \l__pdf_internal_box
\cs_new_protected:Npx \__pdf_backend_annotation:nnnn #1#2#3#4
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D annot ~ }
      { \tex_pdfannot:D }
      width  ~ \exp_not:N \dim_eval:n {#1} ~
      height ~ \exp_not:N \dim_eval:n {#2} ~
      depth  ~ \exp_not:N \dim_eval:n {#3} ~
      {#4}
  }
\cs_new:Npx \__pdf_backend_annotation_last:
  {
    \exp_not:N \int_value:w
    \cs_if_exist:NTF \tex_pdffeedback:D
      { \exp_not:N \tex_pdffeedback:D lastannot ~ }
      { \exp_not:N \tex_pdflastannot:D }
      \c_space_tl 0 ~ R
  }
\cs_new_protected:Npn \__pdf_backend_link_begin_goto:nnw #1#2
  { \__pdf_backend_link_begin:nnnw {#1} { goto~name } {#2} }
\cs_new_protected:Npn \__pdf_backend_link_begin_user:nnw #1#2
  { \__pdf_backend_link_begin:nnnw {#1} { user } {#2} }
\cs_new_protected:Npx \__pdf_backend_link_begin:nnnw #1#2#3
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D startlink ~ }
      { \tex_pdfstartlink:D }
        attr {#1}
        #2 {#3}
  }
\cs_new_protected:Npx \__pdf_backend_link_end:
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D endlink \scan_stop: }
      { \tex_pdfendlink:D }
  }
\cs_new:Npx \__pdf_backend_link_last:
  {
    \exp_not:N \int_value:w
    \cs_if_exist:NTF \tex_pdffeedback:D
      { \exp_not:N \tex_pdffeedback:D lastlink ~ }
      { \exp_not:N \tex_pdflastlink:D }
      \c_space_tl 0 ~ R
  }
\cs_new_protected:Npx \__pdf_backend_link_margin:n #1
  {
    \cs_if_exist:NTF \tex_pdfvariable:D
      { \exp_not:N \tex_pdfvariable:D linkmargin }
      { \exp_not:N \tex_pdflinkmargin:D }
        \exp_not:N \dim_eval:n {#1} \scan_stop:
  }
\cs_new_protected:Npx \__pdf_backend_destination:nn #1#2
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \exp_not:N \tex_pdfextension:D dest ~ }
      { \exp_not:N \tex_pdfdest:D }
        name {#1}
        \exp_not:N \str_case:nnF {#2}
          {
            { xyz }   { xyz }
            { fit }   { fit }
            { fitb }  { fitb }
            { fitbh } { fitbh }
            { fitbv } { fitbv }
            { fith }  { fith }
            { fitv }  { fitv }
          }
          { xyz ~ zoom \exp_not:N \fp_eval:n { #2 * 10 } }
        \scan_stop:
  }
\cs_new_protected:Npx \__pdf_backend_destination_box:nn #1#2
  {
    \group_begin:
      \hbox_set:Nn \l__pdf_internal_box {#2}
     \cs_if_exist:NTF \tex_pdfextension:D
      { \exp_not:N \tex_pdfextension:D dest ~ }
      { \exp_not:N \tex_pdfdest:D }
      name {#1}
      fitr ~
        width  \exp_not:N \box_wd:N \l__pdf_internal_box
        height \exp_not:N \box_ht:N \l__pdf_internal_box
        depth  \exp_not:N \box_dp:N \l__pdf_internal_box
      \box_use:N \l__pdf_internal_box
    \group_end:
  }
\cs_new_protected:Npx \__pdf_backend_catalog_gput:nn #1#2
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D catalog }
      { \tex_pdfcatalog:D }
        { / #1 ~ #2 }
  }
\cs_new_protected:Npx \__pdf_backend_info_gput:nn #1#2
  {
    \cs_if_exist:NTF \tex_pdfextension:D
      { \tex_pdfextension:D info }
      { \tex_pdfinfo:D }
        { / #1 ~ #2 }
  }
\prop_new:N \g__pdf_backend_object_prop
\group_begin:
  \cs_set_protected:Npn \__pdf_tmp:w #1#2
    {
      \cs_new_protected:Npx \__pdf_backend_object_new:nn ##1##2
        {
          #1 reserveobjnum ~
          \int_const:cn
            { c__pdf_backend_object_ \exp_not:N \tl_to_str:n {##1} _int }
            {#2}
          \prop_gput:Nnn \exp_not:N \g__pdf_backend_object_prop {##1} {##2}
        }
    }
  \cs_if_exist:NTF \tex_pdfextension:D
    {
      \__pdf_tmp:w
        { \tex_pdfextension:D obj ~ }
        { \exp_not:N \tex_pdffeedback:D lastobj }
    }
    { \__pdf_tmp:w { \tex_pdfobj:D } { \tex_pdflastobj:D } }
\group_end:
\cs_new:Npn \__pdf_backend_object_ref:n #1
  { \int_use:c { c__pdf_backend_object_ \tl_to_str:n {#1} _int } ~ 0 ~ R }
\group_begin:
  \cs_set_protected:Npn \__pdf_tmp:w #1
    {
      \cs_new_protected:Npn \__pdf_backend_object_write:nn ##1##2
        {
          \tex_immediate:D #1 useobjnum ~
          \int_use:c
            { c__pdf_backend_object_ \tl_to_str:n {##1} _int }
            \str_case_e:nn
              { \prop_item:Nn \g__pdf_backend_object_prop {##1} }
              {
                { array } { { [ ~ \exp_not:n {##2} ~ ] } }
                { dict }  { { << ~ \exp_not:n {##2} ~ >> } }
                { fstream }
                  {
                    stream ~ attr ~ { \__pdf_exp_not_i:nn ##2 } ~
                      file ~ { \__pdf_exp_not_ii:nn ##2 }
                  }
                { stream }
                  {
                    stream ~ attr ~ { \__pdf_exp_not_i:nn ##2 } ~
                      { \__pdf_exp_not_ii:nn ##2 }
                  }
              }
        }
    }
  \cs_if_exist:NTF \tex_pdfextension:D
    { \__pdf_tmp:w { \tex_pdfextension:D obj ~ } }
    { \__pdf_tmp:w { \tex_pdfobj:D } }
\group_end:
\cs_generate_variant:Nn \__pdf_backend_object_write:nn { nx }
\cs_new:Npn \__pdf_exp_not_i:nn #1#2 { \exp_not:n {#1} }
\cs_new:Npn \__pdf_exp_not_ii:nn #1#2 { \exp_not:n {#2} }
\group_begin:
  \cs_set_protected:Npn \__pdf_tmp:w #1
    {
      \cs_new_protected:Npn \__pdf_backend_object_now:nn ##1##2
        {
          \tex_immediate:D #1
            \str_case:nn
              {##1}
              {
                { array } { { [ ~ \exp_not:n {##2} ~ ] } }
                { dict }  { { << ~ \exp_not:n {##2} ~ >> } }
                { fstream }
                  {
                    stream ~ attr ~ { \__pdf_exp_not_i:nn ##2 } ~
                      file ~ { \__pdf_exp_not_ii:nn ##2 }
                  }
                { stream }
                  {
                    stream ~ attr ~ { \__pdf_exp_not_i:nn ##2 } ~
                      { \__pdf_exp_not_ii:nn ##2 }
                  }
              }
        }
    }
  \cs_if_exist:NTF \tex_pdfextension:D
    { \__pdf_tmp:w { \tex_pdfextension:D obj ~ } }
    { \__pdf_tmp:w { \tex_pdfobj:D } }
\group_end:
\cs_generate_variant:Nn \__pdf_backend_object_now:nn { nx }
\cs_new:Npx \__pdf_backend_object_last:
  {
    \exp_not:N \int_value:w
    \cs_if_exist:NTF \tex_pdffeedback:D
      { \exp_not:N \tex_pdffeedback:D lastobj ~ }
      { \exp_not:N \tex_pdflastobj:D }
      \c_space_tl 0 ~ R
  }
\cs_new:Npx \__pdf_backend_pageobject_ref:n #1
  {
    \exp_not:N \int_value:w
      \cs_if_exist:NTF \tex_pdffeedback:D
        { \exp_not:N \tex_pdffeedback:D pageref }
        { \exp_not:N \tex_pdfpageref:D }
          \c_space_tl #1 \c_space_tl \c_space_tl \c_space_tl 0 ~ R
  }
\cs_new_protected:Npx \__pdf_backend_compresslevel:n #1
  {
    \exp_not:N \tex_global:D
    \cs_if_exist:NTF \tex_pdfcompresslevel:D
      { \tex_pdfcompresslevel:D }
      { \tex_pdfvariable:D compresslevel }
      \exp_not:N \int_value:w \exp_not:N \int_eval:n {#1} \scan_stop:
  }
\cs_new_protected:Npn \__pdf_backend_compress_objects:n #1
  {
    \bool_if:nTF {#1}
      { \__pdf_backend_objcompresslevel:n { 2 } }
      { \__pdf_backend_objcompresslevel:n { 0 } }
  }
\cs_new_protected:Npx \__pdf_backend_objcompresslevel:n #1
  {
    \exp_not:N \tex_global:D
    \cs_if_exist:NTF \tex_pdfobjcompresslevel:D
      { \tex_pdfobjcompresslevel:D }
      { \tex_pdfvariable:D objcompresslevel }
      #1 \scan_stop:
  }
\cs_new_protected:Npx \__pdf_backend_version_major_gset:n #1
  {
    \cs_if_exist:NTF \tex_pdfvariable:D
      {
        \int_compare:nNnT \tex_luatexversion:D > { 106 }
          {
            \exp_not:N \tex_global:D \tex_pdfvariable:D majorversion
              \exp_not:N \int_eval:n {#1} \scan_stop:
          }
      }
      {
        \cs_if_exist:NT \tex_pdfmajorversion:D
          {
            \exp_not:N \tex_global:D \tex_pdfmajorversion:D
              \exp_not:N \int_eval:n {#1} \scan_stop:
          }
      }
  }
\cs_new_protected:Npx \__pdf_backend_version_minor_gset:n #1
  {
    \exp_not:N \tex_global:D
    \cs_if_exist:NTF \tex_pdfminorversion:D
      { \exp_not:N \tex_pdfminorversion:D }
      { \tex_pdfvariable:D minorversion }
        \exp_not:N \int_eval:n {#1} \scan_stop:
  }
\cs_new:Npx \__pdf_backend_version_major:
  {
    \cs_if_exist:NTF \tex_pdfvariable:D
      {
        \int_compare:nNnTF \tex_luatexversion:D > { 106 }
          { \exp_not:N \tex_the:D \tex_pdfvariable:D majorversion }
          { 1 }
      }
      {
        \cs_if_exist:NTF \tex_pdfmajorversion:D
          { \exp_not:N \tex_the:D \tex_pdfmajorversion:D }
          { 1 }
      }
  }
\cs_new:Npx \__pdf_backend_version_minor:
  {
    \exp_not:N \tex_the:D
    \cs_if_exist:NTF \tex_pdfminorversion:D
      { \exp_not:N \tex_pdfminorversion:D }
      { \tex_pdfvariable:D minorversion }
  }
\cs_new_protected:Npn \__pdf_backend_bdc:nn #1#2
  { \__kernel_backend_literal_page:n { /#1 ~ #2 ~ BDC } }
\cs_new_protected:Npn \__pdf_backend_emc:
  { \__kernel_backend_literal_page:n { EMC } }
%% 
%%
%% End of file `l3backend-pdfmode.def'.
