[O] Help exporting to-do list as LaTeX/PDF

2014-10-04 Thread Andreas Yankopolus
I'm running OS X 10.9.5 and Aquamacs 3.0a with LaTeX installed through pkgsrc. 
I regularly use LaTeX through TeXShop. It took a while to get the correct combo 
of packages installed.

Exporting my to-do list via HTML works fine, but I get the following log when 
trying to export via LaTeX/PDF:

*

This is pdfTeX, Version 3.1415926-2.5-1.40.14 (Web2C 2013)
 restricted \write18 enabled.
entering extended mode
(/Users/ayank/Documents/residence/punch list.tex
LaTeX2e 2011/06/27
(/usr/pkg/share/texmf-dist/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/pkg/share/texmf-dist/tex/latex/base/size11.clo))
(/usr/pkg/share/texmf-dist/tex/latex/base/inputenc.sty
(/usr/pkg/share/texmf-dist/tex/latex/base/utf8.def
(/usr/pkg/share/texmf-dist/tex/latex/base/t1enc.dfu)
(/usr/pkg/share/texmf-dist/tex/latex/base/ot1enc.dfu)
(/usr/pkg/share/texmf-dist/tex/latex/base/omsenc.dfu)))
(/usr/pkg/share/texmf-dist/tex/latex/base/fontenc.sty
(/usr/pkg/share/texmf-dist/tex/latex/base/t1enc.def))
(/usr/pkg/share/texmf-dist/tex/latex/base/fixltx2e.sty)
(/usr/pkg/share/texmf-dist/tex/latex/graphics/graphicx.sty
(/usr/pkg/share/texmf-dist/tex/latex/graphics/keyval.sty)
(/usr/pkg/share/texmf-dist/tex/latex/graphics/graphics.sty
(/usr/pkg/share/texmf-dist/tex/latex/graphics/trig.sty)
(/usr/pkg/share/texmf-dist/tex/latex/latexconfig/graphics.cfg)
(/usr/pkg/share/texmf-dist/tex/latex/pdftex-def/pdftex.def
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/infwarerr.sty)
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ltxcmds.sty
(/usr/pkg/share/texmf-dist/tex/latex/tools/longtable.sty)
(/usr/pkg/share/texmf-dist/tex/latex/float/float.sty)
(/usr/pkg/share/texmf-dist/tex/latex/wrapfig/wrapfig.sty)
(/usr/pkg/share/texmf-dist/tex/latex/soul/soul.sty)
(/usr/pkg/share/texmf-dist/tex/latex/base/textcomp.sty
(/usr/pkg/share/texmf-dist/tex/latex/base/ts1enc.def
(/usr/pkg/share/texmf-dist/tex/latex/base/ts1enc.dfu)))
(/usr/pkg/share/texmf-dist/tex/latex/marvosym/marvosym.sty)
(/usr/pkg/share/texmf-dist/tex/latex/wasysym/wasysym.sty)
(/usr/pkg/share/texmf-dist/tex/latex/base/latexsym.sty)
(/usr/pkg/share/texmf-dist/tex/latex/amsfonts/amssymb.sty
(/usr/pkg/share/texmf-dist/tex/latex/amsfonts/amsfonts.sty))
(/usr/pkg/share/texmf-dist/tex/latex/hyperref/hyperref.sty
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ifpdf.sty)
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ifluatex.sty))
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/kvsetkeys.sty
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/etexcmds.sty))
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/pdfescape.sty)
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ifvtex.sty)
(/usr/pkg/share/texmf-dist/tex/generic/ifxetex/ifxetex.sty)
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/hycolor.sty
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/xcolor-patch.sty
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/hopatch.sty)))
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/letltxmacro.sty)
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/kvoptions.sty)
(/usr/pkg/share/texmf-dist/tex/latex/hyperref/pd1enc.def)
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/intcalc.sty)
(/usr/pkg/share/texmf-dist/tex/latex/latexconfig/hyperref.cfg)
(/usr/pkg/share/texmf-dist/tex/latex/url/url.sty)
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/bitset.sty
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/bigintcalc.sty))
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/atbegshi.sty))

