23 Comments

  1. Timothée

    Cool

    And by the way, thanks for your blog. very useful.

    How do you manage to add LaTeX in your WordPress posts?

  2. Thanks!

    You can only use math-environment Latex:
    dollar latex your-code dollar (just replace dollar by $)
    Similar to what you do in Latex actually, but you need to tell WordPress that you want to use Latex.

    Cheers

  3. $ latex \mathbb{M}\alpha t \hbar \quad \widetilde{\imath} \oint \quad \mathcal{B} e \vec{a} \cup \tau \check{\imath} \Phi \upsilon \pounds $

    Does it work ?

  4. tom

    You just need to omit the space after the dollar sign and it should work.
    No guarantee for the formula:-).

    Cheers,
    Tom

  5. Great blog. Thanks. Here are some more hack that you can do with the pdflatex generation.

    Here is how I poked my pdflatex config file to make the following modifications to my PDF output.

    sudo vim /usr/share/texmf/tex/latex/hyperref/hyperref.cfg
    \hypersetup{backref=false,    # stops linking from endnotes/references to bodytext.
    pdfpagemode=FullScreen,   # automatically display PDF fullscreen on opening
    colorlinks=true,                      # keeps colours
    hyperfootnotes=false,            # stops footnotes in the body linking to base of page
    breaklinks=true}                      #allows hyperlinks to wrap overlines
  6. RnD HW

    thanks… I’ve been looking for this…
    the default colors are too contrast (red and light green)….

  7. Allan

    I am trying to write a scientific paper and i intend to use the hyperref package for coloured links however when i use it,my Url exceeds one colum what can i do to solve this.
    This is my code:

    \usepackage{url}
    \usepackage[colorlinks=true,linkcolor=blue]{hyperref}
    \usepackage{color}
    \hypersetup{
       colorlinks,
       citecolor=blue,
       filecolor=red,
       linkcolor=black,
       urlcolor=blue
    }
    ...
    \begin{thebibliography}{1}
    \bibitem{lamport94}
    \url{http://www.very-long-url.com/long/longer/longest}
    \end{thebibliography}

    My problem is that the url exceed one column of the Latex Paper and enters into other text,how can i solve this?

    • Hi Allan,

      Thanks for your e-mail. I moved your comment to this blog post, since the answer may also help others with the same problem. Hope that’s ok with you.
      Try loading the url package with the hyphens option. Here is an example:

      \documentclass{article}
      \usepackage[hyphens]{url}
      \usepackage{hyperref}
      \begin{document}
      Some random text to fill some more space before the url. \url{http://www.very-long-url.com/long/longer/longest}
      \end{document}

      Hope that helps,
      Tom.

  8. Allan

    \begin{thebibliography}{1}
    \bibitem{lamport94}
     \url{http://dl.dropbox.com/u/55197391/Robot_Arm_Control_By_Katende_Allan_The_Guru.MPG}
    \end{thebibliography}

    thats my code for the bibliography its a long thing,its over the one column and yet am using two columns.

    • Hi Allan,

      Try this:

      \documentclass[11pt, twocolumn]{article}
      \usepackage[hyphens]{url}
      \usepackage{hyperref}
      \begin{document}
      \cite{lamport94}
      \begin{thebibliography}{1}
      \bibitem{lamport94}
      \url{http://dl.dropbox.com/u/55197391/Robot_Arm_Control_By_Katende_Allan_The_Guru.MPG}
      \end{thebibliography}
      \end{document}
      • Allan

        Thats ok,now i need to add a video to my beamer presentation but i am having trouble with media9 and media15

      • Hi Allan,

        Did you try the flashmovie package? See the example included in the package for some sample code. In case you are using Mac OSX, it doesn’t seem to work in Preview, you’d need to switch to Adobe Reader.

        Best, Tom.

      • Allan

        That doesnt seem to work for me lol,i need to understant either media9.sty or media15.sty

  9. Kelly

    Hi,
    I’m able to insert links using \cite{} and \ref{} and generate a pdf with these links working. However I need to insert signatures into my pdf using Adobe Reader (it’s a PhD thesis).
    As soon as I “save as” the pdflatex-generated pdf with the signatures inserted, the next time I open the pdf all of the links do not work.
    Any help would be appreciated.

    • Hi Kelly,

      I assume you mean digital signatures, which frankly speaking I have never used. However, you may find these links informative: here and here.

      Good luck with your thesis!

      Tom.

  10. Preetham A. M.

    Dear Tom,

    First of all thank for your time and effort. I am have trouble in figuring out start page in pdf reader (Adobe or others). I would like to have my pdf start page from the chapter, after pagenumbering{arabic} i.e. pdf page shall start at page number 1.

    Right after:

    \pagenumbering{arabic}
    \setcounter{page}{1}
    

    I did tried \usepackage[pdfstartpage = some number x]{hyperref}. Since the TOC, list of figures and other contents page number can grow, every time I need to change number ‘x’.

    So, I am really looking forward for some auto-mechanism such that provided that line/piece of code and complied, after opened the pdf page (in Adobe reader/Acrobat), it should right away starts from that page.

    Example:

    \documentclass[letterpaper,12pt]{any class}%
    \usepackage{some packages}
    \begin{document}
    %\uniquecode_for_pdfpage_start  % placed at this location
    \chapter{XXXX}
    \section{XYZ}
    \subsection{XX}
    \chapter{XXXX}
    \section{XYZ}
    %\uniquecode_for_pdfpage_start  % or placed at this location
    \subsection{XX}
    \chapter{XXXX}
    \section{XYZ}
    \subsection{XX}
    \end{document}

    Placed in particular location, it shall start on that particular page.

    Further, I have attached my typical example file:

    \documentclass[letterpaper,12pt]{report}%
    \usepackage{amssymb,amsmath}
    \usepackage{blindtext, setspace}
    \usepackage[hidelinks,breaklinks]{hyperref}
    \usepackage{totcount}
    \usepackage{refcount}
    \usepackage[top=0.75in, bottom=1in, left=1.in, right=1.in]{geometry}
    \pagenumbering{roman}
    \cleardoublepage\phantomsection
    \renewcommand{\contentsname}{Contents}
    \pdfbookmark{\contentsname}{toc}
    \setstretch{1.5}
    \begin{document}
    \listoftables
    \listoffigures
    \clearpage
    \pagenumbering{arabic}
    \setcounter{page}{1}
    \chapter{Some name}
    \blindtext
    \section*{Issues/Risks Identified}
    \blindtext
    \chapter{Some name 2}
    \blindtext
    \section*{Issues/Risks Identified}
    \blind text
    \end{document}

    Thank you,

Leave a Reply