From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?UTF-8?B?TWFydGluIFNjaMO2w7Zu?= Subject: Re: Using KOMA and Memoir? Date: Thu, 8 May 2014 22:17:09 +0200 Message-ID: References: <87siongy2s.fsf@ucl.ac.uk> <87ppjqhwcd.fsf@ucl.ac.uk> <871tw571zk.fsf@alphaville.bos.redhat.com> <20140507222914.GB2785@chitra.no-ip.org> <20140508125830.GE2711@chitra.no-ip.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7b60457c6a8cee04f8e92aef Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:52578) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WiUkh-0007L6-S9 for emacs-orgmode@gnu.org; Thu, 08 May 2014 16:17:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WiUkg-0006tN-Cd for emacs-orgmode@gnu.org; Thu, 08 May 2014 16:17:11 -0400 Received: from mail-qc0-x22a.google.com ([2607:f8b0:400d:c01::22a]:50661) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WiUkg-0006sM-7K for emacs-orgmode@gnu.org; Thu, 08 May 2014 16:17:10 -0400 Received: by mail-qc0-f170.google.com with SMTP id i8so3550398qcq.29 for ; Thu, 08 May 2014 13:17:09 -0700 (PDT) In-Reply-To: <20140508125830.GE2711@chitra.no-ip.org> 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: "emacs-orgmode@gnu.org" --047d7b60457c6a8cee04f8e92aef Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Tonight I have been a bit adventurous and I have seen some success. But before that I tried to understand what lading ox-latex meant and how to do it. I found something here: http://orgmode.org/worg/exporters/koma -letter-export.html and tried it with no luck. Then I thought, org + LaTeX and exporting to PDF= works just fine as long as I stay away from trying KOMA so ox-latex must work... Next I looked up org-latex.el in the directory org-mode version 8.2.5h lives in my computer and started to study the code. I soon found were org-latex-classes are defined and decided to add the code Eric has supplied. Now komaarticle works! This indicates to me that ox-latex has loaded just fine all the time and it is indeed the one from version 8.2.5h that loads. So why didn't it work the way I was told to do it? How much of my .emacs is needed to figure it out, all? Here are the parts I think are relevant. First the very beginning of my .emacs (comments are mixed Swedish and English): ;;; Martins nya .emacs ;;; ;;; (Re)creation started 130819 ;;; Most material comes from .emacs.statler ;;; ;;;;;;;;;;;;;;;;;;;;;; Colours and fonts and what not ;;;;;;;;;;;;;;;;;;; ;; Added 2011-11-04 ;; path till 'egna' lisp-filer (add-to-list 'load-path "~/.emacs.d/my_lisp/") ;; (require 'color-theme-solarized) ;; Added 2011-11-18 ;; Egenvald defaultfont ;;(set-default-font "-gohu-gohufont-medium-*-*-*-11-*-*-*-*-*-*-*") ;;(modify-frame-parameters nil '((wait-for-wm . nil))) ;; british spelling (setq ispell-dictionary "british") ;;;;;;;;;;;;;;;;; To shift focus between frames ;;;;;;;;;;;;;;;;;;;;;; ;; Added 2013-08-19 ;; from http://www.emacswiki.org/emacs/FrameMove ;; framemove.el is placed in my_lisp ;; ;;(require 'framemove) ;; (windmove-default-keybindings) ;; default prefix is Meta ;; (setq framemove-hook-into-windmove t) ;;;;;;;;;;;;;;;;;;;;;; Org-mode stuff ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Added 2014-03-02 ;; to make emacs find org-mode other than default: (add-to-list 'load-path "/home/martin/Program/Org-mode/org-8.2.5h/lisp") (add-to-list 'load-path "/home/martin/Program/Org-mode/org-8.2.5h/contrib /lisp") (require 'org) ;; ;; Added 2014-04-08 ;; Trying to force ox-latex as per http://orgmode.org/worg/exporters/koma -letter-export.html ;; ;(eval-after-load 'ox-latex ; '(add-to-list 'org-latex-packages-alist '("AUTO" "babel" t) t)) ;; After this follows many lines of tweaks most of which is copied from BerntHansen and none of it related to bable or exporting. This is the stuff I have been using for a while and use every day at work. Then near the end LaTeX and Eric's code (commented out): ;;; ;;; ;;; LaTeX ;;; (org-babel-do-load-languages 'org-babel-load-languages '((latex . t))) ;;; ;;; KOMA ;;; ;(add-to-list 'org-latex-classes ; '("komaarticle" "\\documentclass{scrartcl}" ; ("\\section{%s}" . "\\section*{%s}") ; ("\\subsection{%s}" . "\\subsection*{%s}") ; ("\\subsubsection{%s}" . "\\subsubsection*{%s}") ; ("\\paragraph{%s}" . "\\paragraph*{%s}") ; ("\\subparagraph{%s}" . "\\subparagraph*{%s}"))) ;;; So much for Thursday evening. --=20 Martin Sch=C3=B6=C3=B6n http://hem.bredband.net/b262106/index.html --047d7b60457c6a8cee04f8e92aef Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Tonight = I have been a bit adventurous and I have seen some success.
But be= fore that I tried to understand what lading ox-latex meant and how
to do= it. I found something here: http://orgmode.o= rg/worg/exporters/koma= -letter-export.html
and tried it with no luck. Then I thought, org + LaTeX and exporting to PDF works
just fine as long as I stay away from trying = KOMA so ox-latex must work...

