From mboxrd@z Thu Jan 1 00:00:00 1970 From: tsd@tsdye.com (Thomas S. Dye) Subject: Re: latex checkboxes Date: Thu, 16 Jun 2011 13:23:18 -1000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from eggs.gnu.org ([140.186.70.92]:57948) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QXLuH-0006MY-7c for emacs-orgmode@gnu.org; Thu, 16 Jun 2011 19:23:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QXLuF-0003S3-Od for emacs-orgmode@gnu.org; Thu, 16 Jun 2011 19:23:25 -0400 Received: from oproxy3-pub.bluehost.com ([69.89.21.8]:47781) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1QXLuF-0003Mz-Bx for emacs-orgmode@gnu.org; Thu, 16 Jun 2011 19:23:23 -0400 In-Reply-To: (Skip Collins's message of "Thu, 16 Jun 2011 18:09:54 -0400") 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: Skip Collins Cc: emacs-orgmode@gnu.org Skip Collins writes: > There is a couple of problems with the way checkboxes are typeset in LaTeX. > > - [ ] a > - [X] b > - [-] c > > is translated to the LaTeX > > \begin{itemize} > \item $\Box$ a > \item $\boxtimes$ b > \item $\boxminus$ c > \end{itemize} > > The first problem is that \Box is not the same size as \boxtimes or \boxminus . > The correct symbol to use from the amssymb package is \square which > matches the other two symbols. > > Another problem is that these symbols were intended to be mathematical > binary operators, and are therefore rather small for the purposes of a > checkbox. I suggest that LaTeX output could be modified to something > like: > > \setbox0=\hbox{\LARGE$\square$} > \begin{itemize} > \item {\parbox[][][c]{\wd0}{\LARGE$\square$}} a > \item {\parbox[][][c]{\wd0}{\LARGE$\boxtimes$}} b > \item {\parbox[][][c]{\wd0}{\LARGE$\boxminus$}} c > \end{itemize} > > The parbox ensures that the checkbox is nicely centered with the first > line of text. > > Another nice-to-have feature would be to use the checkbox as a label > for list items in non-enumerated lists. Currently, the list bullet > appears as visual clutter next to the checkbox. > > Aloha Skip, I think you might be able to get the behavior you want by modifying the variable org-export-latex-list-parameters, perhaps something like '(:ustart "\\setbox0=\\hbox{\\LARGE$\\square$}\n\\begin{itemize}\n" :cboff "\\parbox[][][c]{\\wd0}{\\LARGE$\\square$}" :cbon "\\parbox[][][c]{\\wd0}{\\LARGE$\\boxtimes$}") The variable is set by default to '(:cbon "$\\boxtimes$" :cboff "$\\Box$") in org-latex.el and is used to override the default settings of org-list-to-latex in org-list.el. Not tested. hth, Tom -- Thomas S. Dye http://www.tsdye.com