Garbage copied from PDF when using certain fonts

2021-08-14 Thread Huanyu Liu via bug-lilypond
Hello LilyPond developers, When using certain fonts (in my case, Noto CJK, both pan-CJK and subset versions), the output looks right but when copied from the generated PDF file, everything becomes garbage. For example: \version "2.22.0" \markup {

Garbage copied from PDF when using certain fonts

2021-08-14 Thread Huanyu Liu via bug-lilypond
Hello LilyPond developers, When using certain fonts (in my case, Noto CJK, both pan-CJK and subset versions), the output looks right but when copied from the generated PDF file, everything becomes garbage. For example: \version "2.22.0" \markup {

Re: Garbage copied from PDF when using certain fonts

2021-08-14 Thread Huanyu Liu via bug-lilypond
Sorry, it seems that there are some bugs with my email client. It showed that the email delivery was failed, so I resent the mail. But actually it succeeded... And sorry for the terribly generated layout... ___ bug-lilypond mailing list bug-lilypond@gnu

Re: Garbage copied from PDF when using certain fonts

2021-08-14 Thread Werner LEMBERG
> When using certain fonts (in my case, Noto CJK, both pan-CJK and > subset versions), the output looks right but when copied from the > generated PDF file, everything becomes garbage. [...] Confirmed. > It seems to be all about CID. Maybe related to Issue #6058? Yes and no. The fix for #605

Re: Garbage copied from PDF when using certain fonts

2021-08-14 Thread Masamichi Hosoda
>> When using certain fonts (in my case, Noto CJK, both pan-CJK and >> subset versions), the output looks right but when copied from the >> generated PDF file, everything becomes garbage. [...] > > Confirmed. > >> It seems to be all about CID. Maybe related to Issue #6058? > > Yes and no. The

Re: Garbage copied from PDF when using certain fonts

2021-08-14 Thread Werner LEMBERG
>> AFAICS, to make copy and paste work for CID fonts it is necessary >> to add a ToUnicode map. We don't do that currently. [This is >> probably worth an entry in our issues database.] This is now issue #6162. https://gitlab.com/lilypond/lilypond/-/issues/6162 Werner _

Re: Garbage copied from PDF when using certain fonts

2021-08-15 Thread Knut Petersen
Hi Huanyu Liu, When using certain fonts (in my case, Noto CJK, both pan-CJK and subset versions), the output looks right but when copied from the generated PDF file, everything becomes garbage. For example: \version "2.22.0" \markup {   \override

Re: Garbage copied from PDF when using certain fonts

2021-08-16 Thread Huanyu Liu via bug-lilypond
Hi Knut, > Do you use a lilypond installer or do you build lilypond from source? Which > operating system do you use? I am using Ubuntu 21.10 and installed LilyPond from its repository (2.22.0-10). I also tried the latest stable (2.22.1-1) and development (2.23.3-1) installer from the LilyPond

Re: Garbage copied from PDF when using certain fonts

2021-08-16 Thread Werner LEMBERG
>> When using certain fonts (in my case, Noto CJK, both pan-CJK and >> subset versions), the output looks right but when copied from the >> generated PDF file, everything becomes garbage. [...] > > The problem does not appear if the cairo backend is used, see > https://gitlab.com/lilypond/lilypond

Re: Garbage copied from PDF when using certain fonts

2021-08-17 Thread Masamichi Hosoda
>>> When using certain fonts (in my case, Noto CJK, both pan-CJK and >>> subset versions), the output looks right but when copied from the >>> generated PDF file, everything becomes garbage. [...] >> >> The problem does not appear if the cairo backend is used, see >> https://gitlab.com/lilypond/li

Re: Garbage copied from PDF when using certain fonts

2021-08-20 Thread Werner LEMBERG
>>> The problem does not appear if the cairo backend is used, see >>> https://gitlab.com/lilypond/lilypond/-/merge_requests/853. >> >> This is good news! > > When copying and pasting from a PDF generated using cairo backend, > some characters turned into similar but different characters. The >

Re: Garbage copied from PDF when using certain fonts

2021-08-20 Thread Masamichi Hosoda
The problem does not appear if the cairo backend is used, see https://gitlab.com/lilypond/lilypond/-/merge_requests/853. >>> >>> This is good news! >> >> When copying and pasting from a PDF generated using cairo backend, >> some characters turned into similar but different characters.

Re: Garbage copied from PDF when using certain fonts

2021-08-21 Thread Werner LEMBERG
>> I've looked up the cairo bug tracker but couldn't find something >> related to copy-and-paste of CID-keyed fonts. Masamichi-san, could >> you submit an issue there so that this gets fixed eventually? I >> guess this would be beneficial for other projects, too. > > In my experiment, Cairo wit

Re: Garbage copied from PDF when using certain fonts

2021-09-04 Thread Masamichi Hosoda
>> In my experiment, Cairo without LilyPond does not generate garbled >> characters. It seems to be a LilyPond issue instead of a Cairo >> issue. Here's a python-cairo sample that works fine. [...] > > I can conform that this small script generates a PDF where > copy-and-paste works as expected