Next I looked up org-latex.el in th= e directory org-mode version 8.2.5h lives in
my computer and start= ed to study the code. I soon found were org-latex-classes
are defi= ned and decided to add the code Eric has supplied.

Now komaarticle works!

This indicates to me that ox-latex has loaded just fine all the time and i= t is indeed
the one from version 8.2.5h that loads.

So why = didn't it work the way I was told to do it?
How much of my .emacs is needed to figu= re it out, all? Here are the parts I think
are relevant. First the very = beginning of my .emacs (comments are mixed Sw= edish
and English):

;;; Martins nya .emacs
;;;
;;; (Re)creation started 130819
;= ;; Most material comes from .emacs.statler
;;;
;;;;;;;;;;;;;;;;;;;;;; Colours and fonts and what not ;;;;;;;;;;;;;;= ;;;;;
;; Added 2011-11-04
;; path till 'egna' lisp-filer
(= add-to-list 'load-path "~/.emacs.d/m= y_lisp/")
;; (require 'color-theme-solarized)
;;= Added 2011-11-18
;; Egenvald defaultfont
;;(set-default-font "-gohu-gohufont-medium-*-*-*-11-= *-*-*-*-*-*-*")
;;(modify-frame-parameters nil '((wait-for-wm . nil)))
;; british spelling
(setq
ispell-diction= ary "british")

;;;;;;;;;;;;;;;;; To shift focus between frames ;;;;;;;;;;;;;;;;;;;;;;<= br>;; Added 2013-08-19
;; from http://www.emacswiki.org/emacs/FrameMove
;; framemove.el= is placed in my_lisp
;;
;;(require 'framemove)
;;=C2=A0=C2=A0= =C2=A0 (windmove-default-keybindings)=C2=A0 ;; default prefix is Meta
;;=C2=A0=C2=A0=C2=A0 (setq framemove-hook-into-windmove t)<= br>

;;;;;;;;;;;;;;;;;;;;;; Org-mode stuff ;;;;;;;;;;;;;;;;;;;;;;;;;;= ;;;;;;
;; Added 2014-03-02
;; to make emacs find org-mode other than def= ault:
(add-to-list 'load-path "/home/martin/Program/Org-mode/or= g-8.2.5h/lisp")
(add-to-list 'load-path "/home/martin/Prog= ram/Org-mode/org-8.2.5h/contrib/lisp") (require 'org)
;;
;; Added 2014-04-08
;; Trying to force ox-la= tex as per http://orgmode.org/worg/exporters/koma-letter-exp= ort.html
;;
;(eval-after-load 'ox-latex
;=C2= =A0 '(add-to-list 'org-latex-packages-alist<= /span> '("AUTO" "babel" t) t))
;;

After this follows many lines of twe= aks most of which is copied from Bernt Hansen= and
none of it related to bable or exporting. Thi= s is the stuff I have been using for a while
and use every day at work.<= br>
Then near the end LaTeX and Eric's code (commented out):

;;;
;;;
;;; LaTeX
;;;
(org-ba= bel-do-load-languages
=C2=A0'org-babel-load-languages
=C2=A0'= ((latex . t)))
;;;
;;; KOMA
;;;
;= (add-to-list 'org-latex-classes
;=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 '("komaarticle" &q= uot;\\documentclass{scrartcl}"
;=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0 ("\\section{%s}" . "\\section*{%s}")=
;=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0 ("\\subsection{%s}" . "\\subsection= *{%s}")
;=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ("\\subsubsection{%s}" . = "\\subsubsection*{%s}")
;=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ("\\parag= raph{%s}" . "\\paragraph*{%s}")
;=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0 ("\\subparagraph{%s}" . "\\subparag= raph*{%s}")))
;;;

So much f= or Thursday evening.

--047d7b60457c6a8cee04f8e92aef--