Package hyperref Message: Driver (autodetected): hpdftex.

(/usr/pkg/share/texmf-dist/tex/latex/hyperref/hpdftex.def
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/atveryend.sty)
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/rerunfilecheck.sty
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/uniquecounter.sty)))
(/Users/ayank/Documents/residence//punch list.aux)
(/usr/pkg/share/texmf-dist/tex/latex/base/ts1cmr.fd)
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/epstopdf-base.sty
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/grfext.sty
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/kvdefinekeys.sty))
(/usr/pkg/share/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg))
(/usr/pkg/share/texmf-dist/tex/latex/hyperref/nameref.sty
(/usr/pkg/share/texmf-dist/tex/latex/oberdiek/refcount.sty)
(/usr/pkg/share/texmf-dist/tex/generic/oberdiek/gettitlestring.sty))
(/Users/ayank/Documents/residence//punch list.out)
(/Users/ayank/Documents/residence//punch list.out)
(/usr/pkg/share/texmf-dist/tex/latex/wasysym/uwasy.fd)
(/usr/pkg/share/texmf-dist/tex/latex/base/ulasy.fd)
(/usr/pkg/share/texmf-dist/tex/latex/amsfonts/umsa.fd)
(/usr/pkg/share/texmf-dist/tex/latex/amsfonts/umsb.fd)
(/Users/ayank/Documents/residence//punch list.toc) [1{/var/lib/texmf/fonts/map/
pdftex/updmap/pdftex.map}] [2] [3] [4]
(/Users/ayank/Documents/residence//punch list.aux)
kpathsea: Running mktexpk --mfmode / --bdpi 600 --mag 1+0/600 --dpi 600 ecbx1200

kpathsea: Running mktexfmt 

Re: [O] Help exporting to-do list as LaTeX/PDF

2014-10-04 Thread Richard Lawrence
Hi Andreas,

Andreas Yankopolus andr...@yank.to writes:
 ...
 kpathsea: Running mktexpk --mfmode / --bdpi 600 --mag 1+0/600 --dpi 600 
 ecbx1200

 kpathsea: Running mktexfmt mf.base
 mktexpk: Mismatched mode ljfour and resolution 600; ignoring mode.
 mktexpk: Running mf-nowin -progname=mf \mode:=ljfour; mag:=1+0/600; 
 nonstopmode; input ecbx1200
 This is METAFONT, Version 2.718281 (Web2C 2013)

 kpathsea: Running mktexfmt mf.base
 I can't find the base file `mf.base'!

 It took a while to get to this point, and I had to install a number of
 font packages from the pkgsrc tex-* collection. I do have tex-ec-1.0
 and tex-eco-1.3 installed. But it seems like the problem is more with
 metafont, which is completely beyond me.

Yeah, this looks to me like your setup is attempting to load (or build??) a
font as part of the compilation process.  As far as I know, that is not
something that should be required when compiling an Org document
exported to LaTeX with the default options.

What are the values of your

org-latex-default-packages-alist
org-latex-packages-alist
org-latex-pdf-process

variables?  And what does the header of the exported .tex file look
like?

I guess the way to debug this is to remove the packages that are loaded
in the exported .tex file, one at a time, until you discover the one
that is at fault here.  (If it's not some particular package, but
rather TeX/LaTeX itself that's trying to use METAFONT, I think you're in
deeper waters...)

Best,
Richard




Re: [O] Help on org-export-filter-link-functions

2014-10-04 Thread John Kitchin
Daimrod daim...@gmail.com writes:

Why don't you just define how the link should be exported in your link
definition?

for example:
https://github.com/jkitchin/jmax/blob/master/org/org-ref.org#the-links

You can see a link that is defined, with different export formats for
different backends.

I am intrigued by your function! It does not seem to work for all types
of links though, for example I tried on on some file links,
e.g. file:bib.bib, and [[file.bib]], but these fall in the (t data)
case. [[file:bib.bib][bibliography]] on the other hand gets handled and
you can access the element properties. 

I tried a similar approach on a table, but it did not work as I
expected. Apparently the next property change puts you in a table-cell,
rather than the parent table.

I too am wondering if there is a defined way to get to the element
properties within a filter function. For example, in this post
http://kitchingroup.cheme.cmu.edu/blog/2014/09/22/Showing-what-data-went-into-a-code-block-on-export/
I concocted a preprocess scheme to get a list of table names, and then a
filter function to put the names in the export on each table. It would
be much more elegant to get it directly from the table element somehow.




 Hi,

 I've wrote a simple filter to customize how links are exported in
 latex:

 #+BEGIN_SRC
 (defun dmd--latex-bib-link-filter (data backend info)
   Convert a bib link to a citation (e.g. bib:foo93 - \cite{foo93}).
   (let* ((beg (next-property-change 0 data))
  (link (if beg (get-text-property beg :parent data
 (cond ((and link
 (org-export-derived-backend-p backend 'latex)
 (string= (org-element-property :type link) bib))
(format \\cite{%s} (org-element-property :path link)))
   ((and link
 (org-export-derived-backend-p backend 'latex)
 (string= (org-element-property :type link) file)
 (string= (org-element-property :path link) ~/.bib.bib))
(format \\cite{%s} (org-element-property :search-option link)))
   (t data
 #+END_SRC

 And I was wondering whether there is an easier way to retrieve the org
 properties stored in the text properties of DATA.

 Best,

-- 
---
John Kitchin
Professor
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
http://kitchingroup.cheme.cmu.edu



Re: [O] Help exporting to-do list as LaTeX/PDF

2014-10-04 Thread Thomas S. Dye
Aloha Andreas,

Assuming that the file mf.base is present on your system, perhaps you
need to update the kpathsea database after installing some fonts.  On my
system, the commands to do this are texhash or mktexlsr.

hth,
Tom


Andreas Yankopolus andr...@yank.to writes:

 I'm running OS X 10.9.5 and Aquamacs 3.0a with LaTeX installed through
 pkgsrc. I regularly use LaTeX through TeXShop. It took a while to get
 the correct combo of packages installed.

 Exporting my to-do list via HTML works fine, but I get the following
 log when trying to export via LaTeX/PDF:

 *

 This is pdfTeX, Version 3.1415926-2.5-1.40.14 (Web2C 2013)
  restricted \write18 enabled.
 entering extended mode
 (/Users/ayank/Documents/residence/punch list.tex
 LaTeX2e 2011/06/27
 (/usr/pkg/share/texmf-dist/tex/latex/base/article.cls
 Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
 (/usr/pkg/share/texmf-dist/tex/latex/base/size11.clo))
 (/usr/pkg/share/texmf-dist/tex/latex/base/inputenc.sty
 (/usr/pkg/share/texmf-dist/tex/latex/base/utf8.def
 (/usr/pkg/share/texmf-dist/tex/latex/base/t1enc.dfu)
 (/usr/pkg/share/texmf-dist/tex/latex/base/ot1enc.dfu)
 (/usr/pkg/share/texmf-dist/tex/latex/base/omsenc.dfu)))
 (/usr/pkg/share/texmf-dist/tex/latex/base/fontenc.sty
 (/usr/pkg/share/texmf-dist/tex/latex/base/t1enc.def))
 (/usr/pkg/share/texmf-dist/tex/latex/base/fixltx2e.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/graphics/graphicx.sty
 (/usr/pkg/share/texmf-dist/tex/latex/graphics/keyval.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/graphics/graphics.sty
 (/usr/pkg/share/texmf-dist/tex/latex/graphics/trig.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/latexconfig/graphics.cfg)
 (/usr/pkg/share/texmf-dist/tex/latex/pdftex-def/pdftex.def
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/infwarerr.sty)
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ltxcmds.sty
 (/usr/pkg/share/texmf-dist/tex/latex/tools/longtable.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/float/float.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/wrapfig/wrapfig.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/soul/soul.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/base/textcomp.sty
 (/usr/pkg/share/texmf-dist/tex/latex/base/ts1enc.def
 (/usr/pkg/share/texmf-dist/tex/latex/base/ts1enc.dfu)))
 (/usr/pkg/share/texmf-dist/tex/latex/marvosym/marvosym.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/wasysym/wasysym.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/base/latexsym.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/amsfonts/amssymb.sty
 (/usr/pkg/share/texmf-dist/tex/latex/amsfonts/amsfonts.sty))
 (/usr/pkg/share/texmf-dist/tex/latex/hyperref/hyperref.sty
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ifpdf.sty)
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/pdftexcmds.sty
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ifluatex.sty))
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/kvsetkeys.sty
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/etexcmds.sty))
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/pdfescape.sty)
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/ifvtex.sty)
 (/usr/pkg/share/texmf-dist/tex/generic/ifxetex/ifxetex.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/hycolor.sty
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/xcolor-patch.sty
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/hopatch.sty)))
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/letltxmacro.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/kvoptions.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/hyperref/pd1enc.def)
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/intcalc.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/latexconfig/hyperref.cfg)
 (/usr/pkg/share/texmf-dist/tex/latex/url/url.sty)
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/bitset.sty
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/bigintcalc.sty))
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/atbegshi.sty))

 Package hyperref Message: Driver (autodetected): hpdftex.

 (/usr/pkg/share/texmf-dist/tex/latex/hyperref/hpdftex.def
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/atveryend.sty)
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/rerunfilecheck.sty
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/uniquecounter.sty)))
 (/Users/ayank/Documents/residence//punch list.aux)
 (/usr/pkg/share/texmf-dist/tex/latex/base/ts1cmr.fd)
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/epstopdf-base.sty
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/grfext.sty
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/kvdefinekeys.sty))
 (/usr/pkg/share/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg))
 (/usr/pkg/share/texmf-dist/tex/latex/hyperref/nameref.sty
 (/usr/pkg/share/texmf-dist/tex/latex/oberdiek/refcount.sty)
 (/usr/pkg/share/texmf-dist/tex/generic/oberdiek/gettitlestring.sty))
 (/Users/ayank/Documents/residence//punch list.out)
 (/Users/ayank/Documents/residence//punch list.out)
 (/usr/pkg/share/texmf-dist/tex/latex/wasysym/uwasy.fd)
 (/usr/pkg/share/texmf-dist/tex/latex/base/ulasy.fd)
 

Re: [O] Babel evaluation of Calc block not working, bug in Calc?

2014-10-04 Thread H. Dieter Wilhelm
Hello Andrea 8-)

Andrea Rossetti andrea.rosse...@gmail.com writes:
 Andrea Rossetti andrea.rosse...@gmail.com writes:
 3) temporary workaround: try to change :var v=3 into :var var-v=3,
 it works for me, does it work for you too?
 The suggested workaround/test is: replace

 #+BEGIN_SRC calc :var v=3
  v + 4
 #+END_SRC

 with

 #+BEGIN_SRC calc :var var-v=3
  v + 4
 #+END_SRC

