From mboxrd@z Thu Jan 1 00:00:00 1970 From: James Harkins Subject: Koma-letter bug: backaddress option not included in latex export Date: Sun, 24 Nov 2013 17:44:52 +0800 Message-ID: <93383175-89d6-41e1-a51c-24733922d046@dewdrop-world.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:42118) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VkWGh-0000w6-Mq for emacs-orgmode@gnu.org; Sun, 24 Nov 2013 04:46:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VkWGb-0005D4-VF for emacs-orgmode@gnu.org; Sun, 24 Nov 2013 04:46:19 -0500 Received: from mail-pd0-x22e.google.com ([2607:f8b0:400e:c02::22e]:53040) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VkWGb-0005Cy-NV for emacs-orgmode@gnu.org; Sun, 24 Nov 2013 04:46:13 -0500 Received: by mail-pd0-f174.google.com with SMTP id y13so3629700pdi.33 for ; Sun, 24 Nov 2013 01:46:12 -0800 (PST) Received: from localhost ([219.136.5.70]) by mx.google.com with ESMTPSA id xs1sm73929994pac.7.2013.11.24.01.46.07 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 24 Nov 2013 01:46:12 -0800 (PST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: orgmode I believe I've found a bug in ox-koma-letter.el. Org-mode version 8.2=20 (release_8.2-2-g18c7c4 @ /home/dlm/share/org-mode.git/lisp/) Accepted values for the "backaddress" option are "t" or "nil." If the option is "t," then the export contains a line=20 "\KOMAoption{backaddress}{true}." If the option is nil, I would expect a line=20 "\KOMAoption{backaddress}{false}" but *the line is omitted*. So, LaTeX=20 prints the back address anyway, even though the option is explicitly set to=20= disable the back address. I think the problem is here: (let ((with-backaddress (plist-get info :with-backaddress)) =09 (with-backaddress-set (plist-get info=20 :with-backaddress-changed-in-buffer-p)) .. (when with-backaddress-set =09(format "\\KOMAoption{backaddress}{%s}\n" (if with-backaddress "true"=20 "false"))) Somehow, when backaddress is nil, with-backaddress-set must be false,=20 causing the line not to be generated. **Update**: Same problem with #+OPTIONS: foldmarks. Possibly all the=20 options are broken. ECM (the simple example at [1], with one #+OPTIONS line added): [1] http://orgmode.org/worg/exporters/koma-letter-export.html #+LATEX_CLASS: my-letter #+TITLE: A simple letter #+DATE: April 22, 2013 #+AUTHOR: Jane Doe #+OPTIONS: backaddress:nil #+FROM_ADDRESS: Some Street 1\\ #+FROM_ADDRESS: 12345 Some City #+TO_ADDRESS: John Doe\\ #+TO_ADDRESS: Other Street 1\\ #+TO_ADDRESS: 54321 Other City #+OPENING: Dear John, #+CLOSING: Yours truly, #+SIGNATURE: Jane #+LANGUAGE: en Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. --> % Created 2013-11-24 Sun 17:27 \documentclass{scrlttr2} \usepackage[english]{babel} \setkomavar{fromemail}{dlm@dlm-A6200} \LoadLetterOption{NF} \setkomavar{fromname}{Jane Doe} \setkomavar{fromaddress}{Some Street 1\\\\ 12345 Some City} \setkomavar{signature}{Jane} \date{April 22, 2013} \begin{document} \setkomavar{subject}{A simple letter} \begin{letter}{% John Doe\\\\ Other Street 1\\\\ 54321 Other City} \opening{Dear John,} Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. \closing{Yours truly,} \end{letter} \end{document} ~~~ Change it to backaddress:t and you'll see the difference. hjh