ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <pragma@wxs.nl>
Cc: "Bruce Horrocks" <bh@granby.demon.co.uk>, ntg-context@ntg.nl
Subject: Re: Problem with bit maps with ConTeXt under MikTeX (works fine using LaTeX)
Date: Wed, 07 Nov 2001 18:04:29 +0100	[thread overview]
Message-ID: <5.1.0.14.1.20011107180028.02f98670@server-1> (raw)
In-Reply-To: <20011107164759.07627efc.taco@elvenkind.com>

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
-------------------------------------------------------------------------


  reply	other threads:[~2001-11-07 17:04 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-11-06 23:50 Bruce Horrocks
2001-11-07  8:29 ` Taco Hoekwater
2001-11-07 11:37   ` Bruce Horrocks
2001-11-07 15:47     ` Taco Hoekwater
2001-11-07 17:04       ` Hans Hagen [this message]
2001-11-07 23:17         ` Bruce Horrocks
2001-11-08  9:27           ` Hans Hagen
2001-11-08 14:59             ` Bruce Horrocks
2001-11-08 16:08               ` Taco Hoekwater
2001-11-08  8:18         ` Taco Hoekwater
2001-11-07 17:17   ` Hans Hagen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5.1.0.14.1.20011107180028.02f98670@server-1 \
    --to=pragma@wxs.nl \
    --cc=bh@granby.demon.co.uk \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).