* Orgmode/Koma script letter
@ 2014-08-19 3:44 Vikas Rawal
2014-08-19 8:22 ` Rasmus
0 siblings, 1 reply; 4+ messages in thread
From: Vikas Rawal @ 2014-08-19 3:44 UTC (permalink / raw)
To: org-mode mailing list
I am trying to create a custom template for my letterhead. The documentation suggests that by default title should be used as subject of the letter.
ox-koma-letter.el has this:
(defcustom org-koma-letter-subject-format t
"Use the title as the subject of the letter.
Byt when I export a file,
#+TITLE: A simple letter
is exported as
\setkomavar{title}{A simple letter}
rather than as
\setkomavar{subject}{A simple letter}
Accordingly, title appears separately as a badly formatted title.
If I have a separate #+Subject: line, that is correctly exported as a subject.
Is there something wrong in what I am doing or is there a problem?
Org version: Org-mode version 8.3beta (release_8.3beta-167-g003edd @ /Users/vikas/.emacs.d/src/org/lisp/)
Vikas
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Orgmode/Koma script letter
2014-08-19 3:44 Orgmode/Koma script letter Vikas Rawal
@ 2014-08-19 8:22 ` Rasmus
2014-08-22 13:54 ` Bastien
0 siblings, 1 reply; 4+ messages in thread
From: Rasmus @ 2014-08-19 8:22 UTC (permalink / raw)
To: emacs-orgmode
Hi Vikas,
Vikas Rawal <vikaslists@agrarianresearch.org> writes:
> I am trying to create a custom template for my letterhead. The
> documentation suggests that by default title should be used as subject
> of the letter.
Cool. Let us know how it goes.
> ox-koma-letter.el has this:
> (defcustom org-koma-letter-subject-format t
> "Use the title as the subject of the letter.
That's a bug in the documentation, if anything. The rest of the
docstring is fine. It gives you a mean of formatting the subject
line, e.g. center it and make it bold.
I'll correct it later.
I'm kind of busy now, but check the docstring of
`org-koma-letter-use-title' and `org-koma-letter-prefer-subject'.
Hopefully setting the latter to non-nil will give you what you want.
> Byt when I export a file,
>
> #+TITLE: A simple letter
>
> is exported as
>
> \setkomavar{title}{A simple letter}
>
> rather than as
>
> \setkomavar{subject}{A simple letter}
>
> Accordingly, title appears separately as a badly formatted title.
>
> If I have a separate #+Subject: line, that is correctly exported as a subject.
This is a feature.
> Is there something wrong in what I am doing or is there a problem?
I don't think there is a code bug. There is a potentially a
documentation bug in the first line of the doc string you mentioned.
> Org version: Org-mode version 8.3beta (release_8.3beta-167-g003edd @
> /Users/vikas/.emacs.d/src/org/lisp/)
Hope it helps,
Rasmus
--
It was you, Jezebel, it was you
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Orgmode/Koma script letter
2014-08-19 8:22 ` Rasmus
@ 2014-08-22 13:54 ` Bastien
2014-08-24 13:41 ` Rasmus
0 siblings, 1 reply; 4+ messages in thread
From: Bastien @ 2014-08-22 13:54 UTC (permalink / raw)
To: Rasmus; +Cc: emacs-orgmode
Rasmus <rasmus@gmx.us> writes:
>> Is there something wrong in what I am doing or is there a problem?
>
> I don't think there is a code bug. There is a potentially a
> documentation bug in the first line of the doc string you mentioned.
Indeed, this is a documentation bug -- can one of you provide a
patch for it?
Thanks!
--
Bastien
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Orgmode/Koma script letter
2014-08-22 13:54 ` Bastien
@ 2014-08-24 13:41 ` Rasmus
0 siblings, 0 replies; 4+ messages in thread
From: Rasmus @ 2014-08-24 13:41 UTC (permalink / raw)
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 407 bytes --]
Hi,
Bastien <bzg@gnu.org> writes:
>>> Is there something wrong in what I am doing or is there a problem?
>>
>> I don't think there is a code bug. There is a potentially a
>> documentation bug in the first line of the doc string you mentioned.
>
> Indeed, this is a documentation bug -- can one of you provide a
> patch for it?
Please see attached.
—Rasmus
--
This space is left intentionally blank
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-ox-koma-letter.el-update-docstring.patch --]
[-- Type: text/x-diff, Size: 1392 bytes --]
From 19c35523994e55a0425d6d52159e6f4687e5ff9d Mon Sep 17 00:00:00 2001
From: Rasmus <rasmus@gmx.us>
Date: Sun, 24 Aug 2014 15:35:17 +0200
Subject: [PATCH] ox-koma-letter.el: update docstring
* ox-koma-letter.el (org-koma-letter-prefer-special-headings): change
docstring.
---
contrib/lisp/ox-koma-letter.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/contrib/lisp/ox-koma-letter.el b/contrib/lisp/ox-koma-letter.el
index d3aa335..951edf4 100644
--- a/contrib/lisp/ox-koma-letter.el
+++ b/contrib/lisp/ox-koma-letter.el
@@ -222,7 +222,7 @@ This option can also be set with the OPTIONS keyword, e.g.:
:type 'boolean)
(defcustom org-koma-letter-subject-format t
- "Use the title as the subject of the letter.
+ "When non-nil include subject. Supports formatting options.
When t, insert a subject using default options. When nil, do not
insert a subject at all. It can also be a list of symbols among
@@ -609,7 +609,7 @@ holding export options."
(org-koma-letter--build-settings 'buffer info)
;; From address.
(let ((from-address (org-koma-letter--determine-to-and-from info 'from)))
- (when (org-string-nw-p from-address)
+ (when (org-string-nw-p from-address)
(format "\\setkomavar{fromaddress}{%s}\n" from-address)))
;; Date.
(format "\\date{%s}\n" (org-export-data (org-export-get-date info) info))
--
2.1.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-08-24 13:41 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-19 3:44 Orgmode/Koma script letter Vikas Rawal
2014-08-19 8:22 ` Rasmus
2014-08-22 13:54 ` Bastien
2014-08-24 13:41 ` Rasmus
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).