Re: Glossario con riferimenti sbagliati alle pagine

#44509
Up
0
Down
::


Eccolo qua:

`
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%% %%%%
%%%% Ciambelli Davide [ lopinsjk@gmail.com ] %%%%
%%%% Tesi di Laurea Specialistica %%%%
%%%% Maggio 2010 %%%%
%%%% %%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%************************************************************
% documento
\documentclass[pdftex,11pt,a4paper,oneside]{book}
\usepackage[pdftex]{graphicx}
\DeclareGraphicsExtensions{.pdf,.png,.jpg,.mps}
\RequirePackage[hyperindex]{hyperref}
%\usepackage{thumbpdf}
%************************************************************
% ottenere logo università sulla sfondo
\newcommand\ACP[1]{
\AddToShipoutPicture*{\AtPageCenter{
\makebox(90,10){
\raisebox{.15\textheight}
{\includegraphics[width=1.38\textwidth]{#1}}}}}}
%************************************************************
% package
\usepackage{glossary}
\usepackage[utf8]{inputenc}
\usepackage[italian,english]{babel}
\usepackage{eso-pic}
\usepackage[bf]{caption} % crea le caption in bold
\usepackage{graphicx}
\usepackage{fancyhdr}
\usepackage{listings}
\addto\captionsitalian{%
\renewcommand{\lstlistingname}{Sorgente}}
\addto\captionsitalian{%
\renewcommand{\lstlistlistingname}{Elenco dei sorgenti}}
\lstset {
showstringspaces=false,
showspaces=false,
numbers=left,
numberstyle=\scriptsize,
stepnumber=1,
numbersep=5pt,
framexleftmargin=5mm,
frame=trBR,
frameround=fttt,
mathescape=false,
fontadjust=true,
breaklines=true,
breakatwhitespace=true,
breakautoindent
}
%************************************************************
%tabelle
\usepackage{booktabs}
%************************************************************
%definizione ambiente abstract
\newcommand{\fncyblank}{\fancyhf{}}
\newenvironment{abstract}
{\cleardoublepage \fncyblank \null \vfill
\begin{center}
\bfseries \abstractname
\end{center}}{\vfill \null}
%************************************************************
% interlinea: se 1.3 allora interlinea 1.5, se 1.6 interlinea 2
\linespread{1.5}
%************************************************************
% piccole variazioni ai bordi della pagina e alla larghezza del testo
\addtolength{\hoffset}{-0.5cm}
\addtolength{\textwidth}{1cm}
\addtolength{\evensidemargin}{-1.2cm}
\addtolength{\oddsidemargin}{1.2cm}
\footskip=37pt
%************************************************************
%subsubsubsection
\setcounter{secnumdepth}{4}
\setcounter{tocdepth}{4}
\makeatletter
\renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
{-3.25ex \@plus-1ex \@minus-.2ex}%
{.5ex \@plus.1ex}%
{\normalfont\normalsize\bfseries}}
\makeatother
%************************************************************
%glossario
\makeglossary
\renewcommand{\glossaryname}{Glossario}
%************************************************************
%inizio documento
\begin{document}
\include{frontespizio}
\include{dedica}
\include{costruire}
\include{sommario_ita}
\include{sommario_eng}
%************************************************************
% indice generale
\pagestyle{fancy}
\renewcommand{\chaptermark}[1]{\markright{\thechapter.\ #1}{}}
\renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}{}}
\fancyfoot[LE,RO]{\bfseries\thepage}
\fancyhead[LE]{\bfseries\leftmark}
\fancyhead[RO]{\bfseries\rightmark}
\renewcommand{\headrulewidth}{0.5pt}
\renewcommand{\footrulewidth}{0.5pt}
\addtolength{\headheight}{0.5pt}
\fancypagestyle{plain}{
\fancyhead{} % ignora, nello stile plain, le intestazioni
\renewcommand{\headrulewidth}{0pt} % e la linea
}

\pagenumbering{alph}% prevent duplicate page link names if using PDF
\selectlanguage{italian}
\pagenumbering{roman}
\tableofcontents
\clearpage{\pagestyle{empty}\cleardoublepage}
%************************************************************
% indice figure
\selectlanguage{italian}
\listoffigures
%\addcontentsline{toc}{chapter}{\listfigurename}
%************************************************************
% indice tabelle
\selectlanguage{italian}
\listoftables
%\addcontentsline{toc}{chapter}{\listtablename}
%************************************************************
% indice codici
\selectlanguage{italian}
\lstlistoflistings
%************************************************************
% capitoli tesi
\selectlanguage{italian}
\mainmatter
\include{capitolo1}
\include{capitolo2}
\include{capitolo3}
\include{capitolo4}
\include{capitolo5}
%************************************************************
% appendici, bibliografia e grazie
\include{appendix}
\include{glossario}
\include{bibliografia}
\include{grazie}
%************************************************************
\end{document}
`

e questo è il glossario:

`
\clearpage{
\pagestyle{empty}
\cleardoublepage}
\addcontentsline{toc}{chapter}{Glossario}
\phantomsection
\printglossary
`

questo è uno dei due sommari:

`
\begin{titlepage}
\pagestyle{empty}
\selectlanguage{italian}
\begin{abstract}
Bla bla bla
\end{abstract}
\clearpage{\pagestyle{empty}\cleardoublepage}
\end{titlepage}
`

Saluti

Go to top