From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: pretty export of tags Date: Fri, 4 Jun 2010 13:22:39 +0200 Message-ID: <8F15FF05-47A1-4E53-84C1-450EFE7AB477@gmail.com> References: <87mxvgdsrp.fsf@convex-new.cs.unb.ca> Mime-Version: 1.0 (Apple Message framework v936) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=48008 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OKVNf-000573-R5 for emacs-orgmode@gnu.org; Fri, 04 Jun 2010 07:48:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OKVNa-0007ZA-Lj for emacs-orgmode@gnu.org; Fri, 04 Jun 2010 07:48:07 -0400 Received: from mail-ww0-f41.google.com ([74.125.82.41]:34132) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OKVNa-0007Y9-Gp for emacs-orgmode@gnu.org; Fri, 04 Jun 2010 07:48:02 -0400 Received: by mail-ww0-f41.google.com with SMTP id 24so924015wwb.0 for ; Fri, 04 Jun 2010 04:48:02 -0700 (PDT) In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Scot Becker Cc: emacs-orgmode@gnu.org On May 31, 2010, at 6:28 PM, Scot Becker wrote: > On Mon, May 31, 2010 at 3:56 PM, David Bremner wrote: >> >> I would like some more control over how tags are exported to PDF. I >> tried both latex and docbook based methods, and as far as I can >> tell, in >> both cases the treatment is hard-coded (at least in the docbook >> case it >> does mark them as being different from the headline). Is there some >> existing trick I should know about? I'd like the tags e.g. right >> justified, or on the next line in a box. The HTML treatment is >> almost >> OK. > > David, > > I could have sworn I was looking at the relevant variable this > morning, but I can't find it. (I was looking at > org-export-latex-todo-keyword-markup, but that's of course for TODO > words). It looks to me like tag markup is hard-coded for LaTeX > export, as a simple substitution in the function > 'org-export-latex-keywords-maybe. > > I, too, would be glad to do some tricks on tags for LaTeX output. > Would it add to the complexity too much to expand the capabilities of > org-export-latex-classes, so that in the lines where you define the > header markup for each class, you can also define tag markup? > > So in the following, %s is just the text of the header and %t is a > (comma-separated, for possible use as LaTeX arguements?) tag list: > > '(("mynewclass" > "\\documentclass[11pt, a4paper]{article}" > ("\\section{%s}\n\taglist{%t}" . "\\section*{%s}\n\taglist{%t}") > ("\\subsection{%s}\n\taglist{%t}" . "\\subsection*{%s}\n > \taglist{%t}") > ... and so on. > > The above example would produce LaTeX code like this: > > \section{This is a Title Here} > \taglist{tag1,tag2,tag3} > Section text goes here. > > I would then define \taglist{} in my header as a custom latex command > which does the formatting I want on the tags. Would it not be more consistent if I just make the command for the taglist be specified in a variable, similar to org-export-latex-todo-keyword- markup. This seems the more logical solution to me. You could still use a non- existing command and define it in the header.... > > Presumably I could also add whatever formatting I want around %t ---at > least whatever formatting LaTeX supports. David, you might want to > assure yourself that LaTeX is capable of producing the results you > want. I'm weak on the specifics, but there is some trouble putting > certain kinds of commands in LaTeX header lines. > > It may be that in time, org-export-generic will grow into a tool that > can be made to produce a decent LaTeX exporter, (and might now for > certain well-structured and not-too-demanding kinds of documents), but > I suspect that time quite yet. > > I'd be glad to hear of any other solutions or hacks. > > Scot > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode - Carsten