[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: PDF bookmarks and special insertions & characters
From: |
Gavin Smith |
Subject: |
Re: PDF bookmarks and special insertions & characters |
Date: |
Fri, 8 May 2020 20:10:42 +0100 |
User-agent: |
Mutt/1.9.4 (2018-02-28) |
On Fri, May 08, 2020 at 07:09:45PM +0200, Sebastian Urban wrote:
> Hello once again,
>
> I hope this is my last trouble, at least for few weeks. But, to the
> point.
>
> 1. In my "test" texi file there is a line:
> @chapter ``Some text'' and the rest of the @TeX{} text
>
> The point is, when I export file to PDF (texi2pdf --tidy test.texi,
> with @documentencoding UTF-8), the bookmark that is created (PDF
> bookmarks) has ``Some text'', while I was hoping for “Some text”
> (curved quotes).
>
> I can "fix" it like this:
> @chapter “Some text” ....
>
> ("fix" in this case means getting "Some text" in the bookmarks, which
> is at least ASCII style quoting convention, i.e. it's better)
>
> but is there any way to stick to the ``..'' convention?
It would have to be implemented. The problem is that the PDF format
uses UTF-16 internally for the bookmarks, so using curly quotes here is
quite difficult. Hence we are stuck with ASCII in the bookmarks. I
guess that " is better than `` but this may also be difficult to
implement. `` is a ligature in the fonts used that is a curvy double
quote but the PDF bookmarks are completely separate - you'd need to
change the two tokens `` to something else somehow.
> 2. Related to the previous, also about PDF bookmarks.
>
> It's about this @TeX{} special insertion in the line above. PDF
> bookmarks are showing me "... rest of the TeX{} text", while I was
> expecting "... rest of the TeX text" - I'm writing about ASCII TeX,
> not symbol/glyph.
>
> Again, I was able to fix it like this:
> @chapter ... rest of the @w{@TeX} text
>
> but HTML export ends with error, that says something about "expected {}".
I think I've fixed this problem in commit 4f92cb1.