msnoigrs / ox-rst

reStructuredText Back-End for Org-Mode Export Engine
116 stars 18 forks source link

Need space in table #11

Closed yitang closed 9 years ago

yitang commented 9 years ago

Hi,

Apart from #10 , I also noticed a strange behaviour in exporting tables. In the following image, the first table is in org-format, the second table is the exported rst-format.

screenshot from 2015-03-30 10 17 49

Notice the separator | in the middle in table 2, does no line up (should be underneath the +), and I have to remove two spaces, while for the last separate, I have to add three spaces to make the table format correct, otherwise, the Spnix throws this error message:

ERROR: Malformed table.

I only see this strange behaviour in 3 out of 20-ish tables I was exporting, and I don't know why it was triggered since the org-table looks perfectly fine.

-Yi

msnoigrs commented 9 years ago

Hi.

I can't reproduce the problem in my environment. If possible, please indicate the other example.

yitang commented 9 years ago

Hi, this is a minimal example I can produce on my side.

The following graph illustrates the CDF represented by this data:

[[./img/image071.png]]

Consider now that the user has requested 

| Probability of Non-Exceedance | Loss Value (Million) |
|                             0 |                    0 |
|                          0.05 |                    0 |
|                          0.25 |                    0 |
|                           0.5 |                  200 |
|                          0.75 |                  400 |
|                          0.95 |                  480 |
|                             1 |                  500 |

The following graph shows the 

The exported content is:

.. contents::
The following graph illustrates the CDF represented by this data:

.. image:: ./img/image071.png

Consider now that the user has requested 

.. table::

    +-------------------------------+----------------------+
    | Probability of Non-Exceedance | Loss Value (Million) |
    +-------------------------------+----------------------+
    |               0 |            0 |
    +-------------------------------+----------------------+
    |            0.05 |            0 |
    +-------------------------------+----------------------+
    |            0.25 |            0 |
    +-------------------------------+----------------------+
    |             0.5 |          200 |
    +-------------------------------+----------------------+
    |            0.75 |          400 |
    +-------------------------------+----------------------+
    |            0.95 |          480 |
    +-------------------------------+----------------------+
    |               1 |          500 |
    +-------------------------------+----------------------+

The following graph shows the 
msnoigrs commented 9 years ago

sorry, still can not reproduce.

yitang commented 9 years ago

Hello, I tried it again with a fresh Emacs session with only org and ox-rst loaded, and everything is fine. So it shows some of my settings triggered the problems. Once I figure out I will let you know. Thank you.

-Yi