# Tag Info

16

egreg answered the specific issue but the general issue of avoiding package loading as mentioned in comments: \documentclass{article} \ProvidesFile{longtable.sty} \usepackage{longtable} \typeout{longtable is: \meaning\longtable} \stop produces longtable is: undefined showing that the package is not loaded, despite the \usepackage.

10

I don't see any way of configuring the current version of latexmk to prevent it doing the extra runs. Not only is makeindex run a second time by latexmk, but so is latex, so the run time is doubled, which is a bad penalty on a large document. To correct this needs changes in latexmk itself. There is enough information in the .log file for latexmk to ...

8

The page range formation is disabled via a command line option, rather than an instruction in the .ist file. So the solution is to call makeindex with the -r option; with imakeidx this can be specified in the value for the option key; the simplest call would be \makeindex[options= -r] if no other setting for the (main) index is needed. In your case, ...

6


6

Normally the argument of \index is read verbatim, but ams alignments act like command arguments and defeat verbatim so the argument is read as command tokens and the entry expands to \indexentry{$\mu ^{\otimes \delimiter "3223379 n}$}{1} which messes up the index. You could use \index{$\mu^{\otimes\protect\downarrow n}$} which would work, but produces ...

5

For makeindex the symbol ! has a specific meaning. The manual of makeindex (texdoc makeindex) has the following example / explanation: To produce a subentry, the argument of the \index command should contain both the main entry and the subentry, separated by a ! character. Page 7: \index{gnat!size of} || gnat, 32 Page 32: \index{gnat} ...

5

Load imakeidx before hyperref. Generally, hyperref should be loaded last, though there are some exceptions (see Which packages should be loaded after hyperref instead of before? ).

5

imakeidx sets the number of columns with \imki@columns; so you can simply build another document with the following format: \documentclass{article} \usepackage{imakeidx} \usepackage{hyperref} \begin{document} \makeatletter \def\imki@columns{1} \def\indexname{External index} \makeatother \input{mainfile.ind} \end{document} leaving to the class the rest.

5

For getting the colon you need to define a new MakeIndex style; it's really simple: just prepare the following 31083.ist file in the same folder as your main document, with the single line delim_0 ": " because delim_0 is the container of the tokens inserted between an index entry and the first page number (if any). Then you have to instruct imakeidx to ...

5

One can modify the index formatting with \indexsetup, that takes as argument a list of key-value pairs; in your case the key is othercode: \indexsetup{othercode=\small} The code given as value to the key is inserted just before the index body is typeset, so this doesn't influence the header. Note, however, that the effect is global and will affect all ...

5

The solution is to move \nobreak after \@idxitem: % arara: lualatex % arara: makeindex % arara: lualatex \documentclass{article} \usepackage{makeidx} \makeatletter % we don't want a page break before a subitem \renewcommand\subitem{\@idxitem\nobreak\hspace*{20\p@}} \makeatother \makeindex \begin{document} \index{gap!radial}\index{gap!axial} ...

5

You have to call imakeidx with the nonewpage option and run makeindex manually. Unfortunately, there's also the need to apply a patch around a bug that should be solved in the next release of imakeidx; see Why does imakeidx + nonewpage fail to write an idx file? In order to automate the work you have two roads: Use latexmk Use arara I'd prefer the ...

4

Quick solution Here is a shorter solution, it struggles with the issue that it writes the first occurence text to the glossary. \defglsdisplayfirst[\acronymtype]{#1#4\index{#1}} It redefines the first display of the term to include a call to index using the \defglsdisplayfirst command and restricts this change to the acronym glossary. Right now the ...

4

Not to take away anything from John's answer, adding \$makeindex = "touch -m %D"; to the local .latexmkrc produces automated workflow with nearly minimal overhead. In which case, on my system with this example, latex is only run once. I.e., this is (nearly) as efficient as things can ever get. The proviso, of course, is that imakeidx with \write18 enabled is ...

4

The imakeidx package must be loaded before hyperref. \documentclass{scrbook} \usepackage{imakeidx} \usepackage{classicthesis} \usepackage{cleveref} \makeindex \begin{document} Since hyperref is loaded by classicthesis this is the correct order.

4

Here is a possible solution. I show it with sections, it should be easy to adapt to your setting. (1) I define a counter and step it each time a new section is started with the \Section command, which defines a unique command holding the section's title and whose name depends on the value of the counter. (2) I get copies of the relevant indexing commands ...

3

While it is possible to reduce the index fontsize using only imakeidx, the space between index heading and first entry will be somewhat larger than that produced by a fontsize switch after a "normal" heading. If you use idxlayout, the spacing will be the same. The following MWE contains both variants; comment/uncomment the respective lines and compare. ...

3

Here's a way: \documentclass[10pt,% % corpo del font principale a4paper,% % carta A4 % draft,% % evidenzia le righe Overfull hbox twoside,% % oneside,% openright,% % fronte-retro % openany% ...

3

Add to your .ist file the line symhead_positive "Símbolos" to change The Name "Symbols" in your index to that you want. With MakeIndex you will need to use \index{algebra@álgebra} for a better sorting. How to install Xindy with MiKTeX please have a look to question How to use Xindy with MiKTeX.

3

I'm afraid it's a bug in imakeidx which calls for closing the idx file too early even if noautomatic (implied by nonewpage) is in force. For the moment you can give the correct definition to \imki@putindex: \documentclass{article} \usepackage[nonewpage]{imakeidx} \makeatletter \def\imki@putindex#1{% \ifimki@nonewpage\else \imki@clearpage %%% The ...

2

There should be a solution with indexstyle, but the manual is rather cryptic on the subject. \documentclass{article} \usepackage[dvipsnames]{xcolor} \usepackage{listings} \usepackage{imakeidx} \makeindex \lstdefinelanguage{minion}{ % define the "minion language", known for its semantic complexity morekeywords={bello,banana} % keywords for the "minion ...

2

Generally the indexed words do not necessarily appear in the text at all (for example there can be a fox in the text and an \index{animals} next to it). Therefore I'm not sure whether I understand your question right. \documentclass{article} \usepackage{makeidx} \makeindex \usepackage{hyperref} \begin{document} ...

2


1

Here is my final implementation of @egreg's answer. It uses \thepage in spite of his idea to use a counter. The reason for that is that I want to generate hyperlinks in the index, which is not possible if I don't know the page to link to, and I don't want to play with hundreds of dynamic labels. All in all, this works and I'm happy with it: ...

1

Silly me; I was looking for the answer in the wrong place and just answered my own question. Answer Use the splitindex option, eg. \RequirePackage[splitindex]{imakeidx} imakeidx provides the splitindex option which (as you might expect) allows all index entries to be written to a single file, then split out by the splitindex script. This means that ...

1

The command \hfil is not working. Please try this ist file: delim_0 "\\dotfill" delim_1 "\\hfill" delim_2 "\\hfill" \dotfill (for better reading fills the line with dots, \hfill has no dots, but the numer is right justified. Result:

1

Since this is probably impossible; I've modified my example to look something like this which works for my use case (even if it isn't quite the same): \documentclass{article} \usepackage[splitindex]{imakeidx} \makeindex[name=anidx] \def\arobustcmd{Some text} \def\anotherrobustcmd{some text} \newcommand*{\setthetext}[1]{% ...

Only top voted, non community-wiki answers of a minimum length are eligible