This is working for me as well, I think this will help me to understand
what is going on...

Thank you for you help
 Dieter

PS: Are you using Calc regularly?
-- 
Best wishes
H. Dieter Wilhelm
Darmstadt, Germany




Re: [O] Formal description of Org files

2014-10-04 Thread Gustav Wikström
Hi!

 Just curious: what is it you wish to do in a mobile environment.  I have
 everything I need with MobileOrg and running full emacs + org on an
 OpenPandora.  Obviously, your needs may be different than mine.

 (email composed on train offline on my OpenPandora in Emacs with gnus ;-)

 --
 : Eric S Fraga (0xFFFCF67D), Emacs 24.3.1, Org release_8.3beta-372-gdd70cf

My wish is to be able to do mostly everything related to
task-tracking, scheduling, working with references and so on. General
GTD stuff. OpenPandora sounds neat, except it's not quite the standard
tool available out there ;-) And a general idea of Emacs in your
pocket is nice, except it's not really possible without a different UI
than the keyboard. So; what way forward with GTD in Emacs Org-mode
then, while still having the wish of it to be more accessible?

Thus the idea of a more formal (and parsable) grammar in a
standardized format. My hope is that it will make Org-mode more
general than it already is. As I said already; Org-mode to me is more
than Emacs. To think BIG, Org-mode grammar could be a standard for PIM
or GTD related software. To think a bit less big, it might help
developers create software with non-Emacs tools. By using the formal
grammar to work with Org-mode source documents in more accessible
ways. Maybe with UI's available through mobile phones or tablets (and
without the use of special schedules of read/write in Emacs to keep
the mobile system synced; MobileOrg).

