emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Kodi Arfer <kodi@arfer.net>
To: Bastien <bzg@altern.org>
Cc: emacs-orgmode@gnu.org
Subject: Re: Bug with automatic alignment of table columns in HTML export
Date: Tue, 19 Mar 2013 15:39:22 -0400	[thread overview]
Message-ID: <5148BEEA.6000702@arfer.net> (raw)
In-Reply-To: <87ehfbrzil.fsf@bzg.ath.cx>

On 2013 Mar 19 Tue 1:26:13 PM -0400, Bastien <bzg@altern.org> wrote:
> Hi Kodi,
>
> Kodi Arfer <kodi@arfer.net> writes:
>
>> Consider an Org file with the following content:
>>
>> |   a | b |
>> |-----+---|
>> | 100 | 1 |
>> |   1 | 1 |
>> |     | 1 |
>> |     | 1 |
>> |     | 1 |
>> |     | 1 |
>> |     | 1 |
>> |     | 1 |
>>
>> Within Emacs, Org right-aligns the left column, as it should, since most
>> nonempty cells in the column are numeric. In HTML export, though (starting
>> from "emacs -Q -l /tmp/minimal-org.el"), the column comes out
>> left-aligned. The problem seems to be with how the exporter treats empty
>> cells, since if you put numbers in all the empty cells above, the column
>> comes out right-aligned in HTML export.
>
> Fixed, thanks.

You're quite welcome. That was prompt! I see this case now works in 
master. The catch is that there are still some cases which give 
inconsistent alignment between Emacs and HTML export, such as:

|   a | b |
|-----+---|
| 100 | 1 |
|   1 | 1 |
|   1 | 1 |
|   1 | 1 |
|   a | 1 |
|     | 1 |
|     | 1 |
|     | 1 |
|     | 1 |
|     | 1 |
|     | 1 |

I believe the heuristic used for in-buffer display is that empty cells 
are ignored entirely when doing the comparison against 
org-table-number-fraction.

  reply	other threads:[~2013-03-19 19:39 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-17 15:08 Bug with automatic alignment of table columns in HTML export Kodi Arfer
2013-03-19 17:26 ` Bastien
2013-03-19 19:39   ` Kodi Arfer [this message]
2013-04-06  0:48     ` Bastien

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=5148BEEA.6000702@arfer.net \
    --to=kodi@arfer.net \
    --cc=bzg@altern.org \
    --cc=emacs-orgmode@gnu.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).