From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dan Davison Subject: Re: Worg needs some reorganizing Date: Thu, 20 Jan 2011 11:22:57 +0000 Message-ID: References: <4CAD81B0.6090807@manor-farm.org> <87bp6ytacd.fsf_-_@stats.ox.ac.uk> <87fwsubckf.fsf@gnu.org> <87aaj2w5x4.fsf@fastmail.fm> <87d3nyuhkw.fsf@altern.org> <87aaj0kggo.fsf@gmail.com> <87zkr0load.fsf@riotblast.dunsmor.com> <87pqrwipjd.fsf@gmail.com> <87oc7glhef.fsf@riotblast.dunsmor.com> <87hbd8ins8.fsf@gmail.com> <87ipxolgji.fsf@riotblast.dunsmor.com> <87aaj0iiff.fsf@gmail.com> <87r5cbk28p.fsf@riotblast.dunsmor.com> <87fwsrtokh.fsf@gnu.org> <87lj2jouz7.fsf@fastmail.fm> <877he2fvw0.fsf@gnu.org> <87fwsqw8u3.fsf@fastmail.fm> <87d3nufa7a.fsf@gmail.com> <87r5cagi6h.fsf@riotblast.dunsmor.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from [140.186.70.92] (port=50198 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pfsbt-0000wn-PU for emacs-orgmode@gnu.org; Thu, 20 Jan 2011 06:23:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pfsbl-0004xc-Bh for emacs-orgmode@gnu.org; Thu, 20 Jan 2011 06:23:18 -0500 Received: from lo.gmane.org ([80.91.229.12]:42220) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pfsbl-0004xV-1F for emacs-orgmode@gnu.org; Thu, 20 Jan 2011 06:23:17 -0500 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Pfsbh-0003xU-U9 for emacs-orgmode@gnu.org; Thu, 20 Jan 2011 12:23:13 +0100 Received: from 94.196.187.99.threembb.co.uk ([94.196.187.99]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 20 Jan 2011 12:23:13 +0100 Received: from dandavison7 by 94.196.187.99.threembb.co.uk with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 20 Jan 2011 12:23:13 +0100 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: emacs-orgmode@gnu.org Jason Dunsmore writes: > "Eric Schulte" writes: > >> Matt Lundin writes: >> >>> Bastien writes: >>> >>>> Jeff Horn writes: >>>> >>>>> Jason seems to be garnering a lot of votes, but Eric's zenburn >>>>> emulation makes my eyes happy. If Jason wins out, I suppose I could >>>>> always just read Worg in emacs... :D >>>> >>>> Or use Eric zenburn-like css by selecting it as an alternative >>>> stylesheet in Firefox : View -> Page Style -> [select stylesheet]. >>>> >>>> I don't know how to make this choice persistent from Firefox and I >>>> don't know if this feature is available for other browsers, but it >>>> is certainly worth having several stylesheet available. >>> >>> Could we perhaps go ahead and put the new stylesheets on Worg along with >>> alternate stylesheet links in the publishing preamble? That way we could >>> begin to tweak the stylesheets as a community and test them "on the >>> fly." (It would also save Jason the work of having to publish to tmp >>> directories.) Others would then be free to add their own >>> stylesheets---though I suppose that adding alternate stylesheet links >>> will require access to the publishing options on the server. >>> >>> Once we've decided on a default, we could then adjust the preamble >>> accordingly and clean up the alternates. >>> >> >> This sounds like a great approach to me. I'm convinced that there are >> other Org-mode users with much more sophisticated knowledge of CSS who >> may improve our initial efforts in time. >> >> One other alternative that comes to mind--while we're making impositions >> on Jason's kindness :)--is that it would be nice to have an alternate >> version of Worg published side-by-side with the original, only instead >> of publishing each page using org-publish-as-html, it could publish each >> page using only htmlize. That way we could show off how nice Org-mode >> syntax can be when viewed from inside of Emacs, and users could see a >> side-by-side between the plain-text and html versions. I strongly second this. In fact I'll stick my neck out more: Worg is great, but for tutorials on org-mode, HTML export is often the wrong format for obvious reasons (i.e. unless you go to some trouble, it conceals a lot of the org syntax). I'm tempted to suggest that htmlized output should be the default format for many org tutorials on Worg. >> An example of >> this approach done successfully is Dan's Babel example at >> http://www.stats.ox.ac.uk/~davison/software/org-babel/drift.org.html > > That sounds like a good idea. Do you know exactly how to do this? I believe I used this. I'd been meaning to look into adding something like this more formally to Org, but haven't got round to it. **** Htmlize with images Based on https://stat.ethz.ch/pipermail/ess-help/2009-August/005478.html by Vitalie S. #+begin_src emacs-lisp (defun dan/htmlize-buffer-with-org-images () "Convert buffer to html, including embedded images." (interactive) (save-excursion (switch-to-buffer (htmlize-buffer (current-buffer))) (goto-char (point-min)) (while (re-search-forward "file:\\(.+\\)" nil t) (replace-match (concat ""))))) #+end_src Dan > > I added the following to org-publish-project-alist: > > ("worg-htmlize" > :base-directory "~/git/Worg/" > :base-extension "org" > :html-extension "org.html" > :publishing-directory "/var/www/orgmode.org/worg/" > :recursive t > :htmlized-source t > :publishing-function htmlize) > > But when I run: > > (defun publish-worg-htmlize nil > "Publish Worg." > (interactive) > (add-hook 'org-publish-after-export-hook 'worg-fix-symbol-table) > (let ((org-format-latex-signal-error nil) > (org-startup-folded nil)) > (org-publish-project "worg-htmlize"))) > > I get the error "Symbol's function definition is void: publish-htmlize". > I made sure to (require 'htmlize). > > _______________________________________________ > 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