]> git.lyx.org Git - features.git/commitdiff
fix bug 2623:
authorJürgen Spitzmüller <spitz@lyx.org>
Mon, 29 May 2006 14:49:08 +0000 (14:49 +0000)
committerJürgen Spitzmüller <spitz@lyx.org>
Mon, 29 May 2006 14:49:08 +0000 (14:49 +0000)
* lib/layouts/memoir.layout:
add ProvidesMakeindex

* src/LaTeX.C (run):
rerun latex im idx file is empty (needed by memoir)
fix typo in comment
* src/LaTeXFeatures.C (getPackages):
whitespace

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13950 a592a061-630c-0410-9148-cb99ea01b6c8

lib/layouts/memoir.layout
src/LaTeX.C
src/LaTeXFeatures.C

index 7c1bc9e930ea22a94ff32a9bc918bcd086ca01aa..63abd2cd5ed078c5381efdf966d8a1c08386eca1 100644 (file)
@@ -13,6 +13,7 @@ SecNumDepth        2
 TocDepth           2
 DefaultStyle       Standard
 PageStyle          Headings
+ProvidesMakeidx    1
 
 
 ClassOptions
index 90092a7cf9b782b795053e8542fa4da1094685eb..5837c5d9b3c20a1bd33f9ee7ca1e7d22b74bb9cb 100644 (file)
@@ -269,6 +269,11 @@ int LaTeX::run(TeXErrors & terr)
        // the .aux file is checked for signs of bibtex. Bibtex is then run
        // if needed.
 
+       // memoir (at least) writes an empty *idx file in the first place.
+       // A second latex run is needed.
+       rerun = fs::exists(ChangeExtension(file, ".idx"))
+               && fs::is_empty(ChangeExtension(file, ".idx"));
+
        // run makeindex
        if (head.haschanged(onlyFilename(changeExtension(file, ".idx")))) {
                // no checks for now
@@ -331,7 +336,7 @@ int LaTeX::run(TeXErrors & terr)
 
        // 1.5
        // The inclusion of files generated by external programs like
-       // makeindex or bibtex might have done changes to pagenumbereing,
+       // makeindex or bibtex might have done changes to pagenumbering,
        // etc. And because of this we must run the external programs
        // again to make sure everything is redone correctly.
        // Also there should be no need to run the external programs any
index 347c10a814d209311ec3c660af7ab497b43d5234..2a2b757436df8b0085edeb35f76bebcdfe40d382 100644 (file)
@@ -294,7 +294,7 @@ string const LaTeXFeatures::getPackages() const
 
        // makeidx.sty
        if (isRequired("makeidx")) {
-               if (! tclass.provides(LyXTextClass::makeidx))
+               if (!tclass.provides(LyXTextClass::makeidx))
                        packages << "\\usepackage{makeidx}\n";
                packages << "\\makeindex\n";
        }