Document Classes ⇒ problem with natbib
problem with natbib
I am using natbib package for bibliography. Could anyone please tell me how to change the font size and position of bibliography title from the default. I am using book class as default one.
I set default chapter title as 14pt garamond font, ragged right.
but in bibliography it shows 18pt normal font.
Is there any option to modify this...
many thanks
gopal
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
- Stefan Kottwitz
- Site Admin
- Posts: 10324
- Joined: Mon Mar 10, 2008 9:44 pm
problem with natbib
see natbib documentation 2.12 Other Formatting Options. There it's described how you can change the heading (\bibsection). If you still have questions just tell us.
Stefan
Re: problem with natbib
Thanks for your kind reply. I already tried that option with titlesec package as follows
\renewcommand{\bibsection}{%
\titleformat{\chapter} {\normalfont\large\filcenter\bfseries}{}{}{}
\titlespacing*{\chapter} {0pt}{60pt}{18pt}
\chapter*{ \bibname \markboth{\bibname}{\bibname}%
\addcontentsline{toc}{chapter}{\bibname}} }
But it does not work. Is there any other way to modify this....
I have another problem with package titlesec. When i use long section title, it becomes hyphenated. How could I avoid those hyphens in my title...
Thanks
gopal
- Stefan Kottwitz
- Site Admin
- Posts: 10324
- Joined: Mon Mar 10, 2008 9:44 pm
problem with natbib
that should work. When I tried your code and even wrote \tiny instead of \large then the bibliography heading becomes very small. One short working example:
Code: Select all
\documentclass[a4paper,10pt]{book}\usepackage[T1]{fontenc}\usepackage[urw-garamond]{mathdesign}\usepackage{natbib}\usepackage{titlesec}\renewcommand{\bibsection}{%\titleformat{\chapter} {\normalfont\tiny\filcenter\bfseries}{}{}{}\titlespacing*{\chapter} {0pt}{60pt}{18pt}\chapter*{ \bibname \markboth{\bibname}{\bibname}%\addcontentsline{toc}{chapter}{\bibname}} }\begin{document}\begin{thebibliography}{99}\bibitem{test} test\end{thebibliography}\end{document}
Stefan
Re: problem with natbib
I also tried that option. But it did not work. so I attached my class file here with.
Thanks for your help.
Gopal
- Attachments
-
- rosePhDthesis.cls
- (16.54 KiB) Downloaded 415 times
-
- Posts: 1
- Joined: Wed Sep 10, 2008 4:49 pm
Re: problem with natbib
There is quite a good guide to natbib here: http://www.mps.mpg.de/software/latex/lo ... natbib.pdf
- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
problem with natbib
This is the official user guide of natbib which can also be found on CTAN.alexbowers wrote:[...] There is quite a good guide to natbib here: http://www.mps.mpg.de/software/latex/lo ... natbib.pdf
Best regards
Thorsten¹
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10