From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Hendy Subject: Re: Custom title page in org-mode Date: Wed, 21 Dec 2011 16:23:20 -0600 Message-ID: References: <8088.1324505746@alphaville.americas.hpqcorp.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=000e0ce005fe92d56304b4a1a167 Return-path: Received: from eggs.gnu.org ([140.186.70.92]:43914) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RdUZI-0002QN-Su for Emacs-orgmode@gnu.org; Wed, 21 Dec 2011 17:23:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RdUZH-0002jV-A8 for Emacs-orgmode@gnu.org; Wed, 21 Dec 2011 17:23:24 -0500 Received: from mail-ey0-f169.google.com ([209.85.215.169]:61181) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RdUZG-0002jC-Ul for Emacs-orgmode@gnu.org; Wed, 21 Dec 2011 17:23:23 -0500 Received: by eabm6 with SMTP id m6so6778112eab.0 for ; Wed, 21 Dec 2011 14:23:21 -0800 (PST) In-Reply-To: <8088.1324505746@alphaville.americas.hpqcorp.net> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: nicholas.dokos@hp.com Cc: Emacs-orgmode@gnu.org, Steve Prud'Homme --000e0ce005fe92d56304b4a1a167 Content-Type: text/plain; charset=UTF-8 On Wed, Dec 21, 2011 at 4:15 PM, Nick Dokos wrote: > Steve Prud'Homme wrote: > > > Ok so i use emacs for school work. > > I was trying to make a custom title page because, the default latex > > custom page do not respect my teacher standard > > > > So my org-file look like that : > > [...] > If I were you, what I would do is make my own LaTeX class. Start from > the one closest to the desired result (probably article), incorporate > whatever changes you want from report.cls (in particular, the page > breaks you want), make whatever changes you want to the \title, \author > etc. macros, save the result as myarticle.cls in the same directory as > your org file, and add an entry for it to org-export-latex-classes. Then > add a > > #+LaTeX_CLASS: myarticle > > [...] > That's all that's needed to produce separate title and TOC pages and > keep the rest of the article class intact. If you don't like the > titlepage format, you can modify it to your heart's content: you will > need to figure out the LaTeX part to do that, but that's not as > difficult as you might think it is at first sight - and I guarantee that > you will have an easier time this way than fighting the org latex > exporter, a fight that you will probably lose :-) IMO, of course. > > I just did this and took a different method. I simply added: --- #+text: \input{./title.tex} --- to the beginning of my document. Then I created a separate .tex file with the title. If something is recurring, maybe it's worth the separate article class file. If not, I think it *might* be simpler to just define a custom title page and do as above. I think I just followed this: http://en.wikibooks.org/wiki/LaTeX/Title_Creation#Custom_Title_Pages Up to you! I can't guarantee this is right; I'm on a work computer and did this on my home one. John > Nick > > Footnotes: > > [fn:1] Bastien is right that redefining \baselinestretch is better than > mucking around with the \baselineskip as I suggested (see > e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=linespace ) > > It's probably even better to do it like this however: > > --8<---------------cut here---------------start------------->8--- > #+LaTeX_HEADER: \usepackage{setspace}\doublespacing > --8<---------------cut here---------------end--------------->8--- > > or > > --8<---------------cut here---------------start------------->8--- > #+LaTeX_HEADER: \usepackage{setspace}\onehalfspacing > --8<---------------cut here---------------end--------------->8--- > > or if you don't like the built-in factors, choose your own: > > --8<---------------cut here---------------start------------->8--- > #+LaTeX_HEADER: \usepackage{setspace}\setstretch{1.3} > --8<---------------cut here---------------end--------------->8--- > > BTW, I think the factors are logarithmic: doublespacing is about 1.66 > and onehalfspacing is 1.25 or so (depending on the font size). > > --000e0ce005fe92d56304b4a1a167 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On Wed, Dec 21, 2011 at 4:15 PM, Nick Dokos <nicholas.dokos@h= p.com> wrote:
Steve Prud'Homme <sprudhom@gma= il.com> wrote:

> Ok so i use emacs for school work.
> I was trying to make a custom title page because, the default latex > custom page do not respect my teacher standard
>
> So my org-file look like that :


[...]
=C2=A0
If I were you, what I would do is make my own LaTeX class. Start from
the one closest to the desired result (probably article), incorporate
whatever changes you want from report.cls (in particular, the page
breaks you want), make whatever changes you want to the \title, \author
etc. =C2=A0macros, save the result as myarticle.cls in the same directory a= s
your org file, and add an entry for it to org-export-latex-classes. Then add a

#+LaTeX_CLASS: myarticle


[...]
=C2=A0
That's all that's needed to produce separate title and TOC pages an= d
keep the rest of the article class intact. If you don't like the
titlepage format, you can modify it to your heart's content: you will need to figure out the LaTeX part to do that, but that's not as
difficult as you might think it is at first sight - and I guarantee that you will have an easier time this way than fighting the org latex
exporter, a fight that you will probably lose :-) IMO, of course.


I just did this and took a different m= ethod. I simply added:

---
#+text:=C2=A0<= span class=3D"sy0" style=3D"background-color:rgb(255,255,255)">\input{./ti= tle.tex}
---

to the beginning of my document. Then I= created a separate .tex file with the title. If something is recurring, ma= ybe it's worth the separate article class file. If not, I think it *mig= ht* be simpler to just define a custom title page and do as above. I think = I just followed this:=C2=A0http://en.wikibooks.org/wiki/LaTeX/= Title_Creation#Custom_Title_Pages

Up to you! I can't guarantee this is right; I'm= on a work computer and did this on my home one.

<= br>
John



= =C2=A0
Nick

Footnotes:

[fn:1] Bastien is right that redefining \baselinestretch is better than
mucking around with the \baselineskip as I suggested (see
e.g. http://www.tex.ac.uk/cgi-bin/texfaq2html?label=3Dlinespa= ce )

It's probably even better to do it like this however:

--8<---------------cut here---------------start------------->8---
#+LaTeX_HEADER: \usepackage{setspace}\doublespacing
--8<---------------cut here---------------end--------------->8---

or

--8<---------------cut here---------------start------------->8---
#+LaTeX_HEADER: \usepackage{setspace}\onehalfspacing
--8<---------------cut here---------------end--------------->8---

or if you don't like the built-in factors, choose your own:

--8<---------------cut here---------------start------------->8---
#+LaTeX_HEADER: \usepackage{setspace}\setstretch{1.3}
--8<---------------cut here---------------end--------------->8---

BTW, I think the factors are logarithmic: doublespacing is about 1.66
and onehalfspacing is 1.25 or so (depending on the font size).


--000e0ce005fe92d56304b4a1a167--