Feature: add templates to advanced export

Bug #1086395 reported by joede on 2012-12-04
This bug affects 2 people
Affects Status Importance Assigned to Milestone
UberWriter (moved to github!)

Bug Description

Currently Uberwriter uses its own templates for exporting Markdown. It is important to allow the user the selection of his own templates. IMO there are two possible ways.

(1) build the whole drop-down-list from the list of found templates. So instead of presenting a predefined list ("LaTeX Source", "LaTeX PDF", ...), the whole list is filled with

(2) add a list of templates to the "advanced export" dialog. This list must be based on the selected backend. The naming of the templates must declare the used backend. So if the backend "LaTeX" is selectes, all template files with the pattern latex-*.templ are collected and presented in the dialog.

Each template file should have description file (like latex-*.xml) which include some descriptive text which is shown in the dialog. Additional stuff like variables could be added later. For solution (1) this description file should define the backend too.

Going this way, it is possible to export a document as an article or an report. There is no single PDF layout anymore.

Wolf Vollprecht (w-vollprecht) wrote :

Hi Joede,

thanks for this suggestion. I don't know if you are aware of pandoc templates? That's basically what I intended to do as soon as I have some time.

For example, there could be a LaTeX / PDF Template for a letter. Now, I would like the workflow like this:

User selects template -> a new document gets created with a very special header: YAML-Like markup of the variables for the template, eg:


Name: Peter Wise
Adress 1: Great Street 15
Adress 2: 8845 Frankfurt


and from this the variables are »compiled« and inserted into the pandoc template.

Also I agree, there should be more different templates for different things, as you mentioned. But as much as I would love to do all this, I can't with the limited time I have.

If you already have some templates I would be really happy if you contribute them :) (This goes out to everyone ;)

joede (joerg-desch) wrote :

I would make a difference between templates to create new documents (that is what you are talking about) on one side, and the (IMO missnamed) pandoc templates to specify the layout of the output (I will call them *output template* now).

If you add special markup to the document, you must also add something like *output classes*. These classes must reduce the list of possible *output templates*. So you have to add the supported classes to the *output templates* too. This would go one step further than my approach.

If you create a letter or slide from a *uberwriter template*, than the advanced export show only backends or *output templates* which are valid for letters or slides.

The pandoc template is only the sleeve for the layout. It doesn't hold the meta data like the *output classes* or the supported (excpected) variables.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers