Cookbook -- no really, a cookbook...

28 views
Skip to first unread message

Crisses

unread,
Mar 14, 2013, 3:41:52 PM3/14/13
to wikipu...@googlegroups.com
Next book project: A cookbook.  Not a pmwiki or wikipublisher cookbook or recipe, but a cookbook for making food done in wikipublisher.  Wondering the best way to format recipes/ingredients/etc.  Also thinking I might not want the usual page formats.

Like both of my other wikipublisher-typeset books, I plan to self-publish via Createspace.  There seems to be many other page size formats at Createspace than in WikiPublisher...

Unfortunately color printing is prohibitively expensive, but I'm considering an e-version with full color pictures.  Then again, food photography is also prohibitive....

Shouldn't we have a "Made with Wikipublisher" page on the website -- for links to (published? distributed?) books actually created with the package?  Just a thought.  I love how my books came out, and people can use the Look Inside... feature at Amazon and check out WikiPublisher's done product...

JR

unread,
Mar 15, 2013, 3:39:24 AM3/15/13
to wikipu...@googlegroups.com
I am aware of one other recipe book produced using Wikipublisher. The most useful tip turned out to be:

(:div class=multicol:)
2 cooking apples, such as ballarat

yeast

cinnamon

etc
(:divend:)

which produces a 2 column list of ingredients in the pdf.

Currently, there are 4 standard book sizes: A5, CH (classic hardback), HU (half US letter) and TP (trade paperback). However, an author can also upload her own sty file to define any page size and page layout she chooses. This is a text file with a sty extension that includes LaTeX commands to redefine *any* of the commands Wikipublisher uses to lay out the book. With a little LaTeX knowledge (OK, sometimes a lot of LaTeX knowledge) she can redefine any layout feature and produce a book to her own specification. There is an example attached to http://www.wikipublisher.org/wiki/PressBooks/Fortress (scroll down to the bottom to see the link to the style file -- the page describes all the features of this particular book design).

It would be useful to explore a way for the wikibook server to generate a book in epub. The wikipublisher wiki plug-in can already produce an html version of the book and it shouldn't be too hard to teach the wikibook server to run calibre in command line mode and return an epub. I expect we will have to tweak the html of the book into something calibre can digest, but how hard can that be? As I understand it, you can give calibre a set of rules to tell it how to interpret your html into something sensibly bookish.

A "Made with Wikipublisher" page is a great idea.

Hope this helps.
JR

Crisses

unread,
Mar 17, 2013, 3:35:34 PM3/17/13
to wikipu...@googlegroups.com


On Friday, March 15, 2013 3:39:24 AM UTC-4, JR wrote:
I am aware of one other recipe book produced using Wikipublisher. The most useful tip turned out to be:

(:div class=multicol:)
2 cooking apples, such as ballarat

yeast

cinnamon

etc
(:divend:)

which produces a 2 column list of ingredients in the pdf.

I tried upgrading: When my wikibook server is working again, maybe this will work....  I'm generating XML but no PDF.  I haven't upgraded in 2 years...
 
Currently, there are 4 standard book sizes: A5, CH (classic hardback), HU (half US letter) and TP (trade paperback). However, an author can also upload her own sty file to define any page size and page layout she chooses. This is a text file with a sty extension that includes LaTeX commands to redefine *any* of the commands Wikipublisher uses to lay out the book. With a little LaTeX knowledge (OK, sometimes a lot of LaTeX knowledge) she can redefine any layout feature and produce a book to her own specification. There is an example attached to http://www.wikipublisher.org/wiki/PressBooks/Fortress (scroll down to the bottom to see the link to the style file -- the page describes all the features of this particular book design).

Will try to figure that out if I decide to do a different size book.  Thanks! 
 
It would be useful to explore a way for the wikibook server to generate a book in epub. The wikipublisher wiki plug-in can already produce an html version of the book and it shouldn't be too hard to teach the wikibook server to run calibre in command line mode and return an epub. I expect we will have to tweak the html of the book into something calibre can digest, but how hard can that be? As I understand it, you can give calibre a set of rules to tell it how to interpret your html into something sensibly bookish.

I have to try the html method on my 2nd book.  I have been distracted (and lazy)...so I haven't gotten around to it. 

 
A "Made with Wikipublisher" page is a great idea.
 
I added something to the Examples page because I couldn't make a whole new page for the sidebar...
 
Hope this helps.

Thanks!  You're ever-helpful :)

JR

unread,
Mar 19, 2013, 5:37:06 PM3/19/13
to wikipu...@googlegroups.com
One other comment: if the recipe book has an index, we may need to do a bit of pdf server tweaking. The 2010 (?) TeXLive introduced an incompatibility between hyperref (which makes links in the pdf clickable) and xindy (which generates the index). I implemented a script that patches the intermediate files, but it is "lightly tested" and currently not included in the wikibook server code. Meanwhile, the work-around is that indexes generate correctly, but page numbers are not clickable (other links are not affected; it runs hyperref with hyperindex=false). It would be good to have a properly-tested fix for this issue.

JR

On Friday, March 15, 2013 8:41:52 AM UTC+13, Crisses wrote:

Crisses

unread,
Mar 20, 2013, 7:20:49 PM3/20/13
to wikipu...@googlegroups.com
I backed out of my wikibook/wikipublisher upgrade, since it broke "stuff".  I'm on some mighty old wikibook/publisher stuff right now.  And I think the server that it's on is old and in need of updates too -- so the TeX is likely to be old, and still work ;)

The reason I remembered to upgrade was because the multicol didn't work.  But I then saw that multicol predated my wikipublisher anyway -- so I have no idea why it doesn't work.

JR

unread,
Mar 22, 2013, 12:38:54 AM3/22/13
to wikipu...@googlegroups.com
To check whether the wikibook pdf server version supports multicolumn output, open wikibook/xml/tblatex.xsl in a text editor. Within the <xsl:template match="group"> ... </xsl:template> block, look for

<xsl:when test="'multicol' = @class">
...
</xsl:when>

If it's there, (:div class=multicol:) should work and produce a 2 column block by default. If it's not there, we can provide code to patch tblatex.xsl, without upgrading the entire server.

JR

On Friday, March 15, 2013 8:41:52 AM UTC+13, Crisses wrote:

Crisses

unread,
Mar 22, 2013, 11:00:58 PM3/22/13
to wikipu...@googlegroups.com


On Friday, March 22, 2013 12:38:54 AM UTC-4, JR wrote:
To check whether the wikibook pdf server version supports multicolumn output, open wikibook/xml/tblatex.xsl in a text editor. Within the <xsl:template match="group"> ... </xsl:template> block, look for

<xsl:when test="'multicol' = @class">
...
</xsl:when>


No, I don't see it.  I'm on wikibook 1.1 beta 11.... 
 
If it's there, (:div class=multicol:) should work and produce a 2 column block by default. If it's not there, we can provide code to patch tblatex.xsl, without upgrading the entire server.
 
Awesome :)   Although I would like to upgrade... not sure what's wrong.

JR

unread,
Mar 23, 2013, 6:02:49 PM3/23/13
to wikipu...@googlegroups.com
The beta 11 version is about 17 releases behind the current pdf server version, so upgrading would be a good idea.

It would be prudent to start by upgrading the version of LaTeX. On Ubuntu or other Debian-based servers:

sudo add-apt-repository ppa:texlive-backports/ppa

sudo apt-get update

sudo apt-get install texlive-full

Note the texlive-full. As the pdf server's capabilities have grown, it has increasingly called on packages beyond those found in texlive-base.My guess is that the server is missing a package. If it's a LaTeX problem, the "debug" button will produce a listing that includes the heart-sinking message "emergency stop" at the point where it fell over.


JR
On Friday, March 15, 2013 8:41:52 AM UTC+13, Crisses wrote:
Reply all
Reply to author
Forward
0 new messages