Am Montag 18 November 2013, 05:32:31 schrieb Donjan Rodic:
> I'm using the overlay functionality of TikZ, which requires at least one
> more rerun than Lyx currently does. It's the same problem as with
> http://www.mail-archive.com/[email protected]/msg89501.html
> just in another package. The workaround of hitting Ctrl+R, adding a
> change (e.g. whitespace), then Ctrl+R again works, but clearly lacks in
> elegance.
> 
> How can I produce the necessary output to help make Lyx check for the
> rerun? I'm attaching an example file that simply connects two points
> with an arrow line in an overlay. That line always lags behind one
> change step.

The problem is that LyX needs some clear rerun statement in the log file, but 
tikz does not issue one, so LyX is unable to guess whether a rerun statement 
is needed or not.

Fortunately, the great Heiko Oberdiek has written yet another package which 
fixes exactly this (and other pgf/tikz shortcomings). See
http://tex.stackexchange.com/questions/82063/programming-tex-macros-so-that-they-output-instructions-to-rerun-the-compilation

Despite the announcement, the package is not yet published on CTAN, so I've 
unpacked the version posted to sx, see attachment.
Adding \usepackage{hopgf} to the preamble seems to cure your problem.

HTH
Jürgen

> cheers
> Donjan Rodic

%%
%% This is file `hopgf.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% hopgf.dtx  (with options: `package')
%% 
%% This is a generated file.
%% 
%% Project: hopgf
%% Version: 2012/09/29 v1.0
%% 
%% Copyright (C) 2012 by
%%    Heiko Oberdiek <heiko.oberdiek at googlemail.com>
%% 
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.3c of this license or (at your option) any later
%% version. This version of this license is in
%%    http://www.latex-project.org/lppl/lppl-1-3c.txt
%% and the latest version of this license is in
%%    http://www.latex-project.org/lppl.txt
%% and version 1.3 or later is part of all distributions of
%% LaTeX version 2005/12/01 or later.
%% 
%% This work has the LPPL maintenance status "maintained".
%% 
%% This Current Maintainer of this work is Heiko Oberdiek.
%% 
%% The Base Interpreter refers to any `TeX-Format',
%% because some files are installed in TDS:tex/generic//.
%% 
%% This work consists of the main source file hopgf.dtx
%% and the derived files
%%    hopgf.sty, hopgf.pdf, hopgf.ins, hopgf.drv, hopgf.bib,
%%    hopgf-test1.tex, hopgf-test-alpha.tex,
%%    hopgf-test-sysmark.tex.
%% 
\begingroup\catcode61\catcode48\catcode32=10\relax%
  \catcode13=5 % ^^M
  \endlinechar=13 %
  \catcode35=6 % #
  \catcode39=12 % '
  \catcode44=12 % ,
  \catcode45=12 % -
  \catcode46=12 % .
  \catcode58=12 % :
  \catcode64=11 % @
  \catcode123=1 % {
  \catcode125=2 % }
  \expandafter\let\expandafter\x\csname [email protected]\endcsname
  \ifx\x\relax % plain-TeX, first loading
  \else
    \def\empty{}%
    \ifx\x\empty % LaTeX, first loading,
      % variable is initialized, but \ProvidesPackage not yet seen
    \else
      \expandafter\ifx\csname PackageInfo\endcsname\relax
        \def\x#1#2{%
          \immediate\write-1{Package #1 Info: #2.}%
        }%
      \else
        \def\x#1#2{\PackageInfo{#1}{#2, stopped}}%
      \fi
      \x{hopgf}{The package is already loaded}%
      \aftergroup\endinput
    \fi
  \fi
\endgroup%
\begingroup\catcode61\catcode48\catcode32=10\relax%
  \catcode13=5 % ^^M
  \endlinechar=13 %
  \catcode35=6 % #
  \catcode39=12 % '
  \catcode40=12 % (
  \catcode41=12 % )
  \catcode44=12 % ,
  \catcode45=12 % -
  \catcode46=12 % .
  \catcode47=12 % /
  \catcode58=12 % :
  \catcode64=11 % @
  \catcode91=12 % [
  \catcode93=12 % ]
  \catcode123=1 % {
  \catcode125=2 % }
  \expandafter\ifx\csname ProvidesPackage\endcsname\relax
    \def\x#1#2#3[#4]{\endgroup
      \immediate\write-1{Package: #3 #4}%
      \xdef#1{#4}%
    }%
  \else
    \def\x#1#2[#3]{\endgroup
      #2[{#3}]%
      \ifx#1\@undefined
        \xdef#1{#3}%
      \fi
      \ifx#1\relax
        \xdef#1{#3}%
      \fi
    }%
  \fi
\expandafter\x\csname [email protected]\endcsname
\ProvidesPackage{hopgf}%
  [2012/09/29 v1.0 Some fixes for pgf (HO)]%
\begingroup\catcode61\catcode48\catcode32=10\relax%
  \catcode13=5 % ^^M
  \endlinechar=13 %
  \catcode123=1 % {
  \catcode125=2 % }
  \catcode64=11 % @
  \def\x{\endgroup
    \expandafter\edef\csname hopgf@AtEnd\endcsname{%
      \endlinechar=\the\endlinechar\relax
      \catcode13=\the\catcode13\relax
      \catcode32=\the\catcode32\relax
      \catcode35=\the\catcode35\relax
      \catcode61=\the\catcode61\relax
      \catcode64=\the\catcode64\relax
      \catcode123=\the\catcode123\relax
      \catcode125=\the\catcode125\relax
    }%
  }%
\x\catcode61\catcode48\catcode32=10\relax%
\catcode13=5 % ^^M
\endlinechar=13 %
\catcode35=6 % #
\catcode64=11 % @
\catcode123=1 % {
\catcode125=2 % }
\def\TMP@EnsureCode#1#2{%
  \edef\hopgf@AtEnd{%
    \hopgf@AtEnd
    \catcode#1=\the\catcode#1\relax
  }%
  \catcode#1=#2\relax
}
\TMP@EnsureCode{45}{12}% -
\TMP@EnsureCode{46}{12}% .
\TMP@EnsureCode{47}{12}% /
\TMP@EnsureCode{62}{12}% >
\TMP@EnsureCode{91}{12}% [
\TMP@EnsureCode{93}{12}% ]
\edef\hopgf@AtEnd{\hopgf@AtEnd\noexpand\endinput}
\begingroup\expandafter\expandafter\expandafter\endgroup
\expandafter\ifx\csname RequirePackage\endcsname\relax
  \def\TMP@RequirePackage#1[#2]{%
    \begingroup\expandafter\expandafter\expandafter\endgroup
    \expandafter\ifx\csname ver@#1.sty\endcsname\relax
      \input #1.sty\relax
    \fi
  }%
\else
  \let\TMP@RequirePackage\RequirePackage
\fi
\TMP@RequirePackage{infwarerr}[2010/04/08]%
\TMP@RequirePackage{ltxcmds}[2011/11/09]%
\ltx@newif\ifhopgf@latex
\ltx@IfUndefined{@newl@bel}{%
}{%
  \ltx@IfUndefined{RequirePackage}{%
  }{%
    \ltx@IfUndefined{AtBeginDocument}{%
    }{%
      \hopgf@latextrue
    }%
  }%
}
\ifhopgf@latex
  \RequirePackage{hopatch}[2011/06/24]%
  \def\hopgf@PatchAfterPackage#1#2{%
    \ltx@IfUndefined{#1}{%
      \hopatch@AfterPackage{#2}%
    }\ltx@firstofone
  }%
\else
  \def\hopgf@PatchAfterPackage#1{%
    \ltx@IfUndefined{#1}\ltx@gobbletwo\ltx@secondoftwo
  }%
\fi
\hopgf@PatchAfterPackage{pgffor@makealphabetic}{pgffor}{%
  \def\hopgf@tmp#1{%
    \pgfutil@tempcnta=#1\relax
    \ifnum\pgfutil@tempcnta>95\relax
      \advance\pgfutil@tempcnta by-96%
      \expandafter\def\expandafter#1\expandafter{%
        \pgffor@alpha\pgfutil@tempcnta
      }%
    \else
      \advance\pgfutil@tempcnta by-64%
      \expandafter\def\expandafter#1\expandafter{%
        \pgffor@Alpha\pgfutil@tempcnta
      }%
    \fi
  }%
  \ifx\hopgf@tmp\pgffor@makealphabetic
    \def\pgffor@makealphabetic#1{%
      \pgfutil@tempcnta=#1%
      \advance\pgfutil@tempcnta
        -\ifnum\pgfutil@tempcnta>95 96\else 64\fi
      \edef#1{\pgffor@alpha\pgfutil@tempcnta}%
    }%
    \@PackageInfoNoLine{hopgf}{%
      \ltx@backslashchar pgffor@makealphabetic fixed%
    }%
  \else
    \@PackageInfoNoLine{hopgf}{%
      \ltx@backslashchar pgffor@makealphabetic is not fixed%
    }%
  \fi
}
\ifhopgf@latex
  \hopgf@PatchAfterPackage{pgfsyspdfmark}{pgfsys}{%
    \def\hopgf@tmp#1#2#3{%
      \expandafter
      \gdef\csname pgf@sys@pdf@mark@pos@#1\endcsname{%
        \pgfqpoint{#2sp}{#3sp}%
      }%
    }%
    \ifx\hopgf@tmp\pgfsyspdfmark
      \def\pgfsyspdfmark#1#2#3{%
        \@newl@bel{pgf@sys@pdf@mark@pos}{#1}{\pgfqpoint{#2sp}{#3sp}}%
      }%
      \@PackageInfoNoLine{hopgf}{%
        \ltx@backslashchar pgfsyspdfmark patched%
      }%
    \else
      \@PackageInfoNoLine{hopgf}{%
        \ltx@backslashchar pgfsyspdfmark is not patched%
      }%
    \fi
  }%
\fi
\ifhopgf@latex
  \RequirePackage{auxhook}[2011/03/04]%
  \AddLineBeginAux{%
    \string\providecommand\string\pgfsyspdfmark[3]{}%
  }%
\fi
\hopgf@AtEnd%
\endinput
%%
%% End of file `hopgf.sty'.

Reply via email to