I have to admit I might be overstating the importance of Org-mode
formal grammar with this goal in mind. I haven't used EBNF-parsers and
don't really know how powerful they can be. Reading about those things
give high hopes though.

Best regards
Gustav



Re: [O] Formal description of Org files

2014-10-04 Thread Gustav Wikström
Ah, yes. I've seen that and I really really admire your work. :-) What
I'm aiming at is something more standardised. Something that can be
used to generate language lexers and parsers in other programming
languages.. But, as I stated a moment ago in another mail to the list
- I don't really know the power of such a standardised grammar and of
what can be done if it was there.. I only envision the possibilities.
;-)

Best regards
Gustav

On Sun, Sep 21, 2014 at 2:43 PM, Nicolas Goaziou m...@nicolasgoaziou.fr wrote:
 Hello,

 Gustav Wikström gustav.e...@gmail.com writes:

 There was a discussion many years back about a formal description of
 Org files [1]. In some way that might be achieved now in org-elements,
 but that still is heavily bound to elisp.

 So my question is; have there been more discussions of constructing
 such a formal grammar? Maybe in EBNF form. I suspect getting every
 aspect of Org mode into such a description would be difficult. But
 imagine the possibilities. Tools such as ANTLR and similar would
 straight away have a way of parsing Org mode. Org mode source files
 could be parsed in many other languages, simplifying the process of
 expanding Org mode to other platforms ( Android  iOS, web ).

 Further rant; To me Org mode should be less about Emacs and more about
 the source file format. Let Emacs be the main carrier, but let Org
 mode also expand into other domains. One way to simplify this might be
 to provide the formal description so that other tools might be easier
 to develop based on this grammar.

 (For me, the biggest limitation of Org mode is lacking tools to
 utilize it on the run. The aim of this is thus to feed thoughts on how
 to simplify processes that can expand Org mode into those more
 mobile domains).

 See

   (info (org) Org syntax)


 Regards,

 --
 Nicolas Goaziou



