"∈" symbol of Pagella looks broken

If I select Pagella math font, the “∈” becomes this:

37%20PM

Any idea why? Thanks.

I get a normal ∈ in Pagella. Perhaps you could try “Tools -> Fonts -> Clear font cache”, then “Tools -> Fonts -> Look for more fonts” and restart TeXmacs.

I have, unfortunately that doesn’t fix it. I suspect that the pagella font is incomplete on my system, because when using other math fonts like math-enr, math environment uses math-enr’s italic letters, but when using math-pagella, I found that the italic letters in math environment is from my body text font, Charter. Do you know how I can inspect this? Thanks.

You could have a look at the file system/cache/font_cache.scm in your TEXMACS_HOME_PATH (which depends on your system, it’s ~/.TeXmacs for Linux). That should show you which file is detected for Pagella.

Strange, I found these four lines

"ttf:texgyrepagella-italic" "/Applications/TeXmacs.app/Contents/Resources/share/TeXmacs/fonts/truetype/texgyre/texgyrepagella-italic.otf"
"ttf:texgyrepagella-regular" "/Applications/TeXmacs.app/Contents/Resources/share/TeXmacs/fonts/truetype/texgyre/texgyrepagella-regular.otf"
"ttf:make_bbb[texgyrepagella-regular" ""
"ttf:texgyrepagella-math" "/Applications/TeXmacs.app/Contents/Resources/share/TeXmacs/fonts/truetype/texgyre/texgyrepagella-math.otf"

And in texgyrepagella-math.otf I am able to find the symbol:

57%20AM

Is there any way to inspect the font used for the character at point in TeXmacs? Like C-x = in Emacs?

It seems that this problem isn’t with Pagella, I tried Bonum and it couldn’t render the symbol correctly neither. If it matters, the code I used is

<assign|font|math=math-bonum,Charter>
<assign|font|math=math-pagella,Charter>

I forgot to add an important information: the screen rendering is fine, it is only the exported pdf that contains the broken symbol.

Screen rendering:

28%20AM

PDF:

I should also add that even if the screen rendering isn’t broken, it doesn’t seem to use the glyph from Pagella. The glyph in Pagella looks different:

57%20AM

Maybe it has something to do with ttf, since both Bonum and Pagella are from ttf files.

I can reproduce it in pdf with your code. I tried setting the math font via the menus and got something slightly different:

<assign|font|math=bonum,Charter>

Could you try this variant?

Yes, removing math- fixed it, now I feel stupid :-) Thanks a lot!

How did you get

<assign|font|math=bonum,Charter>

from changing font in menu? Is there like a hidden permeable section for a document or something?

You’re welcome!

In Document -> Font you can select the math font by pressing Advanced.... Once you have done that, you can extract the corresponding commands by doing Tools -> Macros -> Extract style file

I don’t see a Advanced... option in the font menu:

44%20PM

I’m using TeXmacs v2.1 for MacOS. Thanks for the extra style tip, that’s very useful!

Ah, yes, what you show is the same as what I meant.

If you choose the option Edit -> Preferences -> Complex actions: Through popup Windows, then you are presented with a popup for font selection, instead of the menu you show. There you get an Advanced button, but the effect should be the same as picking the math font in the way you do.

1 Like

Gosh, the pop up window is a so much better interface, thanks!