Visuwesh <visuwe...@gmail.com> writes:

>> Here is the recipe
>> 1. make repro (I tried with the latest Emacs master and with Emacs 29)
>> 2. Open test.odt (attached)
>> 3. M-x org-mode
>> 4. Copy the non-empty cell area
>> 5. M-x yank-media <RET> app<TAB> <RET>
>> 6. Observe encoding problems
>
> Thanks for the reproducer.  I think this might be locale-dependent.  I
> fail to reproduce on my end with the following locale settings:
>
>     LANG=en_GB.UTF-8
>     LC_COLLAGE=ta_IN.UTF-8
>     LC_MONETARY=ta_IN.UTF-8
>     LC_NUMERIC=ta_IN.UTF-8
>
>     locale-coding-system = 'utf-8-unix
>
> I have no idea how to deal with locale issues like this unfortunately.

I tested a bit further, and it might not be locale. Maybe it is some
LibreOffice version issue or build issue.

Below is the DATA passed to yank handler:

Debugger entered--entering a function:
* org--libreoffice-table-handler(application/x-libreoffice-tsvc 
#("1\0\11\0002\0\11\0003\0\n\0004\0\11\0005\0\11\0005\0\n\0" 0 24 
(foreign-selection application/x-libreoffice-tsvc)))
  yank-media()

As you can see, the data contains \0 characters.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

Reply via email to