typora / typora-issues

Bugs, suggestions or free discussions about the minimal markdown editor — Typora
https://typora.io
1.53k stars 58 forks source link

Invalid character inserted during PDF conversion #3290

Open rg-info opened 4 years ago

rg-info commented 4 years ago

Hi,

I notice an issue using Typora PDF export. I had the string "sp.filter" in my markdown that got replaced by "sp.filter" after exporting to PDF.

Looks pretty similar, but if you copy fi to a notepad, you will notice fi is singular character now (UTF-8: 0xEF 0xAC 0x81).

Regards.

jgclark commented 4 years ago

I would generally want to have this behaviour, as 'ligatures' like fi, fl, ffl, ffi are one of the features of better typography. Does this feature break something for you?

rg-info commented 4 years ago

Actually, yes it does. I sent a PDF version of one of my Markdown to give configuration instructions of a tool and the tool execution failed cause of misspelled filter string.

abnerlee commented 4 years ago

relates #889 #1871

Does add following CSS work?

body {
   font-variant-ligatures: no-common-ligatures;
}