%%
%% This is file `interfaces-hypbmsec.code.tex',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% interfaces.dtx  (with options: `hypbmsec.code.tex')
%% 
%% This is a generated file.
%% 
%% interfaces : 2010/10/20 v1.1 - interfaces : interfaces with keys for other packages (FC)
%% 
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.3 of this license or (at your option) any later
%% version. The latest version of this license is in
%%    http://www.latex-project.org/lppl.txt
%% 
%% This work consists of the main source file interfaces.dtx
%% and the derived files
%%     interfaces.sty, interfaces.pdf, interfaces.ins,
%%     interfaces-base.sty,
%%     interfaces-LaTeX.sty,
%%     interfaces-tikz.sty,
%%     interfaces-titlesec.sty,
%%     interfaces-hyperref.sty,
%%     interfaces-bookmark.sty,
%%     interfaces-hypbmsec.sty,interfaces-hypbmsec.code.tex,
%%     interfaces-fancyhdr.sty,
%%     interfaces-marks.sty,
%%     interfaces-tocloft.sty,
%%     interfaces-makecell.sty,
%%     interfaces-enumitem.sty,
%%     interfaces-truncate.sty,
%%     interfaces-appendix.sty,
%%     interfaces-embedfile.sty,
%%     interfaces-environ.sty,
%%     interfaces-umrand.sty,
%%     interfaces-scrlfile.sty,
%%     interfaces-pgfkeys.sty,
%%     interfaces-etoolbox.sty,
%%     interfaces-fancyvrb.sty
%% 
%% interfaces: interfaces with keys for other packages (FC)
%% Copyright (C) 2010 by Florent Chervet <florent.chervet@free.fr>
%% 
\ProvidesFile{interfaces-hypbmsec.code.tex}
   [2010/10/27 v1.2 code for interfaces-hypbmsec (FC)]
\itf@patch\pretocmd\hbs@do{%
   \edef\itf@tp{\expandafter\itf@strip@at\string#1}%
   }%
   {\PackageInfo{interfaces-hypbmsec}
      {Command \string\hbs@do\space successfully patched}}
   {\PackageWarning{interfaces-hypbmsec}
      {Command \string\hbs@do\space could not be patched
      \MessageBreak loading of `interfaces-hypbmsec` aborted
      \MessageBreak \string\lastsection\space will not work}%
    \endinput}
\itf@patch\pretocmd\hbs@process{%
   \itf@hbs@next{#1}%
   }%
   {\PackageInfo{interfaces-hypbmsec}
      {Command \string\hbs@process\space successfully patched}}
   {\PackageWarning{interfaces-hypbmsec}
      {Command \string\hbs@process\space could not be patched
      \MessageBreak loading of `interfaces-hypbmsec` aborted
      \MessageBreak \string\lastsection\space will not work}%
      \endinput}%
\long\def\itf@hbs@next#1{%
   \csdef{itf@next\itf@tp title}{#1}%
   \expandafter\let\csname itf@next\itf@tp toc\expandafter\endcsname
      \csname
         \ifx\hbs@tocstring\relax itf@next\itf@tp title\else
                                  hbs@tocstring\fi
      \endcsname
   \expandafter\let\csname itf@next\itf@tp bookmark\expandafter\endcsname
      \csname
         \ifx\hbs@bmstring\relax itf@next\itf@tp toc\else
                                 hbs@bmstring\fi
      \endcsname
   \expandafter\expandafter\expandafter
   \expandafter\expandafter\expandafter
   \expandafter\itf@hbs@chkclass
         \expandafter\expandafter\expandafter\string
            \expandafter\hbs@seccmd\string\ttl@\@nil
      {\expandafter\itf@last@from@next\expandafter{\itf@tp}}%
}% \itf@hbs@next
\long\expandafter\def\expandafter\itf@hbs@chkclass
            \expandafter#\expandafter1\string\ttl@#2\@nil{%
   \ifblank{#1}{\if@nobreak\itf@hbs@nobreakfix#2\@nnil\fi}%
}% \itf@hbs@chkclass
\def\itf@hbs@nobreakfix#1#{\itf@hbs@n@breakfix}
\def\itf@hbs@n@breakfix#1#2\@nnil{%
   \unless\ifx\lastsectionname\relax
   \unless\ifnum\csname ttll@#1\endcsname > \csname ttll@\lastsectionname\endcsname\relax
      \@nobreakfalse
   \fi\fi
}% \itf@hbs@nobreakfix
\def\itf@last@from@next#1{%
   \gdef\lastsectionname{#1}%
   \global\expandafter\let\csname last#1title\expandafter\endcsname
                        \csname itf@next#1title\endcsname
   \global\expandafter\let\csname last#1toc\expandafter\endcsname
                        \csname itf@next#1toc\endcsname
   \global\expandafter\let\csname last#1bookmark\expandafter\endcsname
                        \csname itf@next#1bookmark\endcsname
   \let\@elt\itf@resetlastsections
   \csname cl@#1\endcsname
}% \itf@last@from@next
\def\itf@resetlastsections#1{%
   \expandafter\let\csname last#1title\endcsname\relax
   \expandafter\let\csname last#1toc\endcsname\relax
   \expandafter\let\csname last#1bookmark\endcsname\relax
   \csname cl@#1\endcsname
}% \itf@resetlastsections
\let\lastsectionname\relax
\@for\itf@tp:=part,section,subsection,subsubsection,paragraph,subparagraph%
   \do{\expandafter\let\csname last\itf@tp title\endcsname\relax
      \expandafter\let\csname last\itf@tp toc\endcsname\relax
      \expandafter\let\csname last\itf@tp bookmark\endcsname\relax
   }%
\AtBeginDocument{\ifundef\chapter{}
   {\let\lastchaptertitle\relax
    \let\lastchaptertoc\relax
    \let\lastchapterbookmark\relax}%
}%
\endinput
%%
%% End of file `interfaces-hypbmsec.code.tex'.
