emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <n.goaziou@gmail.com>
To: Francesco Pizzolante
	<public-fpz-djc/iPCCuDYQheJpep6IedvLeJWuRmrY@plane.gmane.org>
Cc: mailing-list-org-mode <public-emacs-orgmode-mXXj517/zsQ@plane.gmane.org>
Subject: Re: Centering graphics in LaTeX export
Date: Fri, 16 May 2014 10:51:42 +0200	[thread overview]
Message-ID: <87d2fem7hd.fsf@gmail.com> (raw)
In-Reply-To: <87vbt79i9d.fsf@somewhere.org> (Francesco Pizzolante's message of "Thu, 15 May 2014 17:25:02 +0200")



Hello,

"Francesco Pizzolante"
<fpz-djc/iPCCuDYQheJpep6IedvLeJWuRmrY@public.gmane.org> writes:

> Here's a small patch that enables centering graphics in LaTeX exports
> (as it already exists for tables).

Thanks for this. A few, minor, comments follow.

> +(defcustom org-latex-images-centered t
> +  "When non-nil, images are exported in a center environment."
> +  :group 'org-export-latex
> +  :type 'boolean)

You need to add

  :version "24.5"
  :package-version '(Org . "8.3")

since this is a new variable.

>  	 (comment-include (if (plist-get attr :comment-include) "%" ""))
>  	 ;; It is possible to specify width and height in the
>  	 ;; ATTR_LATEX line, and also via default variables.
> +	 (centerp (if (plist-member attr :center)
> +                      (plist-get attr :center)
> +		    org-latex-images-centered))

I suggest to move the CENTERP binding above the previous comments.

> +		    path
> +                    (if centerp "\\par}\n" "")
> +                    ))

No parens alone on a line, please.

You also need to update manual and document the feature.

Eventually, could you provide a proper commit message and send an
updated patch?


Regards,

-- 
Nicolas Goaziou

      parent reply	other threads:[~2014-05-16  8:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-15 15:25 Centering graphics in LaTeX export Francesco Pizzolante
2014-05-15 15:28 ` John Hendy
2014-05-16  8:51 ` Nicolas Goaziou [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d2fem7hd.fsf@gmail.com \
    --to=n.goaziou@gmail.com \
    --cc=public-emacs-orgmode-mXXj517/zsQ@plane.gmane.org \
    --cc=public-fpz-djc/iPCCuDYQheJpep6IedvLeJWuRmrY@plane.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).