ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <j.hagen@xs4all.nl>
To: Taco Hoekwater <taco@elvenkind.com>
Cc: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Minimum METAPOST code produces problematic PDF
Date: Thu, 9 Jul 2020 12:10:43 +0200	[thread overview]
Message-ID: <4d1e9138-6bca-987c-6ff1-f31270d15c56@xs4all.nl> (raw)
In-Reply-To: <FA33AC5F-7924-460A-9669-2E14687A0745@elvenkind.com>

On 7/9/2020 9:08 AM, Taco Hoekwater wrote:
> 
> 
>> On 9 Jul 2020, at 08:32, Hans Hagen <j.hagen@xs4all.nl> wrote:
>>
>> On 7/8/2020 8:14 PM, Gerben Wierda wrote:
>>> I found out this in the PDF spec:
>>> The minimum page size should be 3 by 3 units in default user space; the
>>
>> I never noticed that ... what section/paragraph in the spec?
> 
> It’s in the implementation limits for Acrobat, not in the normative section.

Great. That used to be 1 bp so now it's more. As it happens, we do have 
a check for this in context so we can adapt it ... but, as this 3 bp is 
kind of arbitrary and because 3 bp becomes a float and thereby ends up 
slightly less than the integer 3 we can best play safe and revert to the 
usual tex joke, so i now set the minumum to

   \luaexpr{math.pi}\onebasepoint

which then gives:

   /MediaBox [ 0 0 3.141539539 3.141539539 ] because after all, any 
rediculous minimum will do and that way a user can still figure out that 
it's a value set by context.

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
        tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

  parent reply	other threads:[~2020-07-09 10:10 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-07 22:49 Gerben Wierda
2020-07-07 23:08 ` Jairo A. del Rio
2020-07-08 18:14   ` Gerben Wierda
2020-07-09  6:32     ` Hans Hagen
     [not found]       ` <FA33AC5F-7924-460A-9669-2E14687A0745@elvenkind.com>
2020-07-09 10:10         ` Hans Hagen [this message]
2020-07-09 12:07           ` Gerben Wierda
2020-07-09  6:37     ` Aditya Mahajan
2020-07-11 12:22       ` Gerben Wierda

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=4d1e9138-6bca-987c-6ff1-f31270d15c56@xs4all.nl \
    --to=j.hagen@xs4all.nl \
    --cc=ntg-context@ntg.nl \
    --cc=taco@elvenkind.com \
    /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).