In one of my indices it really would be nice if searching only matched the top level index entries.

One way would be to make the index entires images, but wondering if there is an easier way? And if this is the only solution, what is the best way to make the text be an image?

For instance in the following, within the index, searching for "byte" should yield on one result, not three.

enter image description here




    % #1 = word to index
    % #2 = index name

    \textcolor{blue}{#1} #2%

%% Defer the binary units until AFTER \begin{document} as per
%% http://tex.stackexchange.com/questions/287579/how-to-overwrite-siunitxs-binary-prefixes

    O{}% #1 = index name
      m% #2 = word to index this under
      m% #3 = indexed term
      m% #4 = symbol

\makeindex[title={Main Index},columns=1,program=texindy]
\makeindex[title={Name Index},columns=1,program=texindy,name=Name]



\AddIndexEntry[Name]{byte}{bit}{symbol: \si{\bit}}

  • 1
    As you imply with your image suggestion, you will almost certainly have to fool the PDF browser to do this. Another way might be to add some "hidden" characters? – Andrew Feb 16 '16 at 11:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.