all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Max Nikulin <manikulin@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: Add \usepackage{cmap} as default LaTeX class in ox-latex (was: org exported pdf files)
Date: Thu, 29 Sep 2022 22:34:07 +0700	[thread overview]
Message-ID: <th4dth$5df$1@ciao.gmane.io> (raw)
In-Reply-To: <87bkqy95ud.fsf@localhost>

On 29/09/2022 11:12, Ihor Radchenko wrote:
> Max Nikulin writes:
> 
>> On 28/09/2022 10:07, Ihor Radchenko wrote:
>>> Max Nikulin writes:
>>>
>>>> - What TeX engine do you use? E.g. for PdfLaTeX it may be necessary to
>>>> add \usepackage{cmap} immediately after \documentclass. Unicode engines
>>>> like LuaTeX likely do not require such trick.
>>>
>>> I am wondering if having cmap should be a good default in general.
>>> Not just for accessibility.
>>
>> For me it must have, but I am a rare person on this mail list who is
>> happy with the Computer Modern font (actually cm-super Type 1 font). I
>> have never tried .ttf fonts with PdfLaTeX and I am unaware of effect of
>> \usepackage{cmap} in that case.
> 
> May others familiar with LaTeX comment on this?
> If it is safe to add cmap to default LaTeX template, I see no reason why
> we should not.

It seems something changed during last decade. I have not tried default 
Type3 raster fonts (I do not remember if it is possible to disable 
cm-super without uninstalling it), but at least with cm-super installed, 
the cmap package is not necessary to have Cyrillic text properly encoded 
in PDF files, not to mention ASCII. I have tried utf8 and cp1251 options 
of inputenc.

However with cmap more math characters get correct unicode symbols

\[ \forall \delta \exists \epsilon \ne t \]

I tried to search for problems that may cause cmap. There is no 
incompatibility with \usepackage[pdfa=true]{hyperref} anymore
https://tex.stackexchange.com/questions/64585/incompatibilities-of-cmap-with-fontenc-hyperref
(side note: the answer marked as accepted is incorrect). So I hope, it 
is safe to use this package for PdfLaTeX.

I have noticed mmap package intended to improve math representation
https://tex.stackexchange.com/questions/64409/proper-use-of-cmap-and-mmap
With the dumb example provided above I have not noticed difference 
between cmap and \usepackage[noTeX]{mmap}. I am unsure when TeX commands 
may be preferred to Unicode characters as it works for default mmap 
configuration.

There is a chance that mmap is not installed in the system since it is 
provided by "extra" system package in Ubuntu:
texlive-latex-recommended: 
/usr/share/texlive/texmf-dist/tex/latex/cmap/cmap.sty
texlive-latex-extra: /usr/share/texlive/texmf-dist/tex/latex/mmap/mmap.sty
It should be possible to detect availability of mmap.sty in runtime 
using kpsewhich command.

So when I was writing that cmap is must have for me, I was not aware 
that nowadays PDF files generated from LaTeX source have mostly properly 
encoded text even without this package, in the past attempt to copy text 
resulted in some garbage.



      reply	other threads:[~2022-09-29 16:14 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-27  1:48 org exported pdf files Jude DaShiell
2022-09-27  2:48 ` Ihor Radchenko
2022-09-27  3:15   ` Jude DaShiell
2022-09-27  3:24     ` Ihor Radchenko
2022-09-27  4:31       ` Jude DaShiell
2022-09-27  4:58         ` Ihor Radchenko
2022-09-28  4:36           ` Jude DaShiell
2022-09-28  4:53             ` Timothy
2022-09-28  6:48               ` Jude DaShiell
2022-09-28  8:47                 ` Tim Cross
2022-09-28  9:19                   ` Timothy
2022-09-28 17:08                     ` Tim Cross
2022-09-28 17:39                       ` Timothy
2022-09-28 18:23                       ` Juan Manuel Macías
2022-09-29 20:58                         ` Tim Cross
2022-09-29  4:09                       ` Org HTML export accessibility (was: org exported pdf files) Ihor Radchenko
2022-09-29  8:22                         ` Tim Cross
2022-09-29 11:43                           ` Jude DaShiell
2022-09-29 21:05                           ` Apology [was: Re: Org HTML export accessibility (was: org exported pdf files)) Tim Cross
2022-09-30  5:34                             ` tomas
2022-10-02 10:59                             ` Apology [ Fraga, Eric
2022-10-02  9:42                           ` [HELP] Help implementing org-lint/warnings buffer during export (was: Org HTML export accessibility (was: org exported pdf files)) Ihor Radchenko
2022-10-02 20:52                             ` Tim Cross
2022-10-03  3:25                               ` Ihor Radchenko
2022-09-29  7:07                       ` org exported pdf files Max Nikulin
2022-09-29 21:00                         ` Tim Cross
2022-10-01 10:55                       ` Max Nikulin
2022-09-28 13:02                   ` Jude DaShiell
2022-09-28 16:12                 ` Max Nikulin
2022-09-27 11:08         ` Max Nikulin
2022-09-28  3:07           ` Ihor Radchenko
2022-09-28 15:58             ` Max Nikulin
2022-09-29  4:12               ` Add \usepackage{cmap} as default LaTeX class in ox-latex (was: org exported pdf files) Ihor Radchenko
2022-09-29 15:34                 ` Max Nikulin [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

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

  git send-email \
    --in-reply-to='th4dth$5df$1@ciao.gmane.io' \
    --to=manikulin@gmail.com \
    --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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.