From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/34324 Path: news.gmane.org!not-for-mail From: "Zhichu Chen" Newsgroups: gmane.comp.tex.context Subject: Re: \pdfannot and \tooltip won't work with Chinese characters Date: Wed, 18 Apr 2007 08:41:16 +0800 Message-ID: <769ba7780704171741l42a959bbp62b4c43cf4ea9834@mail.gmail.com> References: <769ba7780704102151j32030d30v9282e3bd9fd91d12@mail.gmail.com> <769ba7780704122324p797ac6f7qed0da9ceb8ba26cb@mail.gmail.com> <4624B00E.8050103@wxs.nl> <769ba7780704170552q23c2872ahb263c8b7852777db@mail.gmail.com> <4624C57B.7070502@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1944342977==" X-Trace: sea.gmane.org 1176856911 10358 80.91.229.12 (18 Apr 2007 00:41:51 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 18 Apr 2007 00:41:51 +0000 (UTC) To: "mailing list for ConTeXt users" Original-X-From: ntg-context-bounces@ntg.nl Wed Apr 18 02:41:43 2007 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1HdyEu-0003UD-F9 for gctc-ntg-context-518@m.gmane.org; Wed, 18 Apr 2007 02:41:40 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id AC7B12022E; Wed, 18 Apr 2007 02:41:39 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 19132-07-6; Wed, 18 Apr 2007 02:41:28 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 73B3520207; Wed, 18 Apr 2007 02:41:28 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 626D920207 for ; Wed, 18 Apr 2007 02:41:25 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 19132-07-5 for ; Wed, 18 Apr 2007 02:41:21 +0200 (CEST) Original-Received: from nz-out-0506.google.com (nz-out-0506.google.com [64.233.162.230]) by ronja.ntg.nl (Postfix) with ESMTP id A0903201FF for ; Wed, 18 Apr 2007 02:41:20 +0200 (CEST) Original-Received: by nz-out-0506.google.com with SMTP id n1so1574032nzf for ; Tue, 17 Apr 2007 17:41:17 -0700 (PDT) Original-Received: by 10.114.157.1 with SMTP id f1mr2670812wae.1176856876710; Tue, 17 Apr 2007 17:41:16 -0700 (PDT) Original-Received: by 10.114.103.11 with HTTP; Tue, 17 Apr 2007 17:41:16 -0700 (PDT) In-Reply-To: <4624C57B.7070502@wxs.nl> X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:34324 Archived-At: --===============1944342977== Content-Type: multipart/alternative; boundary="----=_Part_86626_26539322.1176856876662" ------=_Part_86626_26539322.1176856876662 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi, Hans It may be useless, but I really hope I can pass some options to the comment. e.g., use \comment[color=blue][title]{some contents} will make "some contents" blue. So I think we can use /RC instead of /Contents. On 4/17/07, Hans Hagen wrote: > > Zhichu Chen wrote: > > Thanks Hans, > > > > It works. But only the /Contents part was converted correctly, the /T > > part > > is still not so good. So I redefined your \doPDFinsertcomment macro and > > changed the third line from > > ======================== > > \doifelsenothing{#1} > > {\let\PDFidentifier\empty} > > {\def\PDFidentifier{/T (#1)}}% > > ======================== > > to > > ======================== > > \doifelsenothing{#1} > > {\let\PDFidentifier\empty} > > {\sanitizePDFencoding#1\to\PDFcommenttitle\def\PDFidentifier{/T > > \ifPDFunicode <\PDFcommenttitle>\else (\PDFcommenttitle)\fi}}% > > ======================== > > > > Now it's OK for me. I hope there's a more clever way that I don't need > to > > copy such long codes to my source file. > just patch spec-fdf > > i changed it here so it will be in the next release > > (which reminds me that for luatex i need to make a driver file dealing > with such issues) > > Hans > > ----------------------------------------------------------------- > Hans Hagen | PRAGMA ADE > Ridderstraat 27 | 8061 GH Hasselt | The Netherlands > tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com > | www.pragma-pod.nl > ----------------------------------------------------------------- > > _______________________________________________ > ntg-context mailing list > ntg-context@ntg.nl > http://www.ntg.nl/mailman/listinfo/ntg-context > -- Sincerely yours, Chen ---------------------------------------------------------------- Zhi-chu Chen | Shanghai Synchrotron Radiation Facility No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China tel: 086 21 5955 3405 | zhichu.chen.googlepages.com | www.sinap.ac.cn ---------------------------------------------------------------- ------=_Part_86626_26539322.1176856876662 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline
Hi, Hans
 
It may be useless, but I really hope I can pass some options to the comment. e.g., use \comment[color=blue][title]{some contents} will make "some contents" blue. So I think we can use /RC instead of /Contents.

 
On 4/17/07, Hans Hagen <pragma@wxs.nl> wrote:
Zhichu Chen wrote:
> Thanks Hans,
>
> It works. But only the /Contents part was converted correctly, the /T
> part
> is still not so good. So I redefined your \doPDFinsertcomment macro and
> changed the third line from
> ========================
>   \doifelsenothing{#1}
>     {\let\PDFidentifier\empty}
>     {\def\PDFidentifier{/T (#1)}}%
> ========================
> to
> ========================
>   \doifelsenothing{#1}
>     {\let\PDFidentifier\empty}
>     {\sanitizePDFencoding#1\to\PDFcommenttitle\def\PDFidentifier{/T
> \ifPDFunicode <\PDFcommenttitle>\else (\PDFcommenttitle)\fi}}%
> ========================
>
> Now it's OK for me. I hope there's a more clever way that I don't need to
> copy such long codes to my source file.
just patch spec-fdf

i changed it here so it will be in the next release

(which reminds me that for luatex i need to make a driver file dealing with such issues)

Hans

-----------------------------------------------------------------
                                         Hans Hagen | PRAGMA ADE
             Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
    tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                            | www.pragma-pod.nl
-----------------------------------------------------------------

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context



--
Sincerely yours,
Chen
----------------------------------------------------------------

          Zhi-chu Chen | Shanghai Synchrotron Radiation Facility
         No. 2019 | Jialuo Rd. | Jiading | Shanghai | P.R. China
             tel: 086 21 5955 3405 | zhichu.chen.googlepages.com
                                               | www.sinap.ac.cn
---------------------------------------------------------------- ------=_Part_86626_26539322.1176856876662-- --===============1944342977== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context --===============1944342977==--