* can't export default koma letter
@ 2016-08-29 14:56 kevinbanjo
2016-08-30 9:45 ` Nicolas Goaziou
0 siblings, 1 reply; 2+ messages in thread
From: kevinbanjo @ 2016-08-29 14:56 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1.1: Type: text/plain, Size: 13360 bytes --]
Hi,
I installed the get-stable version in ~/0work/org-mode and did the make on
it (see my previous email).
I then added
(push "~/0work/org-mode/lisp" load-path)
(push "~/0work/org-mode/etc" load-path)
(push "~/0work/org-mode/contrib" load-path)
(require 'org)
(eval-after-load 'ox '(require 'ox-koma-letter))
(eval-after-load 'ox-koma-letter
'(progn
(add-to-list 'org-latex-classes
'("my-letter"
"\\documentclass\{scrlttr2\}
\\usepackage[english]{babel}
\\setkomavar{frombank}{(1234)\\,567\\,890}
\[DEFAULT-PACKAGES]
\[PACKAGES]
\[EXTRA]"))
(setq org-koma-letter-default-class "my-letter")))
to my .emacs.
Now when I load up the attached koma example letter and try and export it
(C-c C-e k o) I get the following stack trace:
Debugger entered--Lisp error: (wrong-type-argument listp #("Romeo" 0 5
(:parent (#1))))
org-element-set-contents(#("Romeo" 0 5 (:parent (#0))))
apply(org-element-set-contents #("Romeo" 0 5 (:parent (#0))) nil)
#[(s) " \306\307\310 # \311\312 \211 :\204 \313\202\" @9\203! AA\202\"
)\"\210\314\315\n \211 :\2043\313\202@ @9\203? AA\202@ )#\210 \316\211\n
;\203V\317\320\f #\202\\\321 A@\f\"* \211 ;\203n\322 \313\f
$\202z A\323 A@\f
#\240\210 +\210\nA A@\240\210\n @\240*\207" [s new old element property
value replace-regexp-in-string "\n" " " mapc #[(blob) " \305 \211 ;\203
\306\f\307 \n$\202 \fA\310\fA@ \n#\240\210\f+\207" [blob old value property
element :parent org-add-props nil plist-put] 6] nil apply
org-element-set-contents :parent get-text-property 0 plist-get
org-add-props plist-put] 6](#("Romeo" 0 5 (:parent (#0))))
#[(--data) " \211 :\204 ;\205 \306\202 @9\205 @) ?\206\337 \203, \307
\310\">\206\337 \n\2047\311\f \"\202\337 \n\312=\203\\\311\f \211
:\204J\313\202W @9\203V AA\202W )\"\202\337 \n
>\203\202 !\211 \203\201 \203z\314\315 \"\210\202\201 B ) \316=\203\312
;\204\312\n \236A\313 \211 \203\311 @ \f ;\203\266\317\320 #\202\275\307 A@
\"*!\210 A\211 \204\234* \203\202 \316=\203\202 \n >\203\202 \313 \211
\203\201 @\211 @ A ;\203 \317\320 #\202 \307 A@ \"* ! \" !\203w \"
#\235\203_ \" $\235\203P \321 !!\313 %\211 \203L @ %\f %A!\210\f %@!\210
A\211 \2042 *\202w \f !A!\210\f !@!\210\202w \" $\235\203r \311\f\321
!!\"\210\202w \f !!\210* A\211 \204\350*\n &>\206\337 \211 :\204\224
\313\202\241 @9\203\240 AA\202\241 )?\206\337 \322=\203\265 \n '>?\206\337
\323=\203\303 \n (>\206\337 \311\f \211 :\204\320 \313\202\335
@9\203\334 AA\202\335
)\")\207" [--data element --type info --walk-tree types plain-text
plist-get :ignore-list mapc org-data nil throw --map-first-match objects
get-text-property 0 reverse greater-elements elements fun result
first-match --acc --category org-element-secondary-value-alist p
--dolist-tail-- property with-affiliated org-element-all-elements
org-element--parsed-properties-alist kwd-pair value kwd
org-element-dual-keywords org-element-multiple-keywords line no-recursion
org-element-greater-elements org-element-all-objects] 6](#("Romeo" 0 5
(:parent (#0))))
mapc(#[(--data) " \211 :\204 ;\205 \306\202 @9\205 @) ?\206\337 \203,
\307 \310\">\206\337 \n\2047\311\f \"\202\337 \n\312=\203\\\311\f \211
:\204J\313\202W @9\203V AA\202W )\"\202\337 \n
>\203\202 !\211 \203\201 \203z\314\315 \"\210\202\201 B ) \316=\203\312
;\204\312\n \236A\313 \211 \203\311 @ \f ;\203\266\317\320 #\202\275\307 A@
\"*!\210 A\211 \204\234* \203\202 \316=\203\202 \n >\203\202 \313 \211
\203\201 @\211 @ A ;\203 \317\320 #\202 \307 A@ \"* ! \" !\203w \"
#\235\203_ \" $\235\203P \321 !!\313 %\211 \203L @ %\f %A!\210\f %@!\210
A\211 \2042 *\202w \f !A!\210\f !@!\210\202w \" $\235\203r \311\f\321
!!\"\210\202w \f !!\210* A\211 \204\350*\n &>\206\337 \211 :\204\224
\313\202\241 @9\203\240 AA\202\241 )?\206\337 \322=\203\265 \n '>?\206\337
\323=\203\303 \n (>\206\337 \311\f \211 :\204\320 \313\202\335
@9\203\334 AA\202\335
)\")\207" [--data element --type info --walk-tree types plain-text
plist-get :ignore-list mapc org-data nil throw --map-first-match objects
get-text-property 0 reverse greater-elements elements fun result
first-match --acc --category org-element-secondary-value-alist p
--dolist-tail-- property with-affiliated org-element-all-elements
org-element--parsed-properties-alist kwd-pair value kwd
org-element-dual-keywords org-element-multiple-keywords line no-recursion
org-element-greater-elements org-element-all-objects] 6] (#("Romeo" 0 5
(:parent #0))))
#[(--data) " \211 :\204 ;\205 \306\202 @9\205 @) ?\206\337 \203, \307
\310\">\206\337 \n\2047\311\f \"\202\337 \n\312=\203\\\311\f \211
:\204J\313\202W @9\203V AA\202W )\"\202\337 \n
>\203\202 !\211 \203\201 \203z\314\315 \"\210\202\201 B ) \316=\203\312
;\204\312\n \236A\313 \211 \203\311 @ \f ;\203\266\317\320 #\202\275\307 A@
\"*!\210 A\211 \204\234* \203\202 \316=\203\202 \n >\203\202 \313 \211
\203\201 @\211 @ A ;\203 \317\320 #\202 \307 A@ \"* ! \" !\203w \"
#\235\203_ \" $\235\203P \321 !!\313 %\211 \203L @ %\f %A!\210\f %@!\210
A\211 \2042 *\202w \f !A!\210\f !@!\210\202w \" $\235\203r \311\f\321
!!\"\210\202w \f !!\210* A\211 \204\350*\n &>\206\337 \211 :\204\224
\313\202\241 @9\203\240 AA\202\241 )?\206\337 \322=\203\265 \n '>?\206\337
\323=\203\303 \n (>\206\337 \311\f \211 :\204\320 \313\202\335
@9\203\334 AA\202\335
)\")\207" [--data element --type info --walk-tree types plain-text
plist-get :ignore-list mapc org-data nil throw --map-first-match objects
get-text-property 0 reverse greater-elements elements fun result
first-match --acc --category org-element-secondary-value-alist p
--dolist-tail-- property with-affiliated org-element-all-elements
org-element--parsed-properties-alist kwd-pair value kwd
org-element-dual-keywords org-element-multiple-keywords line no-recursion
org-element-greater-elements org-element-all-objects] 6]((#("Romeo" 0 5
(:parent #0))))
byte-code(" !\210\n\237\207" [--walk-tree data --acc] 2)
org-element-map((#("Romeo" 0 5 (:parent #0))) plain-text #[(s) "
\306\307\310 # \311\312 \211 :\204 \313\202\" @9\203! AA\202\"
)\"\210\314\315\n \211 :\2043\313\202@ @9\203? AA\202@ )#\210 \316\211\n
;\203V\317\320\f #\202\\\321 A@\f\"* \211 ;\203n\322 \313\f
$\202z A\323 A@\f
#\240\210 +\210\nA A@\240\210\n @\240*\207" [s new old element property
value replace-regexp-in-string "\n" " " mapc #[(blob) " \305 \211 ;\203
\306\f\307 \n$\202 \fA\310\fA@ \n#\240\210\f+\207" [blob old value property
element :parent org-add-props nil plist-put] 6] nil apply
org-element-set-contents :parent get-text-property 0 plist-get
org-add-props plist-put] 6])
org-export--get-inbuffer-options([cl-struct-org-export-backend
koma-letter latex ((export-block . org-koma-letter-export-block)
(export-snippet . org-koma-letter-export-snippet) (headline .
org-koma-letter-headline) (keyword . org-koma-letter-keyword) (template .
org-koma-letter-template)) ((:latex-class "LATEX_CLASS" nil
org-koma-letter-default-class t) (:lco "LCO" nil
org-koma-letter-class-option-file) (:author "AUTHOR" nil
(org-koma-letter--get-value org-koma-letter-author) parse)
(:author-changed-in-buffer-p "AUTHOR" nil nil t) (:from-address
"FROM_ADDRESS" nil org-koma-letter-from-address newline) (:phone-number
"PHONE_NUMBER" nil org-koma-letter-phone-number) (:email "EMAIL" nil
(org-koma-letter--get-value org-koma-letter-email) t) (:to-address
"TO_ADDRESS" nil nil newline) (:place "PLACE" nil org-koma-letter-place)
(:subject "SUBJECT" nil nil parse) (:opening "OPENING" nil
org-koma-letter-opening parse) (:closing "CLOSING" nil
org-koma-letter-closing parse) (:signature "SIGNATURE" nil
org-koma-letter-signature newline) (:special-headings nil
"special-headings" org-koma-letter-prefer-special-headings) (:special-tags
nil nil (append org-koma-letter-special-tags-in-letter
org-koma-letter-special-tags-after-closing
org-koma-letter-special-tags-after-letter)) (:with-after-closing nil
"after-closing-order" org-koma-letter-special-tags-after-closing)
(:with-after-letter nil "after-letter-order"
org-koma-letter-special-tags-after-letter) (:with-backaddress nil
"backaddress" org-koma-letter-use-backaddress) (:with-email nil "email"
org-koma-letter-use-email) (:with-foldmarks nil "foldmarks"
org-koma-letter-use-foldmarks) (:with-phone nil "phone"
org-koma-letter-use-phone) (:with-place nil "place"
org-koma-letter-use-place) (:with-subject nil "subject"
org-koma-letter-subject-format) (:with-title-as-subject nil "title-subject"
org-koma-letter-prefer-subject) (:with-headline-opening nil nil
org-koma-letter-headline-is-opening-maybe) (:inbuffer-author "AUTHOR" nil
(quote koma-letter:empty)) (:inbuffer-email "EMAIL" nil (quote
koma-letter:empty)) (:inbuffer-phone-number "PHONE_NUMBER" nil (quote
koma-letter:empty)) (:inbuffer-place "PLACE" nil (quote koma-letter:empty))
(:inbuffer-signature "SIGNATURE" nil (quote koma-letter:empty))
(:inbuffer-with-backaddress nil "backaddress" (quote koma-letter:empty))
(:inbuffer-with-email nil "email" (quote koma-letter:empty))
(:inbuffer-with-foldmarks nil "foldmarks" (quote koma-letter:empty))
(:inbuffer-with-phone nil "phone" (quote koma-letter:empty))
(:inbuffer-with-place nil "place" (quote koma-letter:empty))) nil nil (107
"Export with KOMA Scrlttr2" ((76 "As LaTeX buffer"
org-koma-letter-export-as-latex) (108 "As LaTeX file"
org-koma-letter-export-to-latex) (112 "As PDF file"
org-koma-letter-export-to-pdf) (111 "As PDF file and open" (lambda (a s v
b) (if a (org-koma-letter-export-to-pdf t s v b) (org-open-file
(org-koma-letter-export-to-pdf nil s v b)))))))])
org-export-get-environment([cl-struct-org-export-backend koma-letter
latex ((export-block . org-koma-letter-export-block) (export-snippet .
org-koma-letter-export-snippet) (headline . org-koma-letter-headline)
(keyword . org-koma-letter-keyword) (template . org-koma-letter-template))
((:latex-class "LATEX_CLASS" nil org-koma-letter-default-class t) (:lco
"LCO" nil org-koma-letter-class-option-file) (:author "AUTHOR" nil
(org-koma-letter--get-value org-koma-letter-author) parse)
(:author-changed-in-buffer-p "AUTHOR" nil nil t) (:from-address
"FROM_ADDRESS" nil org-koma-letter-from-address newline) (:phone-number
"PHONE_NUMBER" nil org-koma-letter-phone-number) (:email "EMAIL" nil
(org-koma-letter--get-value org-koma-letter-email) t) (:to-address
"TO_ADDRESS" nil nil newline) (:place "PLACE" nil org-koma-letter-place)
(:subject "SUBJECT" nil nil parse) (:opening "OPENING" nil
org-koma-letter-opening parse) (:closing "CLOSING" nil
org-koma-letter-closing parse) (:signature "SIGNATURE" nil
org-koma-letter-signature newline) (:special-headings nil
"special-headings" org-koma-letter-prefer-special-headings) (:special-tags
nil nil (append org-koma-letter-special-tags-in-letter
org-koma-letter-special-tags-after-closing
org-koma-letter-special-tags-after-letter)) (:with-after-closing nil
"after-closing-order" org-koma-letter-special-tags-after-closing)
(:with-after-letter nil "after-letter-order"
org-koma-letter-special-tags-after-letter) (:with-backaddress nil
"backaddress" org-koma-letter-use-backaddress) (:with-email nil "email"
org-koma-letter-use-email) (:with-foldmarks nil "foldmarks"
org-koma-letter-use-foldmarks) (:with-phone nil "phone"
org-koma-letter-use-phone) (:with-place nil "place"
org-koma-letter-use-place) (:with-subject nil "subject"
org-koma-letter-subject-format) (:with-title-as-subject nil "title-subject"
org-koma-letter-prefer-subject) (:with-headline-opening nil nil
org-koma-letter-headline-is-opening-maybe) (:inbuffer-author "AUTHOR" nil
(quote koma-letter:empty)) (:inbuffer-email "EMAIL" nil (quote
koma-letter:empty)) (:inbuffer-phone-number "PHONE_NUMBER" nil (quote
koma-letter:empty)) (:inbuffer-place "PLACE" nil (quote koma-letter:empty))
(:inbuffer-signature "SIGNATURE" nil (quote koma-letter:empty))
(:inbuffer-with-backaddress nil "backaddress" (quote koma-letter:empty))
(:inbuffer-with-email nil "email" (quote koma-letter:empty))
(:inbuffer-with-foldmarks nil "foldmarks" (quote koma-letter:empty))
(:inbuffer-with-phone nil "phone" (quote koma-letter:empty))
(:inbuffer-with-place nil "place" (quote koma-letter:empty))) nil nil (107
"Export with KOMA Scrlttr2" ((76 "As LaTeX buffer"
org-koma-letter-export-as-latex) (108 "As LaTeX file"
org-koma-letter-export-to-latex) (112 "As PDF file"
org-koma-letter-export-to-pdf) (111 "As PDF file and open" (lambda (a s v
b) (if a (org-koma-letter-export-to-pdf t s v b) (org-open-file
(org-koma-letter-export-to-pdf nil s v b)))))))] nil (:output-file
"./k2.tex"))
org-export-as(koma-letter nil nil nil (:output-file "./k2.tex"))
org-export-to-file(koma-letter "./k2.tex" nil nil nil nil nil #[(file)
"\301 !\207" [file org-latex-compile] 2])
org-koma-letter-export-to-pdf(nil nil nil nil)
(org-open-file (org-koma-letter-export-to-pdf nil s v b))
(if a (org-koma-letter-export-to-pdf t s v b) (org-open-file
(org-koma-letter-export-to-pdf nil s v b)))
(lambda (a s v b) (if a (org-koma-letter-export-to-pdf t s v b)
(org-open-file (org-koma-letter-export-to-pdf nil s v b))))(nil nil nil nil)
org-export-dispatch(nil)
call-interactively(org-export-dispatch nil nil)
command-execute(org-export-dispatch)
I also used package-list-packages to delete org and org-contrib so
hopefully its running the latest stable from my includes
Can anyone help?
I just want to be able to do letters, not a lot of lisp debugging. :\
[-- Attachment #1.2: Type: text/html, Size: 18907 bytes --]
[-- Attachment #2: k2.org --]
[-- Type: application/octet-stream, Size: 2186 bytes --]
* Preamble :noexport:
#+TITLE: Mis-shapen chaos of well-seeming forms!
#+SUBJECT: Or: org-mode and KOMA-Script letters
#+DATE: 1580
#+AUTHOR: Romeo
#+PLACE: Verona, Italy
#+LCO: DINmtext
#+OPTIONS: after-closing-order:(my_after_signature ps cc encl)
#+options: ':t backaddress:t subject:centered
#+LATEX_HEADER: \setkomavar{firsthead}{}
* To-address of the lovely Juliet :to:
Juliet
House of Capulet
Verona
* From :from:
House of Montague
Verona
* Location :location:
#+LATEX_HEADER: \usepackage{tikz}
#+BEGIN_CENTER
*Montague*
#+BEGIN_EXPORT latex
\tikz \draw (0,0) --+ (0,-1)
arc [radius=1, start angle=-180, end angle=0]
--+ (0,1) -- cycle
node [below=1.5em,midway] {\bfseries M};
#+END_EXPORT
#+END_CENTER
* Dear Juliet,
#+BEGIN_VERSE
Then plainly know my heart's dear love is set
On the fair daughter of rich Capulet:
As mine on hers, so hers is set on mine;
And all combin'd, save what thou must combine
By holy marriage: when, and where, and how
We met, we woo'd, and made exchange of vow,
I'll tell thee as we pass; but this I pray,
That thou consent to marry us to-day.
#+END_VERSE
* Yours truly, :closing:
Romeo of House Montague
* some arbitrary LaTeX code :my_after_signature:
#+BEGIN_EXPORT latex
% this special heading was added dynamically.
#+END_EXPORT
* PS :ps:
PS: "PS" is not typeset automatically by KOMA-Script
@@latex:\noindent@@ PPS: This is a feature!
* CC :cc:
Paris and Lawrence.
* ENCL :encl:
See also The Tragedy of Romeo and Juliet
* some more arbitrary LaTeX code :after_letter:
#+BEGIN_EXPORT latex
% here we can place random LaTeX code, e.g. including PDFs via the pdfpages package.
#+END_EXPORT
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: can't export default koma letter
2016-08-29 14:56 can't export default koma letter kevinbanjo
@ 2016-08-30 9:45 ` Nicolas Goaziou
0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Goaziou @ 2016-08-30 9:45 UTC (permalink / raw)
To: kevinbanjo; +Cc: emacs-orgmode
Hello,
kevinbanjo <kevinbanjo@gmail.com> writes:
> Hi,
> I installed the get-stable version in ~/0work/org-mode and did the make on
> it (see my previous email).
>
> I then added
>
> (push "~/0work/org-mode/lisp" load-path)
> (push "~/0work/org-mode/etc" load-path)
> (push "~/0work/org-mode/contrib" load-path)
>
> (require 'org)
>
> (eval-after-load 'ox '(require 'ox-koma-letter))
Note that ox-koma-letter already requires "ox".
> Debugger entered--Lisp error: (wrong-type-argument listp #("Romeo" 0 5
> (:parent (#1))))
> org-element-set-contents(#("Romeo" 0 5 (:parent (#0))))
> apply(org-element-set-contents #("Romeo" 0 5 (:parent (#0))) nil)
> #[(s) " \306\307\310 # \311\312 \211 :\204 \313\202\" @9\203! AA\202\"
> )\"\210\314\315\n \211 :\2043\313\202@ @9\203? AA\202@ )#\210 \316\211\n
> ;\203V\317\320\f #\202\\\321 A@\f\"* \211 ;\203n\322 \313\f
I cannot reproduce it.
It looks like you are having a mixed installation problem.
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-08-30 9:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-29 14:56 can't export default koma letter kevinbanjo
2016-08-30 9:45 ` Nicolas Goaziou
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).