Re: [O] Help on org-export-filter-link-functions

2014-10-04 Thread Rasmus
John Kitchin jkitc...@andrew.cmu.edu writes:

 I too am wondering if there is a defined way to get to the element
 properties within a filter function.

qNo.  But sometimes you can recover it from the text-properties, if it
is not a verb, (~·~, =·=).  Her's an example:

  (defun rasmus/get-org-headline-string-element  (headline backend info)
Return the org element representation of a headline.
(let ((prop-point (next-property-change 0 headline)))
  (and prop-point (plist-get (text-properties-at prop-point headline) 
:parent

-- 
And I faced endless streams of vendor-approved Ikea furniture. . .






[O] Filter by tags

2014-10-04 Thread Chris Henderson
I have 4 * items (* Tasks, * Projects, * Someday/ maybe and * Read and
Review) - how do I select tags (e.g. @internet, @home, @work etc.) only
from * Tasks and * Projects?

Thanks.


[O] Babel introduction example cannot be executed

2014-10-04 Thread jenia.ivlev

Hello.

I want to run one of the examples on babel page. Normally, it's the simplest
example the world has ever seen. I have a table of numbers and I want to
take the evage of those number.

Here is how I did it.

Attemp 1:

#+name: tbl-example-data()
#+begin_src R 
runif(n=5, min=0, max=1)
#+end_src

#+RESULTS: tbl-example-data
| 0.640676139388233 |
| 0.509703768184409 |
| 0.979426965117455 |
| 0.560781393200159 |
| 0.793947959318757 |

#+name: R-mean(x)
#+begin_src R 
mean(x)
#+end_src

When I execute the code here emacs tells me:
Variable x in block R-mean must be assigned a default value.

So what I didn was assign it a default value like so:

#+name: R-mean(x)
#+begin_src R :var x=tbl-example-data
mean(x)
#+end_src


It tells me the exact same thing. What should I change here?

Thanks in advance for your time and kind concern.