2

unfortunately I have some issue with the nomenclature. It works fine but I have double interline between each nomenclature. Could you help me please? How to get a normal nomenclature? I attaching the preamble of my article and the nomenclature. Thanks in advance!

\documentclass[10pt,a4paper,titlepage]{book} 
\usepackage[paperwidth=165mm, paperheight=238mm, left=2.5cm,right=2cm,top=2cm,bottom=2cm]{geometry}
\usepackage[utf8]{inputenc}
\usepackage{tabularx}

\newcommand*{\Resize}[2]{\resizebox{#1}{!}{$#2$}}%

\usepackage[english]{babel}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{graphicx}
\usepackage{amssymb}
\usepackage{empheq, nccmath}
%\usepackage{amsmath}
 %  \usepackage[overload]{empheq}

 \usepackage{empheq, nccmath}
\usepackage{amsfonts}
\usepackage{showframe} \usepackage{cases}

\DeclareFontFamily{U}{mathx}{\hyphenchar\font45}
\DeclareFontShape{U}{mathx}{m}{n}{
<-6> mathx5 <6-7> mathx6 <7-8> mathx7
<8-9> mathx8 <9-10> mathx9
<10-12> mathx10 <12-> mathx12
}{}
\DeclareSymbolFont{mathx}{U}{mathx}{m}{n}
\DeclareFontSubstitution{U}{mathx}{m}{n}

\DeclareMathAccent{\widebar}{0}{mathx}{"73}  


\usepackage{subfloat}
\usepackage{subcaption}

\usepackage{adjustbox}
\usepackage{showframe} 

\usepackage{fontspec}

\usepackage{lineno}
%\linenumbers
\renewcommand{\baselinestretch}{1} 
\setlength{\parindent}{4em}

\pagenumbering{arabic}

\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhf{}
\cfoot{\thepage}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{0pt}

%\bibliographystyle{plain}
\renewcommand\thesection{\arabic{section}}
\setcounter{secnumdepth}{5}
\usepackage{epstopdf}

\usepackage{nomencl}
\makenomenclature
\usepackage{cases}

\usepackage{etoolbox}
\renewcommand\nomgroup[1]{%
  \item[\bfseries
  \ifstrequal{#1}{A}{Symbols}{%
  \ifstrequal{#1}{B}{Subscripts}{%
  \ifstrequal{#1}{C}{Superscripts}{%
  \ifstrequal{#1}{D}{Acronyms{}}}}}%
]}

 % This will add the units
%----------------------------------------------
\newcommand{\nomunit}[1]{%
\renewcommand{\nomentryend}{\hspace*{\fill}#1}}
%----------------------------------------------

\begin{document}

\setlength{\baselineskip}{13pt}
\setmainfont{Georgia}

\setcounter{section}{2}
\setcounter{figure}{1}

\printnomenclature[0.75in]

...
...
...
\end{document}

enter image description here

6
  • 1
    Your document uses fontspec so can't be used with pdftex so \usepackage[utf8]{inputenc} should be deleted I couldn't get it to produce the output shown but \setlength{\parindent}{4em} looks suspicious, what happens if you remove that? May 19, 2016 at 15:30
  • 1
    May you add some nomenclature entries to your example code?
    – egreg
    May 19, 2016 at 15:30
  • Hi \setlength{\parindent}{4em} works well, it sets the indent at each new paragraph. I deleted usepackage[utf8]{inputenc} but nothing happens. The example, I do not know why but it looks that it does not work. It works only with the entire document.
    – chrisis
    May 19, 2016 at 15:58
  • 1
    sorry I misread it for \parskip (that's what happens if you don't provide a usable example and rely on people debugging by eyeballing the code:-) If you delete inputenc something will happen: the warning the package gives that it should not be used with xetex will go away. ( May 20, 2016 at 7:07
  • Yes, not it works and the Nomenclature is written well. The problem now how to reduce the font size of the word Nomenclature as the chapter and how to set the word nomenclature on top of the page?
    – chrisis
    May 20, 2016 at 8:29

1 Answer 1

2

The nomencl package sets \itemsep to the value of \nomitemsep (default 4pt plus 2pt minus 1pt), which is added to \parsep (default for book class the same as \nomitemsep.

If you want tight typesetting, set \nomitemsep to the negative of \parsep.

The text below \printnomenclature is meant to compare the two lists.

\documentclass{book}
\usepackage{nomencl}

\setlength{\nomitemsep}{-\parsep}

\begin{document}
some text

\printnomenclature[0.75in]

\nomenclature{Q}{Heat loss/power}
\nomenclature{R}{Heat loss/power}
\nomenclature{S}{Heat loss/power}

\noindent Q Heat loss/power\par
\noindent Q Heat loss/power\par
\noindent Q Heat loss/power\par

\end{document}

enter image description here

2
  • You save my life. It works perfectly. The last thing. I would like to have the name Nomenclature on the top of the page and a bit smaller font. Do you know how to do this?
    – chrisis
    May 19, 2016 at 16:20
  • 1
    @chrisis The same style as for chapters is used
    – egreg
    May 19, 2016 at 16:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .