emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] [patch] ox-koma-letter.el: subject changes [2/4]


From: Rasmus
Subject: Re: [O] [patch] ox-koma-letter.el: subject changes [2/4]
Date: Tue, 21 May 2013 19:48:17 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Viktor Rosenfeld <address@hidden> writes:

>> > I found a "bug" in that the subject variable should be a list
>> > cf. the
>> > KOMA manual.  This patch fixes this.
>> >
>> > It's pretty complex for something so simple, and I might be
>> > inclined
>> > to admit to the "put it in a LCO"-file approach might be better.
>> 
>> I'd really like to have a second opinion on this. Viktor?
>
> I think this patch is great simply from the usability standpoint of
> being able to configure the behavior through customize (which I don't
> generally use, but admit that it's a good thing).
>
> I found a few issues though:
>
> 1. Choosing `No export' in customize results
> `\KOMAoption{subject}{nil}'.

Thanks, that's a bug.  I'll look into it ASAP. 

> 2. It is not possible to set a subject format in the LCO file because
> if
> `org-koma-letter-subject-format' is set, the KOMA option will be
> overwritten explicitly, and if it is set to `nil' then the subject is
> inhibited altogether. This is actually a problem with the old code as
> well. One way out of this is to only print the subject line (i.e.,
> `\setkomavar{subject}{.}' if `org-koma-letter-subject-format' is nil
> and
> and fix `noexport' to hide the subject (i.e., inhibit
> `\setkomavar{subject}{.}').


Perhaps the  ox-latex.el way is the way to go:
#+TITLE: # i.e. nothing
The difference would be that here would have not to format subject
komavar at all.

> Is this the entended behaviour? I'll try to post a patch for this
> later tonight.

Yeah, let's think about it.  From my point of view, basically never
using LCO files, I think 
  1. it should be possible to not post a subject.  I tried to implement
     this via #+OPTIONS: subject:nil.
  2. But perhaps I'm trying to be too clever.  I might have defined
     komavar-subject in an LCO file, but still changing subject
     formating on the go.  This is not possible.
  3. If letting subject be disabled by an empty title 2. won't break
     it.  So how about the condition (pseudo lisp):
     (or (title is nil) (subject is nil))?

It should be pretty simple to get to that state I think.

> 3. I'm not a big fan of the parentheses in the subject:(.) syntax, but
> if that's required to use an option list with multiple values I think
> it's okay. 

OK, perhaps there's a clever way to get it to accept several keywords
without a parenthese.  I'm not sure.

> It would be nice to be able to specify a single value without the
> parens, but it's not a high priority (and I don't know how to do
> that).

That should be possible.  I thought I'd tested it.  Note though, that
giving a single value overwrites the default.  I'm not sure whether it
should extend upon the default.

Cheers,
Rasmus

-- 
C is for Cookie



reply via email to

[Prev in Thread] Current Thread [Next in Thread]