From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rob Stewart Subject: Fwd: Is `org-preview-latex-fragment` sensitive to alignment specified by document class options? Date: Wed, 9 Apr 2014 16:56:50 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:51417) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WXusD-00014L-N4 for emacs-orgmode@gnu.org; Wed, 09 Apr 2014 11:57:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WXusB-0000Qi-R9 for emacs-orgmode@gnu.org; Wed, 09 Apr 2014 11:57:13 -0400 Received: from mail-yh0-x235.google.com ([2607:f8b0:4002:c01::235]:44881) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WXusB-0000QS-MX for emacs-orgmode@gnu.org; Wed, 09 Apr 2014 11:57:11 -0400 Received: by mail-yh0-f53.google.com with SMTP id i57so1047120yha.26 for ; Wed, 09 Apr 2014 08:57:10 -0700 (PDT) In-Reply-To: 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 Hi, I asked the question below a few days ago, about whether `org-preview-latex-fragment` is sensitive document class options that might affect alignment. I've so far not received feedback, and wondered whether there is more information that I could provide, or if my question is not interesting to other people :-) Git blame tells me that the last commit relating to the definition of `org-preview-latex-fragment` in lisp/org.el is fe939ec by Carsten on 22-03-2008. Who might I be able to poke directly with my question below. Thanks, -- Rob ---------- Forwarded message ---------- From: Rob Stewart Date: 6 April 2014 21:54 Subject: Is `org-preview-latex-fragment` sensitive to alignment specified by document class options? To: emacs-orgmode@gnu.org Hi, Is there a way to make `org-preview-latex-fragment` sensitive to LaTeX class options? I have a simple example to demonstrate where it does not: %%%%%%% #+LaTeX_CLASS: article #+LaTeX_CLASS_OPTIONS: [fleqn] #+LATEX_HEADER: \usepackage{amsmath} \begin{gather} b := (a \oplus s_1) \oplus s_2 \\ e := 0 \\ \end{gather} %%%%%%% If LaTeX is generated for this document with `org-latex-export-to-latex`, which is compiled to a PDF with pdflatex, the "b :=" and the "e :=" are left aligned i.e. the "b" and "e" are vertically aligned. However, if `org-preview-latex-fragment` is called within emacs, the left alignment specified with the `[fleqn]` class option is not honoured. Thus, the two lines in the `gather` block are centrally aligned, which is the default case for `gather` blocks. This is a screenshot of the PDF: http://imgur.com/YVRAlYP This is a screenshot of the preview within emacs: http://imgur.com/S6BNm0K So, is there a way to make `org-preview-latex-fragment` sensitive to LaTeX class options? Thanks, -- Rob