From d8784a24ee61bfc794665e3c8300d435d8d9a4bd Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Fri, 25 Feb 2011 23:45:04 +0000 Subject: linegoal 2.9 (25feb11) git-svn-id: svn://tug.org/texlive/trunk@21523 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/latex/linegoal/linegoal.pdf | Bin 162718 -> 192294 bytes .../texmf-dist/source/latex/linegoal/linegoal.drv | 77 +++- .../texmf-dist/source/latex/linegoal/linegoal.dtx | 430 +++++++++++++-------- .../texmf-dist/source/latex/linegoal/linegoal.ins | 7 +- Master/texmf-dist/tex/latex/linegoal/linegoal.sty | 13 +- 5 files changed, 354 insertions(+), 173 deletions(-) diff --git a/Master/texmf-dist/doc/latex/linegoal/linegoal.pdf b/Master/texmf-dist/doc/latex/linegoal/linegoal.pdf index 6bdd4234ee2..aa371ad6065 100644 Binary files a/Master/texmf-dist/doc/latex/linegoal/linegoal.pdf and b/Master/texmf-dist/doc/latex/linegoal/linegoal.pdf differ diff --git a/Master/texmf-dist/source/latex/linegoal/linegoal.drv b/Master/texmf-dist/source/latex/linegoal/linegoal.drv index 1488356a350..aebef77afe5 100644 --- a/Master/texmf-dist/source/latex/linegoal/linegoal.drv +++ b/Master/texmf-dist/source/latex/linegoal/linegoal.drv @@ -8,7 +8,7 @@ %% %% This is a generated file. %% -%% linegoal : 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line +%% linegoal : 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line %% %% This work may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either @@ -23,29 +23,82 @@ %% linegoal : linegoal : a new dimen corresponding to the remainder of the line %% Copyright (C) 2010 by Florent Chervet %% +\let\microtypeYN=y \edef\thisfile{\jobname} -\def\thisinfo{A new ``dimen'' corresponding to the remainder of the line} -\def\thisdate{2010/12/07} -\def\thisversion{2.7} +\def\thisinfo{Measuring the remaining width of the line} +\def\thisdate{2011/02/25} +\def\thisversion{2.9} \def\CTANbaseurl{http://www.ctan.org/tex-archive/} \def\CTANhref#1#2{\href{\CTANbaseurl/help/Catalogue/entries/#1.html}{\nolinkurl{CTAN:help/Catalogue/entries/#1.html}}} \let\loadclass\LoadClass \def\LoadClass#1{\loadclass[abstracton]{scrartcl}\let\scrmaketitle\maketitle\AtEndOfClass{\let\maketitle\scrmaketitle}} \PassOptionsToPackage{svgnames}{xcolor} +{\makeatletter{\endlinechar`\^^J\obeyspaces + \gdef\ErrorUpdate#1=#2,{\@ifpackagelater{#1}{#2}{}{\let\CheckDate\errmessage\toks@\expandafter{\the\toks@ + \thisfile-documentation: updates required ! + package #1 must be later than #2 + to compile this documentation.}}}}% + \gdef\CheckDate#1{{\let\CheckDate\relax\toks@{}\@for\x:=\thisfile=\thisdate,#1\do{\expandafter\ErrorUpdate\x,}\CheckDate\expandafter{\the\toks@}}}} +\AtBeginDocument{\CheckDate{interfaces=2011/02/12,tabu=2011/02/25}} \documentclass[a4paper,oneside,american,latin1,T1]{ltxdoc} \AtBeginDocument{\DeleteShortVerb{\|}} -\usepackage{inputenc,babel} +\usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} -\usepackage{etoolbox,geometry,xcolor,bbding,txfonts,xspace,hologo,graphicx} -\usepackage{lastpage,fancyhdr,titlesec,enumitem,framed,tocloft,multirow,makecell} -\usepackage[linegoal,delarray]{tabu} -\usepackage{embedfile} +\usepackage{hologo} % bug: must be loaded before graphicx... +\usepackage{ltxnew,etoolbox,geometry,graphicx,xcolor,needspace,ragged2e} % general tools +\usepackage{lmodern,bbding,hologo,relsize,moresize,manfnt,pifont,upgreek} % fonts +\usepackage[official]{eurosym} % font +\ifx y\microtypeYN % + \usepackage[expansion=all,stretch=20,shrink=60]{microtype}\fi % font (microtype) +\usepackage{xspace,tocloft,titlesec,fancyhdr,lastpage,enumitem,marginnote} % paragraphs & pages management +\usepackage{holtxdoc,bookmark,hypbmsec,enumitem-zref} % hyper-links +\usepackage{array,delarray,longtable,colortbl,multirow,makecell,booktabs} % tabulars +\usepackage{tabularx}\tracingtabularx % tabularx +\usepackage{txfonts,framed} \usepackage{interfaces} +\usepackage{nccfoots} +\usepackage[linegoal,delarray]{tabu} \CodelineNumbered\lastlinefit999 -\usepackage{holtxdoc,bookmark} -\usepackage{linegoal} +\usepackage{embedfile} \usepackage{fancyvrb}\fvset{gobble=1,listparameters={\topsep=0pt}} -\usepackage{tabularx} +\usepackage{listings} +\lstset{ + gobble=1, + language=[LaTeX]TeX, + basicstyle=\ttfamily, + breaklines=true, + upquote=true, + backgroundcolor=\color[gray]{0.90}, + keywordstyle=\color{blue}\bfseries, + keywordstyle=[2]{\color{ForestGreen}}, + commentstyle=\ttfamily\color{violet}, + keywordstyle=[3]{\color{black}\bfseries}, + keywordstyle=[4]{\color{red}\bfseries}, + keywordstyle=[5]{\color{blue}\bfseries}, + keywordstyle=[6]{\color{green}\bfseries}, + keywordstyle=[7]{\color{yellow}\bfseries}, + %extendedchars={true}, + alsoletter={&}, +morekeywords=[1]{ + \lstdefinestyle, + \lstinputlisting,\lstset, + \color, + \geometry,\lasthline,\firsthline, + \cmidrule,\toprule,\bottomrule, + \everyrow,\tabulinestyle,\tabureset,\savetabu,\usetabu,\preamble, + \taburulecolor,\taburowcolors}, +morekeywords=[2]{ + tabular, + caption, + table, + tabu}, +morekeywords=[3]{ + &}, +morekeywords=[4]{\linegoal}, +morekeywords=[5]{blue}, +morekeywords=[6]{green}, +morekeywords=[7]{yellow}, +} \csname endofdump\endcsname \hypersetup{% pdftitle={The linegoal package}, diff --git a/Master/texmf-dist/source/latex/linegoal/linegoal.dtx b/Master/texmf-dist/source/latex/linegoal/linegoal.dtx index baeae66608b..f9245b32d94 100644 --- a/Master/texmf-dist/source/latex/linegoal/linegoal.dtx +++ b/Master/texmf-dist/source/latex/linegoal/linegoal.dtx @@ -1,5 +1,5 @@ % \iffalse meta-comment -% linegoal : 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line] +% linegoal : 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line] % % This work may be distributed and/or modified under the % conditions of the LaTeX Project Public License, either @@ -34,10 +34,9 @@ % %<*install> \input docstrip.tex -\tracingall \tracingonline=0 \Msg{************************************************************************} \Msg{* Installation} -\Msg{* Package: 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line} +\Msg{* Package: 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line} \Msg{************************************************************************} \keepsilent @@ -48,7 +47,7 @@ This is a generated file. -linegoal : 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line +linegoal : 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, either @@ -97,29 +96,83 @@ Copyright (C) 2010 by Florent Chervet \fi % %<*driver> +\let\microtypeYN=y \edef\thisfile{\jobname} -\def\thisinfo{A new ``dimen'' corresponding to the remainder of the line} -\def\thisdate{2010/12/07} -\def\thisversion{2.7} +\def\thisinfo{Measuring the remaining width of the line} +\def\thisdate{2011/02/25} +\def\thisversion{2.9} \def\CTANbaseurl{http://www.ctan.org/tex-archive/} \def\CTANhref#1#2{\href{\CTANbaseurl/help/Catalogue/entries/#1.html}{\nolinkurl{CTAN:help/Catalogue/entries/#1.html}}} \let\loadclass\LoadClass \def\LoadClass#1{\loadclass[abstracton]{scrartcl}\let\scrmaketitle\maketitle\AtEndOfClass{\let\maketitle\scrmaketitle}} \PassOptionsToPackage{svgnames}{xcolor} +{\makeatletter{\endlinechar`\^^J\obeyspaces + \gdef\ErrorUpdate#1=#2,{\@ifpackagelater{#1}{#2}{}{\let\CheckDate\errmessage\toks@\expandafter{\the\toks@ + \thisfile-documentation: updates required ! + package #1 must be later than #2 + to compile this documentation.}}}}% + \gdef\CheckDate#1{{\let\CheckDate\relax\toks@{}\@for\x:=\thisfile=\thisdate,#1\do{\expandafter\ErrorUpdate\x,}\CheckDate\expandafter{\the\toks@}}}} +\AtBeginDocument{\CheckDate{interfaces=2011/02/12,tabu=2011/02/25}} \documentclass[a4paper,oneside,american,latin1,T1]{ltxdoc} \AtBeginDocument{\DeleteShortVerb{\|}} -\usepackage{inputenc,babel} +\usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} -\usepackage{etoolbox,geometry,xcolor,bbding,txfonts,xspace,hologo,graphicx} -\usepackage{lastpage,fancyhdr,titlesec,enumitem,framed,tocloft,multirow,makecell} -\usepackage[linegoal,delarray]{tabu} -\usepackage{embedfile} +\usepackage{hologo} % bug: must be loaded before graphicx... +\usepackage{ltxnew,etoolbox,geometry,graphicx,xcolor,needspace,ragged2e} % general tools +\usepackage{lmodern,bbding,hologo,relsize,moresize,manfnt,pifont,upgreek} % fonts +\usepackage[official]{eurosym} % font +\ifx y\microtypeYN % + \usepackage[expansion=all,stretch=20,shrink=60]{microtype}\fi % font (microtype) +\usepackage{xspace,tocloft,titlesec,fancyhdr,lastpage,enumitem,marginnote} % paragraphs & pages management +\usepackage{holtxdoc,bookmark,hypbmsec,enumitem-zref} % hyper-links +\usepackage{array,delarray,longtable,colortbl,multirow,makecell,booktabs} % tabulars +\usepackage{tabularx}\tracingtabularx % tabularx +\usepackage{txfonts,framed} \usepackage{interfaces} +\usepackage{nccfoots} +\usepackage[linegoal,delarray]{tabu} \CodelineNumbered\lastlinefit999 -\usepackage{holtxdoc,bookmark} -\usepackage{linegoal} +\usepackage{embedfile} \usepackage{fancyvrb}\fvset{gobble=1,listparameters={\topsep=0pt}} -\usepackage{tabularx} +\usepackage{listings} +\lstset{ + gobble=1, + language=[LaTeX]TeX, + basicstyle=\ttfamily, + breaklines=true, + upquote=true, +% prebreak={\%\,\ding{229}}, + backgroundcolor=\color[gray]{0.90}, + keywordstyle=\color{blue}\bfseries, + keywordstyle=[2]{\color{ForestGreen}}, + commentstyle=\ttfamily\color{violet}, + keywordstyle=[3]{\color{black}\bfseries}, + keywordstyle=[4]{\color{red}\bfseries}, + keywordstyle=[5]{\color{blue}\bfseries}, + keywordstyle=[6]{\color{green}\bfseries}, + keywordstyle=[7]{\color{yellow}\bfseries}, + %extendedchars={true}, + alsoletter={&}, +morekeywords=[1]{ + \lstdefinestyle, + \lstinputlisting,\lstset, + \color, + \geometry,\lasthline,\firsthline, + \cmidrule,\toprule,\bottomrule, + \everyrow,\tabulinestyle,\tabureset,\savetabu,\usetabu,\preamble, + \taburulecolor,\taburowcolors}, +morekeywords=[2]{ + tabular, + caption, + table, + tabu}, +morekeywords=[3]{ + &}, +morekeywords=[4]{\linegoal}, +morekeywords=[5]{blue}, +morekeywords=[6]{green}, +morekeywords=[7]{yellow}, +} \csname endofdump\endcsname \hypersetup{% pdftitle={The linegoal package}, @@ -136,7 +189,7 @@ Copyright (C) 2010 by Florent Chervet % % \fi % -% \CheckSum{149} +% \CheckSum{153} % % \CharacterTable % {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z @@ -167,7 +220,7 @@ Copyright (C) 2010 by Florent Chervet % \DoNotIndex{\AtBeginDocument,\AtEndDocument,\begingroup,\endgroup} % \DoNotIndex{\frenchspacing,\MessageBreak,\newif,\PackageWarningNoLine} % \DoNotIndex{\protect,\string,\xdef,\ifx,\texttt,\@biblabel,\bibitem} -% \DoNotIndex{\z@,\wd,\wheremsg,\vrule,\voidb@x,\verb,\bibitem} +% \DoNotIndex{\z@,\wd,\wheremsg,\vrule,\voidb@x,\verb,\bibitem,\globcount,\globdimen} % \DoNotIndex{\FrameCommand,\MakeFramed,\FrameRestore,\hskip,\hfil,\hfill,\hsize,\hspace,\hss,\hbox,\hb@xt@,\endMakeFramed,\escapechar} % \DoNotIndex{\do,\date,\if@tempswa,\@tempdima,\@tempboxa,\@tempswatrue,\@tempswafalse,\ifdefined,\ifhmode,\ifmmode,\cr} % \DoNotIndex{\box,\author,\advance,\multiply,\Command,\outer,\next,\leavevmode,\kern,\title,\toks@,\trcg@where,\tt} @@ -178,18 +231,22 @@ Copyright (C) 2010 by Florent Chervet % \parindent\z@\parskip.4\baselineskip\topsep\parskip\partopsep\z@ % \newrobustcmd*\FC{{\color{copper}\usefont{T1}{fts}xn FC}} % \newrobustcmd\ClearPage{\@ifstar\clearpage{}} +% \newrobustcmd*\CTANentry[1]{\href{http://www.tex.ac.uk/tex-archive/help/Catalogue/entries/#1.html}{\xpackage{#1}}} % \def\M{\@ifstar{\M@i\@firstofone}{\M@i\meta}} -% \def\M@i#1{\@ifnextchar[^^A] -% {\M@square#1} -% {\@ifnextchar(^^A) -% {\M@paren#1} -% {\M@brace#1}}^^A -% } -% \def\M@square#1[#2]{\M@Bracket[{#1{#2}}]} -% \def\M@paren#1(#2){\M@Bracket({#1{#2}})} -% \def\M@brace#1#2{\M@Bracket\{{#1{#2}}\}} +% \def\M@i#1{\@ifnextchar[\M@square +% {\ifx (\@let@token^^A) +% \expandafter\M@paren +% \else\ifx |\@let@token +% \expandafter\expandafter\expandafter\M@bar +% \else \expandafter\expandafter\expandafter\M@brace +% \fi\fi#1}} +% \def\M@square #1[#2]{\M@Bracket[{#1{#2}}]} +% \def\M@paren #1(#2){\M@Bracket({#1{#2}})} +% \def\M@bar #1|#2|{\M@Bracket\textbar{#1{#2}}\textbar} +% \def\M@brace #1#2{\M@Bracket\{{#1{#2}}\}} % \def\M@Bracket#1#2#3{{\ttfamily#1#2#3}} % \def\pkgcolor{\color{pkgcolor}}\colorlet{pkgcolor}{teal} +% % \catcode`\§ \active \def§{\@ifnextchar §{\par\nobreak\vskip-2\parskip}{\par\nobreak\vskip-\parskip}} % \def\thispackage{\xpackage{{\pkgcolor\thisfile}}\xspace} % \def\ThisPackage{\Xpackage{\thisfile}\xspace} @@ -199,21 +256,34 @@ Copyright (C) 2010 by Florent Chervet % \def\XPackage#1{\href{\CTANbaseurl/help/Catalogue/entries/#1.html}{\xpackage{#1}}} % \newrobustcmd*\thisyear{\begingroup % \def\thisyear##1/##2\@nil{\endgroup -% \oldstylenums{##1\ifnum##1=\year\else\,\textendash\,\the\year\fi}% +% \oldstylenums{\ifnum##1=2010\else 2010\,\textendash\,\fi ##1}^^A % }\expandafter\thisyear\thisdate\@nil % } +% \newrobustcmd*\TabU[1][\pkgcolor]{\quitvmode\hbox{{#1{\larger[3]\usefont{U}{eur}mn\char"1C}$_\aleph \mkern.1666mu b\,$\rotatebox[origin=c]{-90}{\sf\smaller U}}}\xspaceverb} +% \newrobustcmd*\TABU[1][\pkgcolor]{\quitvmode\hbox{{#1{\larger[8]\usefont{U}{eur}mn\char"1C}$_\aleph \mkern.1666mu b\,$\rotatebox[origin=c]{-90}{\sf\smaller U}}}\xspaceverb} % \newcommand\macrocodecolor{\color{macrocode}}\definecolor{macrocode}{rgb}{0.08,0.00,0.15} % \newcommand\reflinkcolor{\color{reflink}}\colorlet{reflink}{DarkSlateBlue} -% \newrobustcmd\stform{\@ifnextchar*{\@stform[]\textasteriskcentered\@gobble}\@stform} -% \newrobustcmd\@stform[2][\string]{\texttbf{#1#2}\xspace} +% \newrobustcmd*\stform{\ifincsname\else\expandafter\@stform\fi} +% \newrobustcmd*\@stform{\@ifnextchar*{\@@stform[]\textasteriskcentered\@gobble}\@@stform} +% \newrobustcmd*\@@stform[2][\string]{\texttbf{#1#2}\xspaceverb} +% \newrobustcmd*\xspaceverb{\ifnum\catcode`\ =\active\else\expandafter\xspace\fi} % \DefineVerbatimEnvironment{VerbLines}{Verbatim}{gobble=1,frame=lines,framesep=6pt,fontfamily=\ttdefault,fontseries=m} % \DefineVerbatimEnvironment{Verb*}{Verbatim}{gobble=1,fontfamily=\ttdefault,fontseries=m,commandchars=$()} % \def\smex{\leavevmode\hb@xt@2em{\hfil$\longrightarrow$\hfil}} % \newcommand\texorpdf[2]{\texorpdfstring{#1{#2}}{#2}} % \renewrobustcmd\#[1]{{\usefont{T1}{pcr}{bx}{n}\char`\##1}} -% \newrobustcmd\csred[1]{\textcolor{red}{\cs{#1}}} -% \renewrobustcmd\cs[2][]{\mbox{\ttfamily#1\expandafter\@gobble\string\\#2}} -% \newrobustcmd\csbf[2][]{\textbf{\cs[{#1}]{#2}}} +% \newrobustcmd*\grabcs{\leavevmode\hbox\bgroup\bgroup\makeatletter\aftergroup\endgrabcs} +% \def\endgrabcs{\egroup\xspaceverb} +% \renewrobustcmd*\cs{\grabcs\cs@} +% \newrobustcmd*\cs@[2][]{\begingroup\escapechar\m@ne\def\x ##1{\endgroup\@maybehyperlink{##1}{\texttt{#1{\@backslashchar##1}}}}\expandafter\x\expandafter{\string#2}\egroup} +% \newrobustcmd*\@maybehyperlink [2]{\ifcsname @declcs.\detokenize{#1}\endcsname \hyperref{}{declcs}{#1}{#2}\else #2\fi} +% \newcommand*\cs@pdf[1]{\@backslashchar\if\@backslashchar\string#1 \else\string#1\fi} +% \newrobustcmd*\csbf{\cs[\textbf]} +% \newrobustcmd*\csref[2][]{{\escapechar\m@ne\edef\my@tempa{\string#2}\edef\x ##1{\noexpand\hyperref{}{declcs}{\my@tempa}{\noexpand\cs[{##1}]{\my@tempa}}}\expandafter}\x{#1}} +% \newcommand\env{\texorpdfstring \env@ \env@pdf} +% \newcommand*\env@pdf[1]{#1} +% \newrobustcmd*\env@{\@ifstar {\env@starsw[environment]}{\env@starsw[]}} +% \new\def\env@starsw[#1]#2{\textt{#2}\ifblank{#1}{}{ #1}\xspaceverb} % \newcommand\textt[1]{\texorpdf\texttt{#1}} % \newcommand\texttbf[1]{\textt{\bfseries#1}} % \newcommand\nnn{\normalfont\mdseries\upshape}\newcommand\nbf{\normalfont\bfseries\upshape} @@ -226,24 +296,52 @@ Copyright (C) 2010 by Florent Chervet % \newrobustcmd\bk{\color{black}} % \newrobustcmd\ie{\emph{ie.}} % \let\cellstrut\bottopstrut +% \newrobustcmd*\csanchor[2][]{^^A +% \immediate\write\@mainaux{\csgdef{@declcs.\string\detokenize{#2}}{}}^^A +% \raisedhyperdef[14pt]{declcs}{#2}{\cs[{#1}]{#2}}^^A +% } +% \renewrobustcmd\declcs[2][]{^^A +% \if@nobreak \par\nobreak +% \else \par\addvspace\parskip +% \Needspace{.08\textheight}\fi +% \changefont{size+=2.5pt,spread=1,fam=\ttdefault}^^A +% \def\*{\unskip\,\texttt{*}}\noindent +% \hskip-\leftmargini +% \begin{tabu}{|l|}\hline +% \expandafter\SpecialUsageIndex\csname #2\endcsname +% \csanchor[{#1}]{#2}} +% \renewcommand\enddeclcs{% +% \crcr \hline \end{tabu}\nobreak +% \par \nobreak \noindent +% \ignorespacesafterend +% } +% % \let\plainllap\llap -% \newrobustcmd\macro@llap[1]{\global\let\llap\plainllap\setbox0\hbox{#1}^^A -% \ifdim\wd0>2cm\hbox to\z@{\hss\hbox to2cm{#1\hss}}^^A -% \edef\@tempa{\the\everypar\hskip\dimexpr\the\wd0-2cm\relax\global\everypar{}}% -% \global\everypar\expandafter{\@tempa}^^A -% \else\hbox to\z@{\hss#1}\fi -% \setbox\z@\box\voidb@x} -% \pretocmd\macro{\MacrocodeTopsep=\z@skip\MacroTopsep\z@skip\let\llap\macro@llap\parsep=\z@\topsep=\z@\itemsep=\z@\partopsep\z@}{}{} -% \apptocmd\endmacro{\goodbreak\vskip.3\parskip}{}{} +% \newrobustcmd\macro@llap[1]{{\global\let\llap\plainllap +% \setbox0=\hbox\bgroup \raisedhyperdef{macro}{\saved@macroname}{#1}\egroup +% \ifdim\wd0>20mm +% \hbox to\z@ \bgroup\hss \hbox to20mm{\unhcopy0\hss}\egroup +% \edef\@tempa{\hskip\dimexpr\the\wd0-20mm}\global\everypar\expandafter{\the\expandafter\everypar +% \@tempa \global\everypar{}}^^A +% \else \llap{\unhbox0}\fi}} +% \AtBeginEnvironment{macro}{\if@nobreak\else\Needspace{2\baselineskip}\fi +% \MacrocodeTopsep\z@skip \MacroTopsep\z@skip \parsep\z@ \topsep\z@ \itemsep\z@ \partopsep\z@ +% \let\llap\macro@llap} +% \AtEndEnvironment{macro}{\goodbreak\vskip.3\parskip} +% % \sectionformat\section[hang]{ % bookmark={color=MidnightBlue}, % bottom=\smallskipamount,top=\medskipamount, % } +% \sectionformat\subsection{ +% bookmark={color=MidnightBlue}, +% } % \pagesetup{% % norules, % font=\scriptsize\color[gray]{.55}, -% head/color=pkgcolor, -% head/left=\moveleft1cm\vbox to\z@{\vss\setbox0=\null\ht0=\z@\wd0=\paperwidth\dp0=\headheight\rlap{\colorbox{Ivory}{\box0}}}\vskip-\headheight\thispackage, +% head/font+=\sffamily, +% head/left=\moveleft1cm\vbox to\z@{\vss\setbox0=\null\ht0=\z@\wd0=\paperwidth\dp0=\headheight\rlap{\colorbox{Ivory}{\box0}}}\vskip-\headheight{\color{pkgcolor!60}\bfseries l\,i\,n\,e\,g\,o\,a\,l}, +% head/right/font+=\color{pkgcolor!40}\mdseries, % head/right=\thisinfo, % foot/left=\vbox to\baselineskip{\vss{{\rotatebox[origin=l]{90}{\thispackage\,[rev.\thisversion]\,\copyright\,\thisyear\,\lower.4ex\hbox{\pkgcolor\NibRight}\,\FC}}}}, % left/offset=1.5cm, @@ -259,66 +357,66 @@ Copyright (C) 2010 by Florent Chervet % foot/left=\vbox to\baselineskip{\vss{{\rotatebox[origin=l]{90}{\thispackage\,[rev.\thisversion]\,\copyright\,\thisyear\,\lower.4ex\hbox{\pkgcolor\NibRight}\,\FC\quad \xemail{florent.chervet at free.fr}}}}}, % } % \bookmarksetup{openlevel=3} -% \makeatother % -% \deffootnote{1em}{0pt}{\rlap{\textsuperscript{\thefootnotemark}}\kern1em} -% \title{\vspace*{-28pt}\mdseries The {\bfseries\thispackage\footnotemark}\kern.6em package} -% \author{\small\thisdate~--~version \thisversion} +% \title{\vspace*{-28pt}\href{http://www.tex.ac.uk/tex-archive/help/Catalogue/entries/linegoal.html}{\HUGE\bfseries\sffamily\color{CornflowerBlue}\@backslashchar\,l\,i\,n\,e\,g\,o\,a\,l}\Footnotemark{*}\vspace*{6pt}} +% \author{\small\thisdate~--~\hyperref[\thisversion]{version \thisversion}} % \date{} -% \subtitle{\LARGE A new ``dimen'' corresponding to the remainder of the line\endgraf{\small\FC}} +% \subtitle{\begin{tabu}{X[c]}\LARGE A ``dimen'' measuring the remainder of the line\\[1ex] requires \hologo{pdfTeX} or \hologo{XeTeX}\\ \small\FC \end{tabu}\vspace*{-12pt}} +% \makeatother % \maketitle % -% \makeatletter\begingroup\let\@thefnmark\@empty\let\@makefntext\@firstofone -% \footnotetext{\noindent -% This documentation is produced with the +DocStrip+ utility. -% \begin{tabbing} -% \qquad\=\smex\=To get the documentation, \= run (thrice):\quad\= \textt{pdflatex \thisfile.dtx} \\ -% \qquad\>\>To get the index, \> run:\>\texttt{makeindex -s gind.ist \thisfile.idx} \\ -% \>\smex\>To get the package, \> run:\> \texttt{etex \thisfile.dtx} -% \end{tabbing}§ -% The \xext{dtx} file is embedded into this pdf file thank to \xpackage{embedfile} by H. Oberdiek.} +% \makeatletter\begingroup +% \Footnotetext{\rlap{*}\kern1em}{\noindent +% This documentation is produced with the \textt{DocStrip} utility.\par +% \begin{tabu}{X[-3]X[-1]X} +% \smex To get the package, &run: &\texttt{etex \thisfile.dtx} \\ +% \smex To get the documentation &run (thrice): &\textt{pdflatex \thisfile.dtx} \\ +% \leavevmode\hphantom\smex To get the index, &run: &\texttt{makeindex -s gind.ist \thisfile.idx} +% \end{tabu}§ +% The \xext{dtx} file is embedded into this pdf file thank to \XPackage{embedfile} by H. Oberdiek.} % \endgroup\makeatother % -% \deffootnote{1em}{0pt}{\rlap{\thefootnotemark.}\kern1em} -% {\vspace*{-16pt}\let\quotation\relax +% \deffootnote{1em}{0pt}{\rlap{\thefootnotemark.}\kern1em}\setcounter{footnote}{0} +% {\vspace*{-12mm}\let\quotation \relax \let\endquotation \relax % \begin{abstract}\parskip\medskipamount\parindent0pt\lastlinefit0\relax\rightskip1.5cm\leftskip\rightskip\advance\linewidth by-2\leftskip % -% \thispackage provides a macro \csbf{linegoal} which expands to the dimension of the remainder of the line. -% It requires \hologo{pdfTeX} for its \cs{pdfsavepos} primitive. With \hologo{pdfTeX}, \cs{pdfsavepos} works -% in \textt{pdf} mode (\cs{pdfoutput}>0) \textbf{and also in} \textt{dvi} mode (\cs{pdfoutput}=0). -% Two compilations (at least) are necessary to get the correct line goal.§ -% {\centering\extrarowheight\parskip -% \begin{tabular}{ll} -% Saying: &\Verb+\somedimen = \linegoal+ \\ -% or: &\Verb+\setlength \somedimen {\linegoal}+ -% \end{tabular}\par} +% \thispackage provides a single macro: \cs\linegoal \, which expands to the dimension of the remainder of the line. +% It requires \hologo{pdfTeX} (or \hologo{XeTeX}) for its \cs\pdfsavepos primitive. +% With \hologo{pdfTeX}, \cs\pdfsavepos works in \textt{pdf} mode (\cs\pdfoutput$>0$) \textbf{and also in} \textt{dvi} mode (\cs\pdfoutput$=0$). +% Two compilations (at least) are necessary to get the correct ``line goal''.§ +% {\centering\extrarowsep=.3\parskip +% \begin{tabu*}{ll} +% Saying: &\cs\somedimen = \cs\linegoal \quad\footnote{Note that only this syntax allows the \cs\global preffix in case the \XPackage{calc} package is loaded.} \\ +% or: &\cs\setlength \cs\somedimen \M*{\cs\linegoal} +% \end{tabu*} +% \par +% } % -% sets \cs{somedimen} to be the (horizontal) length of the remainder of the current line. This can be useful for +% sets \cs\somedimen to be the (horizontal) length from the current position to the right margin. This can be useful for % use with \XPackage{tabu},\, \XPackage{tabularx},\, or\, \textt{tabular\stform*}\, for example.§ % {\centering\extrarowheight\parskip % \begin{tabu} to\linewidth{@{}lX} -% At first run: &\cs{linegoal} expands to \cs{linewidth} and writes the correct line goal into the \xext{aux} file. \\ -% Other runs: &\cs{linegoal} expands to the value read in the \xext{aux} file and (eventually) updates the +% At first run: &\cs\linegoal expands to \cs\linewidth and writes the correct line goal into the \xext{aux} file. \\ +% Other runs: &\cs\linegoal expands to the value read in the \xext{aux} file and (eventually) updates the % correct line-goal into the \xext{aux} file, if the value has changed. % \end{tabu}\par} % -% \textbf{Limitation:} if \cs{linegoal} is used inside an expression with \cs{dimexpr}, \cs{glueexpr} or -% inside \cs{setlength} (package \xpackage{calc}), then \cs{linegoal} must be at the very last position in the expression: +% Limitation when using \cs\linegoal inside \xpackage{calc} of \hologo{eTeX} expressions: % +% If \cs\linegoal is used inside an expression with \cs\dimexpr, \cs\glueexpr or +% inside \cs\setlength (package \xpackage{calc}), then \cs\linegoal \textbf{must appear at the very last position in the expression}: % -% \begin{tabu}to\linewidth{XX[-1m]} -% \begin{tabu}[c].{X}\} -% \verbatim{^^A -% \begin{tabu} to\dimexpr-2in + .5\linegoal{XX} ....^^@ -% \setlength \dimen@ {-2in + .5\linegoal}} -% \end{tabu} -% & -% are admissible -% \end{tabu} +% \begin{tabu*}spread0pt .{X}\} +% \begin{Verbatim} +% \begin{tabu} to\dimexpr-2in + .5\linegoal{XX} .... +% \setlength \dimen@ {-2in + .5\linegoal} +% \end{tabu} +% \end{Verbatim} +%\end{tabu*} +%\, are admissible. % -% -% \thispackage requires pdf\TeX{} (in \textt{pdf} or \textt{dvi} mode) -% and the module \xpackage{zref-savepos} of \XPackage{zref} package. +% \thispackage requires \hologo{pdfTeX} (in \textt{pdf} or \textt{dvi} mode) +% or \hologo{XeTeX} and the module \xpackage{zref-savepos} of \XPackage{zref}. % % \end{abstract}} % @@ -328,9 +426,9 @@ Copyright (C) 2010 by Florent Chervet % section/dotsep,subsection/dotsep=,subsection/pagenumbers=off, % dotsep=1.5mu, % dot=\hbox{\scriptsize.}, -% title=Contents\quad\leaders\vrule height3.4pt depth-3pt\hfill\null, +% title={\pkgcolor\leaders\vrule height3.4pt depth-3pt\hfill\null}\quad Contents of \thisfile\quad{\pkgcolor\leaders\vrule height3.4pt depth-3pt\hfill\null}, % title/bottom=6pt, -% after=\leavevmode\hrule, +% after=\leavevmode{\pkgcolor\hrule}, % columns=2, % } % @@ -343,24 +441,29 @@ Copyright (C) 2010 by Florent Chervet % % \subsection{\cs{linegoal}: a macro which behaves mostly like a \textt{dimen}} % -% The first aim of \cs{linegoal} is to give a facility to get the length of the remainder of the line. -% This is possible with \hologo{pdfTeX} and its \cs{pdfsavepos} primitive. For convenience, \thispackage loads -% and uses the \xpackage{zref-savepos} package from H. Oberdiek. +% \begin{declcs}{linegoal} +% \end{declcs} +% +% The first aim of \cs\linegoal is to give a facility to get the length of the remainder of the line. +% This is possible with \hologo{pdfTeX} and its \cs\pdfsavepos primitive (which is supplied by \hologo{XeTeX} as well). +% For convenience, \thispackage loads and uses the \xpackage{zref-savepos} package from H. Oberdiek. % -% \cs{pdfsavepos} is supplied by \hologo{pdfTeX} in both \textt{pdf} and \textt{dvi} modes. If the document -% is not compiled with \hologo{pdfTeX} then \cs{linegoal} will expand to \cs{linewidth} in any case. +% \cs\pdfsavepos is supplied by \hologo{pdfTeX} (and \hologo{XeTeX}) in both \textt{pdf} and \textt{dvi} modes. +% If the document is not compiled with \hologo{pdfTeX} or \hologo{XeTeX} then \cs\linegoal will expand to \cs\linewidth +% in any case. % -% \begin{VerbLines} +% {\fontname\font \hologo{XeTeX} {\changefont{fam=cmr}\hologo{XeTeX}}} +% +% \begin{VerbLines}[commandchars=£()] % This is a tabularx that fills the remainder of the line: -% \begin{tabularx}\linegoal{|l|X|}\hline +% \begin{tabularx}(£rred(\linegoal)){|l|X|}\hline % Something & Something else \\ % Something & Something else \\\hline % \end{tabularx} % \end{VerbLines} % -% \textbf{Typical application is for tabulars of variable width} like \xpackage{tabularx} or \xpackage{tabu}. -% Package \xpackage{tabu} has a \textt{linegoal} option to use \cs{linegoal} as default target for the whole -% tabular. +% \textbf{Typical application is for tabulars of variable width} like \CTANentry{tabularx} or \CTANentry{tabu}. +% Package \TabU has a \textt{linegoal} option to use \cs\linegoal as the default target for the whole tabular. % % % This is a \textt{tabularx} that fills the remainder of the line: @@ -369,40 +472,46 @@ Copyright (C) 2010 by Florent Chervet % Something & Something else \\\hline % \end{tabularx} % -% \begin{VerbLines} -% This is a tabu that fills the half of the remainder of the line: -% $\begin{tabu}to .5\linegoal{|[red]X[$c]|[red]X[2$c]|[red]} \tabucline[red]- -% \alpha & \beta \\ \tabucline[on 2pt,red]- -% \gamma & \delta \\ \tabucline[red]- -% \end{tabu}$ -% \end{VerbLines} +% {\smaller +% \begin{lstlisting}[caption={This is a \env{tabu} that fills the half of the remainder of the line}] +% \tabulinestyle{red} +% $\begin{tabu} to .5\linegoal {|X[$c]|X[2$c]|} \tabucline- +% \alpha & \beta \\ \tabucline[on2pt red]- +% \gamma & \delta \\ \tabucline- +% \end{tabu}$ +% \end{lstlisting} +% } % % This is a \textt{tabu} that fills the half of the remainder of the line: -% $\begin{tabu}to .5\linegoal{|[red]X[$c]|[red]X[2$c]|[red]} \tabucline[red]- +% {\tabulinestyle{red} +% $\begin{tabu}to .5\linegoal{|X[$c]|X[2$c]|} \tabucline- % \alpha & \beta \\ \tabucline[on 2pt,red]- -% \gamma & \delta \\ \tabucline[red]- -% \end{tabu}$ +% \gamma & \delta \\ \tabucline- +% \end{tabu}$ +% } % -% Please, refer to \xpackage{tabu} documentation for more information on the preamble and -% the command \cs{tabucline} used here as an example. +% Please, refer to \CTANentry{tabu} documentation +% for more information on the preamble and the command \cs\tabucline used here as an example. % % \subsection{The \textt{verbose} package option} % % You can load \thispackage with the \M*[verbose] option to get the line-goals -% as information in your \xext{log} file. -% +% as information in the \xext{log} file. % % \StopEventually{ % } % -% \bookmarksetup{bold=false} +% \bookmarksetup{bold*} +% \sectionformat\subsection{ +% bookmark={color=gray}, +% } % \section{Implementation} \label{sec:implementation} % \csdef{HDorg@PrintMacroName}#1{\hbox to4em{\strut \MacroFont \string #1\ \hss}} % % \subsection{Identification} % % \begin{itemize} -% \item The package namespace is \texttbf{\macrocodecolor\string\LNGL@} +% \item The package namespace is \cs\LNGL@ % \end{itemize} % % \begin{macrocode} @@ -410,15 +519,13 @@ Copyright (C) 2010 by Florent Chervet \NeedsTeXFormat{LaTeX2e}% LaTeX 2.09 can't be used (nor non-LaTeX) [2005/12/01]% LaTeX must be 2005/12/01 or younger \ProvidesPackage{linegoal} - [2010/12/07 v2.7 - A new dimen corresponding to the remainder of the line] + [2011/02/25 v2.9 - Measuring the remaining width of the line] % \end{macrocode} % % \subsection{Requirements} % % The package requires \xpackage{zref} and its module \xpackage{zref-savepos}. % -% It requires \xpackage{srclfile} for a patch when using the \xpackage{calc} package. -% % \begin{macrocode} \ifdefined\pdfsavepos\else % works also in dvi mode \PackageWarning{linegoal} @@ -435,7 +542,7 @@ Copyright (C) 2010 by Florent Chervet % % \begin{macrocode} \zref@newprop*{linegoal}[\linewidth]{\dimexpr - \linewidth-\the\pdflastxpos sp + \linewidth -\the\pdflastxpos sp +\ifodd\zref@extractdefault{linegoal/posx.\the\LNGL@unique}{page}\c@page \oddsidemargin \else\evensidemargin @@ -445,17 +552,25 @@ Copyright (C) 2010 by Florent Chervet }% linegoal zref-property % \end{macrocode} % -% % \subsection{The linegoal macro} % % \begin{macro}{\linegoal} +% +% \cs\linegoal first expands to the current value (\cs\linewidth or the line goal stored +% in the \xext{aux} file as a \xpackage{zref} property). +% +% Thereafter, \cs\LNGL@setlinegoal is expanded in order to set the new value of the \xpackage{zref} property, +% to be used for the next compilation. The case is slightly different when using the \xpackage{calc} package, +% for \cs\setlength is modified by the \xpackage{calc} package. +% % \begin{macrocode} \newcommand*\linegoal{% \zref@extract{linegoal.\the\LNGL@unique}{linegoal}\LNGL@setlinegoal }% \linegoal -\globcount\LNGL@unique -\globdimen\LNGL@tempdim -\def\LNGL@setlinegoal{\relax\csname LNGL@set\ifdefined\calc@next!\fi\endcsname} +\globcount \LNGL@unique +\globdimen \LNGL@tempdim +\def\LNGL@setlinegoal {\relax \LNGL@set@linegoal} +\protected\def\LNGL@set@linegoal{\csname LNGL@set\ifdefined\calc@next!\fi\endcsname} \expandafter\def\csname LNGL@set!\endcsname!{!\LNGL@set} \protected\def\LNGL@set{% \@bsphack @@ -504,70 +619,83 @@ Copyright (C) 2010 by Florent Chervet % \end{macrocode} % \end{macro} % -% % \begin{macrocode} % % \end{macrocode} % % \DeleteShortVerb{\+} % -% \begin{thebibliography}{9} -% -% \bibitem{zref} -% \textit{The \xpackage{zref} package} by Heiko Oberdiek \\ -% 2010/05/01 v2.17 New reference scheme for LaTeX2e \\ -% \href{http://www.ctan.org/tex-archive/help/Catalogue/entries/zref.html}{\nolinkurl{CTAN:help/Catalogue/entries/zref.html}} -% -% \bibitem{tabu} -% \textit{The \xpackage{tabu} package} by \FC \\ -% 2010/12/07 v1.5 - flexible LaTeX tabulars \\ -% \href{http://www.ctan.org/tex-archive/help/Catalogue/entries/tabu.html}{\nolinkurl{CTAN:help/Catalogue/entries/tabu.html}} -% -% \end{thebibliography} -% +% \addtocontents{toc}{\tocsetup{subsection/font+=\smaller}} % \begin{History} -% \sectionformat\subsection{font=,bottom=\smallskipamount,top=\medskipamount} +% \sectionformat\subsection{font=\normalsize\pkgcolor,bottom=0pt,top=\smallskipamount} +% +% \begin{Version}{2011/02/25 v2.9}\HistLabel{2.9} +% \item Modification of \cs\LNGL@setlinegoal in order to be able to use \cs\linegoal inside the argument of tabulars (or \cs\multicolumn) +% \texttbf p (or \texttbf m or \texttbf b) columns when the \xpackage{calc} package is loaded.\\ +% \xfile{array.sty} unfortunately expands the argument of \texttbf p, \texttbf m of \texttbf b columns during the rewritting process... \\ \par\vskip-\baselineskip +% {\centering +% \begin{tabu} .{>\small l}\} +% \cs\edef\cs\x\M*{\cs\linegoal} \\ +% \cs\setlength\cs\somedimen \M*{\cs\x} +% \end{tabu} +% now works...\par} +% \end{Version} +% +% \begin{Version}{2011/01/15 v2.8}\HistLabel{2.8} +% \item Banner modification. +% \end{Version} % -% \begin{Version}{2010/12/07 v2.7} +% \begin{Version}{2010/12/07 v2.7}\HistLabel{2.7} % \item Updated documentation. Compatibility with \xpackage{tabu} package (version \textt{1.5 -- 2010/12/07}). % \end{Version} % -% \begin{Version}{2010/11/30 v2.6} +% \begin{Version}{2010/11/30 v2.6}\HistLabel{2.6} % \item Added the \textt{verbose} package option. % \end{Version} % -% \begin{Version}{2010/11/19 v2.2} -% \item Fix a bug when using a syntax like \textt{.5\cs{linegoal}}. \\ +% \begin{Version}{2010/11/19 v2.2}\HistLabel{2.2} +% \item Fix a bug when using a syntax like \textt{.5\cs\linegoal}. \\ % Hence a better fitting with \xpackage{tabu} package (version \textt{1.4 -- 2010/11/20}). % \end{Version} % -% \begin{Version}{2010/10/31 v2.1} -% \item \thispackage works also without \hologo{pdfTeX}, but \cs{linegoal} -% is replaced by \cs{linewidth} in any case. \\ +% \begin{Version}{2010/10/31 v2.1}\HistLabel{2.1} +% \item \thispackage works also without \hologo{pdfTeX}, but \cs\linegoal +% is replaced by \cs\linewidth in any case. \\ % A warning is displayed. % \end{Version} % -% \begin{Version}{2010/09/25 v2.0} -% \item New approach: \cs{setlength} is not used anymore. \\ -% \cs{linegoal} behaves more like a real dimen. \\ -% code like: \cs{hspace}\textasteriskcentered\cs{linegoal} is now possible. +% \begin{Version}{2010/09/25 v2.0}\HistLabel{2.0} +% \item New approach: \cs\setlength is not used anymore. \\ +% \cs\linegoal behaves more like a real dimen. \\ +% code like: \cs\hspace\textasteriskcentered\cs\linegoal is now possible. % \end{Version} % -% \begin{Version}{2010/06/20 v1.2} +% \begin{Version}{2010/06/20 v1.2}\HistLabel{1.2} % \item Modification in warning message... % \end{Version} % -% \begin{Version}{2010/06/06 v1.1} +% \begin{Version}{2010/06/06 v1.1}\HistLabel{1.1} % \item The first release required some small corrections ! % \end{Version} % -% \begin{Version}{2010/05/07 v1.0} +% \begin{Version}{2010/05/07 v1.0}\HistLabel{1.0} % \item First version. % \end{Version} % % \end{History} % -% +% \begin{thebibliography}{9} +% +% \bibitem{zref} +% \textit{The \CTANentry{zref} package} by Heiko Oberdiek \\ +% 2010/05/01 v2.17 New reference scheme for LaTeX2e \\ +% +% \bibitem{tabu} +% \textit{The \CTANentry{tabu} package} by \FC \\ +% 2011/02/24 v2.6 - flexible LaTeX tabulars \\ +% +% \end{thebibliography} +% % \bookmarksetup{openlevel=1} % \PrintIndex % diff --git a/Master/texmf-dist/source/latex/linegoal/linegoal.ins b/Master/texmf-dist/source/latex/linegoal/linegoal.ins index 270650d1e06..4a93d0112f8 100644 --- a/Master/texmf-dist/source/latex/linegoal/linegoal.ins +++ b/Master/texmf-dist/source/latex/linegoal/linegoal.ins @@ -8,7 +8,7 @@ %% %% This is a generated file. %% -%% linegoal : 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line +%% linegoal : 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line %% %% This work may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either @@ -24,10 +24,9 @@ %% Copyright (C) 2010 by Florent Chervet %% \input docstrip.tex -\tracingall \tracingonline=0 \Msg{************************************************************************} \Msg{* Installation} -\Msg{* Package: 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line} +\Msg{* Package: 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line} \Msg{************************************************************************} \keepsilent @@ -38,7 +37,7 @@ This is a generated file. -linegoal : 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line +linegoal : 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line This work may be distributed and/or modified under the conditions of the LaTeX Project Public License, either diff --git a/Master/texmf-dist/tex/latex/linegoal/linegoal.sty b/Master/texmf-dist/tex/latex/linegoal/linegoal.sty index 28ece1f153e..b5180c41a08 100644 --- a/Master/texmf-dist/tex/latex/linegoal/linegoal.sty +++ b/Master/texmf-dist/tex/latex/linegoal/linegoal.sty @@ -8,7 +8,7 @@ %% %% This is a generated file. %% -%% linegoal : 2010/12/07 v2.7 - linegoal : a new dimen corresponding to the remainder of the line +%% linegoal : 2011/02/25 v2.9 - linegoal : a new dimen corresponding to the remainder of the line %% %% This work may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either @@ -26,7 +26,7 @@ \NeedsTeXFormat{LaTeX2e}% LaTeX 2.09 can't be used (nor non-LaTeX) [2005/12/01]% LaTeX must be 2005/12/01 or younger \ProvidesPackage{linegoal} - [2010/12/07 v2.7 - A new dimen corresponding to the remainder of the line] + [2011/02/25 v2.9 - Measuring the remaining width of the line] \ifdefined\pdfsavepos\else % works also in dvi mode \PackageWarning{linegoal} {This package requires pdfTeX for its \string\pdfsavepos\space primitive\MessageBreak @@ -37,7 +37,7 @@ \fi \RequirePackage{etex,zref,zref-savepos} \zref@newprop*{linegoal}[\linewidth]{\dimexpr - \linewidth-\the\pdflastxpos sp + \linewidth -\the\pdflastxpos sp +\ifodd\zref@extractdefault{linegoal/posx.\the\LNGL@unique}{page}\c@page \oddsidemargin \else\evensidemargin @@ -48,9 +48,10 @@ \newcommand*\linegoal{% \zref@extract{linegoal.\the\LNGL@unique}{linegoal}\LNGL@setlinegoal }% \linegoal -\globcount\LNGL@unique -\globdimen\LNGL@tempdim -\def\LNGL@setlinegoal{\relax\csname LNGL@set\ifdefined\calc@next!\fi\endcsname} +\globcount \LNGL@unique +\globdimen \LNGL@tempdim +\def\LNGL@setlinegoal {\relax \LNGL@set@linegoal} +\protected\def\LNGL@set@linegoal{\csname LNGL@set\ifdefined\calc@next!\fi\endcsname} \expandafter\def\csname LNGL@set!\endcsname!{!\LNGL@set} \protected\def\LNGL@set{% \@bsphack -- cgit v1.2.3