Page LayoutBibliography page layout

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
vortex3
Posts: 12
Joined: Mon Jan 12, 2009 1:53 am

Bibliography page layout

Post by vortex3 »

Hello everyone,

I need to change the page loyout of the bibliography. I need to put the page number in the upper right corner, insted of the bottle center.

I'm using the bibtex packet.

I try to use the \thispagestyle{}, but it didn't work.

This is what it did:

\thispagestyle{titulos}
\begin{singlespace}
\bibliographystyle{unsrt}
\bibliography{./Bibliografia/Referencias}
\end{singlespace}


I put the \thispagestyle{} command in other lines too, but didn't work.

Anyone knows how to do this?

Thank you very much

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Bibliography page layout

Post by gmedina »

Hi,

you can redefine the thebibliography environment as defined in the document class that you are using; the following code shows how to do this when using article to use empty as the page style:

Code: Select all

\makeatletter
\renewenvironment{thebibliography}[1]
     {\section*{\refname}%
      \thispagestyle{empty}% change the style to suit to your needs
      \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
      \list{\@biblabel{\@arabic\c@enumiv}}%
           {\settowidth\labelwidth{\@biblabel{#1}}%
            \leftmargin\labelwidth
            \advance\leftmargin\labelsep
            \@openbib@code
            \usecounter{enumiv}%
            \let\p@enumiv\@empty
            \renewcommand\theenumiv{\@arabic\c@enumiv}}%
      \sloppy
      \clubpenalty4000
      \@clubpenalty \clubpenalty
      \widowpenalty4000%
      \sfcode`\.\@m}
     {\def\@noitemerr
       {\@latex@warning{Empty `thebibliography' environment}}%
      \endlist}
\makeatother
If your document class in not article, of course, you will have to redefine the
corresponding thebibliography environment.
1,1,2,3,5,8,13,21,34,55,89,144,233,...
BMAcox
Posts: 40
Joined: Sun Dec 23, 2007 12:07 am

Re: Bibliography page layout

Post by BMAcox »

Hello:

I need to change my bib layout in a different way. The default indentation of the bibliography is too far to the right. How can we shift it to the left a bit? The syntax that I use to output my latex file from TeXnicCenter to .pdf was

\begin{thebibliography}{breitestes 1}
\bibitem{}...
.
.
.
\end{thebibliography}

ThanQ!
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Bibliography page layout

Post by localghost »

BMAcox wrote:[…] I need to change my bib layout in a different way. The default indentation of the bibliography is too far to the right. How can we shift it to the left a bit? […]
Learn more about the thebibliography environment to get its appearance right.


Best regards
Thorsten
BMAcox
Posts: 40
Joined: Sun Dec 23, 2007 12:07 am

Re: Bibliography page layout

Post by BMAcox »

I went the doc per the link. But it doesn't say anything about the natural indentation of \bibliography ... ???
User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Bibliography page layout

Post by gmedina »

Hi,

the \thebibliogrpahy environment uses a LaTeX list, so the list parameters can be used to change, for example, the bibitems indentation.
1,1,2,3,5,8,13,21,34,55,89,144,233,...
BMAcox
Posts: 40
Joined: Sun Dec 23, 2007 12:07 am

Bibliography page layout

Post by BMAcox »

gmedina wrote:Hi,

the \thebibliogrpahy environment uses a LaTeX list, so the list parameters can be used to change, for example, the bibitems indentation.
Ok, can you post a sample code for this. I don't see it in the documentation (unless there is another one from the previous post) of how to change the indentation... Would like to save page space. ThX! :geek:
User avatar
gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

Bibliography page layout

Post by gmedina »

BMAcox wrote:...Ok, can you post a sample code for this...
Of course. Here's an example, using article as document class:

Code: Select all

\documentclass{article}
\usepackage{lipsum}% just to automatically generate some text

\makeatletter
\renewenvironment{thebibliography}[1]
     {\section*{\refname}%
      \thispagestyle{plain}%
      \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
      \list{\@biblabel{\@arabic\c@enumiv}}%
           {\settowidth\labelwidth{\@biblabel{#1}}% 
            \setlength\itemindent{10pt}% modified
            \setlength\leftmargin{0pt}% modified 
            \setlength\labelsep{10pt}% modified 
            \advance\leftmargin-30pt% modified
            \@openbib@code
            \usecounter{enumiv}%
            \let\p@enumiv\@empty
            \renewcommand\theenumiv{\@arabic\c@enumiv}}%
      \sloppy
      \clubpenalty4000
      \@clubpenalty \clubpenalty
      \widowpenalty4000%
      \sfcode`\.\@m}
     {\def\@noitemerr
       {\@latex@warning{Empty `thebibliography' environment}}%
      \endlist}
\makeatother

\begin{document}

\lipsum[1]

\begin{thebibliography}{9}
  \bibitem{one} \lipsum[1]
  \bibitem{two} \lipsum[1]
\end{thebibliography}

\end{document}
The changes made to the thebibliography environment are marked with % modified. Use the length commands (and change their value) according to your needs.

Here's the original definition of the environment as given in the file article.cls:

Code: Select all

\newenvironment{thebibliography}[1]
     {\section*{\refname}%
      \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
      \list{\@biblabel{\@arabic\c@enumiv}}%
           {\settowidth\labelwidth{\@biblabel{#1}}%
            \leftmargin\labelwidth
            \advance\leftmargin\labelsep
            \@openbib@code
            \usecounter{enumiv}%
            \let\p@enumiv\@empty
            \renewcommand\theenumiv{\@arabic\c@enumiv}}%
      \sloppy
      \clubpenalty4000
      \@clubpenalty \clubpenalty
      \widowpenalty4000%
      \sfcode`\.\@m}
     {\def\@noitemerr
       {\@latex@warning{Empty `thebibliography' environment}}%
      \endlist}
1,1,2,3,5,8,13,21,34,55,89,144,233,...
BMAcox
Posts: 40
Joined: Sun Dec 23, 2007 12:07 am

Re: Bibliography page layout

Post by BMAcox »

tried it, perfect! thankq! does anyone know how to remove from our output files directory pathname engraved ontop of our figures? :oops:
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Bibliography page layout

Post by localghost »

BMAcox wrote:[...] does anyone know how to remove from our output files directory pathname engraved ontop of our figures? [...]
Please don't mix several topics in one thread. Regarding your problem you should avoid any special characters (blank spaces, underscores, ...) in the name and the path of the file. As an alternative you can try the grffile package from the oberdiek bundle.
Post Reply