From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/115154 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Nedeljkovic via ntg-context Newsgroups: gmane.comp.tex.context Subject: Re: Compiling a large metapost document Date: Thu, 2 Jun 2022 04:41:31 +0200 Message-ID: References: <1f166f27-61d9-e211-0239-b3f9591985de@telus.net> <86576d0a-1fa1-114a-7179-761e44834354@telus.net> Reply-To: mailing list for ConTeXt users Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============8076849646847198865==" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14623"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Stefan Nedeljkovic , mailing list for ConTeXt users To: Max Chernoff Original-X-From: ntg-context-bounces@ntg.nl Thu Jun 02 04:42:19 2022 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane-mx.org Original-Received: from zapf.boekplan.nl ([5.39.185.232] helo=zapf.ntg.nl) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nwamx-0003aj-1U for gctc-ntg-context-518@m.gmane-mx.org; Thu, 02 Jun 2022 04:42:19 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 8511928A1DE; Thu, 2 Jun 2022 04:41:51 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id uV6MeX7TO9kg; Thu, 2 Jun 2022 04:41:50 +0200 (CEST) Original-Received: from zapf.ntg.nl (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id E22C328A1EC; Thu, 2 Jun 2022 04:41:49 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id A7CB128A1EC for ; Thu, 2 Jun 2022 04:41:47 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id C5lD8eaozN2j for ; Thu, 2 Jun 2022 04:41:46 +0200 (CEST) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=209.85.219.49; helo=mail-qv1-f49.google.com; envelope-from=tsar.srb@gmail.com; receiver= Original-Received: from mail-qv1-f49.google.com (mail-qv1-f49.google.com [209.85.219.49]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id 9ED3B28A1DE for ; Thu, 2 Jun 2022 04:41:45 +0200 (CEST) Original-Received: by mail-qv1-f49.google.com with SMTP id b11so2780755qvv.4 for ; Wed, 01 Jun 2022 19:41:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=NUyZep15xAK0QMFhptCVw80gakQeyndnYKctxn/w4KQ=; b=eFM1UdkM2ZJvr8mmhoO0AT+3+Ab86j4X9QR4ysvLZdQ9+X7jOvn+KcaPxFCo/ehNn9 RTYFxfzR2OQ7SdMwhVqUGsL3ujGLDXHPkGQxmCAzeG2/3yxAIvtoowM865Om4V3tdz+Y 07yF6GTnJbfZfkbiNTRoCEKKkOB+SnHsGhnIFGu1gt/vvuxT1dce0rGEhSg2eL+hz7/M j4AjWVq+bLqLhsoEmt+S1PhCPQKVCU5X6aFj1YvHUGgG8aYcEpq+H9/LxgZNfT6uBCKU 8dLHgXk2qq5KFK2MxXipxRBCntj3zgXNbUxxY820cgvQSa7wpeHoyv6AKVLzftajsFMw BXgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=NUyZep15xAK0QMFhptCVw80gakQeyndnYKctxn/w4KQ=; b=Bobi5qI0T8Mwn5xTMxhtV7vJzpToa7eX9GfjN4GkpUNjPv/oLyrkhGw9TgzwDR3Lf3 4PqFTerA3Ws+FVW+gyQTzlLuzx44o5484hXSiGt+cmsA0WFK9atzyZaayS35EEJjRlx7 NB/DRhDav56+7rqK8ZpjM/xEQCGgJDOyOPvv9jNtbBk4D42gpUMjwXyEQfs+omJvwD+M 1cCPfEkC5nw8+RJb2AM3KZ2ZN7z6Pd3gBIUnS69Xlpatc9uYctV7cSvTDxO+keXOch+B Sa75Za0Uz7j5kndh7HPaVLnlQkoGrDT2c/e8P0S46DWNPJuxwyZ0xcOXWqJ29lrT3fTJ DwKw== X-Gm-Message-State: AOAM530o+Mlirad0sz6GEoxvxRG5VTbg1LKvdtA61x2/+XLjEgPGhVeg 4LFuP72kxYY82uqcXohvq4xpk7dDCDNq88Bspz8= X-Google-Smtp-Source: ABdhPJzje0XWf1WWksbp2qg5CexkBptjvIkgue6BNQVik/EsKDjGdpPkJNKTWbTsIk1FXeMbB9wJ3DPXSt/nUEzFDlI= X-Received: by 2002:a05:6214:5013:b0:464:5348:2ef3 with SMTP id jo19-20020a056214501300b0046453482ef3mr14378535qvb.69.1654137702447; Wed, 01 Jun 2022 19:41:42 -0700 (PDT) In-Reply-To: <86576d0a-1fa1-114a-7179-761e44834354@telus.net> X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.26 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: "ntg-context" Xref: news.gmane.io gmane.comp.tex.context:115154 Archived-At: --===============8076849646847198865== Content-Type: multipart/alternative; boundary="00000000000029fe4705e06df208" --00000000000029fe4705e06df208 Content-Type: text/plain; charset="UTF-8" There is one more problem: the pdf generated has incorrect margins. I tried to manually calculate the size in ps points and run gs directly, but the results are the same. How can I get an accurate rendering of the page? On Thu, Jun 2, 2022 at 4:22 AM Max Chernoff wrote: > On 2022-06-01 8:00 p.m., Stefan Nedeljkovic wrote: > > Thank you very much Max! It works indeed! One more question. How would I > > import the eps file back into MPpage, so I could do trickery with text. > > Convert the PostScript file into PDF with either "ps2pdf" or > GhostScript, then you can import the file with "externalfigure": > > \startMPpage > draw externalfigure "belgrade_gm.pdf"; > draw textext.top("One") shifted (264.352, 116.362); > draw textext.top("Two") shifted (306.821, 186.907); > \stopMPpage > > -- Max > --00000000000029fe4705e06df208 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
There is one more problem: the pdf generated has incorrect= margins. I tried to manually=C2=A0calculate the size in ps points and run = gs directly, but the results are the same. How can I get an accurate render= ing of the page?

On Thu, Jun 2, 2022 at 4:22 AM Max Chernoff <mseven@telus.net> wrote:
On 2022-06-01 8:00 p.m., Stefan Ne= deljkovic wrote:
> Thank you very much Max! It works indeed! One more question. How would= I
> import the eps file back into MPpage, so I could do trickery with text= .

Convert the PostScript file into PDF with either "ps2pdf" or
GhostScript, then you can import the file with "externalfigure":<= br>
=C2=A0 =C2=A0 =C2=A0\startMPpage
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0draw externalfigure "belgrade_gm.pdf= ";
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0draw textext.top("One") shifted= (264.352, 116.362);
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0draw textext.top("Two") shifted= (306.821, 186.907);
=C2=A0 =C2=A0 =C2=A0\stopMPpage

-- Max
--00000000000029fe4705e06df208-- --===============8076849646847198865== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly9jb250ZXh0LmFhbmhldC5uZXQKYXJjaGl2ZSAgOiBodHRwczovL2JpdGJ1Y2tldC5v cmcvcGhnL2NvbnRleHQtbWlycm9yL2NvbW1pdHMvCndpa2kgICAgIDogaHR0cDovL2NvbnRleHRn YXJkZW4ubmV0Cl9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fCg== --===============8076849646847198865==--