emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scaling of image produced for math in Info in the Emacs Info reader


From: Eli Zaretskii
Subject: Re: Scaling of image produced for math in Info in the Emacs Info reader
Date: Thu, 30 Jan 2025 10:03:18 +0200

> From: Björn Bidar <bjorn.bidar@thaodan.de>
> Cc: pertusus@free.fr,  emacs-devel@gnu.org
> Date: Thu, 30 Jan 2025 09:19:00 +0200
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > If you mean the Unicode characters from the symbols and mathematical
> > alphanumerics blocks, then does that really work for arbitrary
> > formulas?  The Unicode Standard has only a finite (somewhat small) set
> > of mathematical symbols, they are not enough to cover every possible
> > formula one might need?
> 
> I don't exactly but one way to try look into this is how does LaTeX do
> it when rendering  mathematical formulas to PDF. Not sure if rendering
> is the right here but I hope you get the point.
> 
> One example for rendering mathematical formulas in UTF-8 characters can
> be seen in the PDF linked on this site:
> https://www.cmor-faculty.rice.edu/~heinken/mh_links.html
> 
> List of (La)TeX Greek characters, Mathematical Symbols
> https://www.cmor-faculty.rice.edu/~heinken/latex/symbols.pdf
> 
> Section 10 shows a Latex mathematical completely made of characters.

LaTeX doesn't just use Unicode codepoints to display math, it uses 2D
layout to place various font glyphs around and above/below others.
Since makeinfo produces what is basically a text file, it would need
to include some non-trivial formatting control sequences to tell Emacs
how to render these character glyphs to show them on screen.  So just
using the corresponding codepoints does not solve the problem, because
Emacs will then show the corresponding glyphs linearly, one after the
other.

We could perhaps use character composition and HarfBuzz shaping to
produce the desired effect from a sequence of codepoints, but that
would mean only certain fonts are suitable for displaying Info manuals
with math (assuming there are such fonts out there, I don't know if
that's true), and makeinfo will need to know about those fonts and
their shaping capabilities when it generates Info files.  I'm not sure
this is a reasonable design.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]