From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/6021 Path: main.gmane.org!not-for-mail From: Hans Hagen Newsgroups: gmane.comp.tex.context Subject: Re: Problem with bit maps with ConTeXt under MikTeX (works fine using LaTeX) Date: Wed, 07 Nov 2001 18:04:29 +0100 Sender: owner-ntg-context@let.uu.nl Message-ID: <5.1.0.14.1.20011107180028.02f98670@server-1> References: <20011107092947.0c79bdd4.taco@elvenkind.com> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Trace: main.gmane.org 1035396573 6641 80.91.224.250 (23 Oct 2002 18:09:33 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2002 18:09:33 +0000 (UTC) Cc: "Bruce Horrocks" , ntg-context@ntg.nl Original-To: Taco Hoekwater In-Reply-To: <20011107164759.07627efc.taco@elvenkind.com> Xref: main.gmane.org gmane.comp.tex.context:6021 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:6021 At 04:47 PM 11/7/2001 +0100, Taco Hoekwater wrote: >Hi, > > > I want to use something that Yap can display because of the improved > > edit cycle with its support for forward and reverse lookups. What I want >Right, I see. Available paths using context: > >1) use png file and texexec --pdf, preview in acroread > >2) you can try my (very ugly, more like a proof of concept) hack with bmp >files and yap: > >%% start of file >\unprotect >\definefileinsertion{tr}{bmp}#1#2#3#4#5#6#7#8#9% > {\scratchdimen\@@efbreedte > \ScaledPointsToWholeBigPoints{\number\scratchdimen}\width > \scratchdimen\@@efhoogte > \ScaledPointsToWholeBigPoints{\number\scratchdimen}\height > \vbox to 0pt{\kern -\@@efhoogte\hbox{% > \ifnum\height = 0 > \ifnum\width = 0 \special{em: graph #1}% > \else \special{em: graph #1,\width bp}% > \fi > \else > \special{em: graph #1,\width bp,\height bp}% > \fi% > }\vss}} >\protect I cannot test this here -) #7 and #8 are the dimensions in bp, so this is a better way: >\definefileinsertion{tr}{bmp}#1#2#3#4#5#6#7#8#9% > {\ScaledPointsToWholeBigPoints{#7}\width > \ScaledPointsToWholeBigPoints{#8}\height > \vbox to 0pt{\kern -#8sp\hbox{% > \ifnum\height = 0 > \ifnum\width = 0 \special{em: graph #1}% > \else \special{em: graph #1,#7sp}% > \fi > \else > \special{em: graph #1,\width bp,\height bp}% > \fi% > }\vss}} do we need a special yap driver ? Hans is better, btw, in context all graphics are included at natural size and scaled in the figure placement macros; has to do with object reuse Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com -------------------------------------------------------------------------