* Scaling with \filterpages not working?
@ 2010-11-18 9:53 Procházka Lukáš Ing. - Pontex s. r. o.
2010-11-18 13:12 ` Peter Rolf
0 siblings, 1 reply; 7+ messages in thread
From: Procházka Lukáš Ing. - Pontex s. r. o. @ 2010-11-18 9:53 UTC (permalink / raw)
To: ConTeXt
[-- Attachment #1: Type: text/plain, Size: 700 bytes --]
Hello,
I'm trying similar code as described on http://wiki.contextgarden.net/Including_pages_from_PDF_document:
---
\starttext
\filterpages[1.pdf][2][width=15cm]
\page
\filterpages[1.pdf][2][width=5cm]
\stoptext
---
But I'm still getting the same picture - scaled to (probably) \textwidth.
Bug? My mistake?
So how to scale to paper width (or any arbitrary value)?
- ConTeXt ver: 2010.11.03 19:42 MKIV fmt: 2010.11.12 int: english/english (latest), WinXP
Lukas
--
Ing. Lukáš Procházka [mailto:LPr@pontex.cz]
Pontex s. r. o. [mailto:pontex@pontex.cz] [http://www.pontex.cz]
Bezová 1658
147 14 Praha 4
Tel: +420 244 062 238
Fax: +420 244 461 038
[-- Attachment #2: 1.pdf --]
[-- Type: application/pdf, Size: 10965 bytes --]
[-- Attachment #3: IncSc.mkiv --]
[-- Type: application/octet-stream, Size: 102 bytes --]
\starttext
\filterpages[1.pdf][2][width=15cm]
\page
\filterpages[1.pdf][2][width=5cm]
\stoptext
[-- Attachment #4: IncSc.pdf --]
[-- Type: application/pdf, Size: 11491 bytes --]
[-- Attachment #5: Type: text/plain, Size: 486 bytes --]
___________________________________________________________________________________
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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Scaling with \filterpages not working?
2010-11-18 9:53 Scaling with \filterpages not working? Procházka Lukáš Ing. - Pontex s. r. o.
@ 2010-11-18 13:12 ` Peter Rolf
2010-11-18 13:39 ` Peter Münster
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Peter Rolf @ 2010-11-18 13:12 UTC (permalink / raw)
To: ntg-context
Am 18.11.2010 10:53, schrieb Procházka Lukáš Ing. - Pontex s. r. o.:
> Hello,
>
> I'm trying similar code as described on
> http://wiki.contextgarden.net/Including_pages_from_PDF_document:
>
> ---
> \starttext
> \filterpages[1.pdf][2][width=15cm]
> \page
> \filterpages[1.pdf][2][width=5cm]
> \stoptext
> ---
>
> But I'm still getting the same picture - scaled to (probably) \textwidth.
>
> Bug? My mistake?
>
Only the horizontal shift of \copypages looks fishy (as all other values
seem to fit).
> So how to scale to paper width (or any arbitrary value)?
>
maybe
\definelayout[fullpage]
[height=\paperheight,
width=\paperwidth,
header=0mm,
footer=0mm,
margin=0mm,
topspace=0mm,
bottomspace=0mm,
backspace=0mm,
]
\starttext
\showframe
AAA\page
\setuplayout[fullpage]
\copypages[1.pdf]
\setuplayout[reset]
\page
BBB
\stoptext
Best wishes, Peter
> - ConTeXt ver: 2010.11.03 19:42 MKIV fmt: 2010.11.12 int:
> english/english (latest), WinXP
>
> Lukas
>
>
>
>
> ___________________________________________________________________________________
> 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://tex.aanhet.net
> archive : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___________________________________________________________________________________
___________________________________________________________________________________
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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Scaling with \filterpages not working?
2010-11-18 13:12 ` Peter Rolf
@ 2010-11-18 13:39 ` Peter Münster
2010-11-18 14:56 ` Procházka Lukáš Ing. - Pontex s. r. o.
2010-11-19 20:44 ` Hans Hagen
2 siblings, 0 replies; 7+ messages in thread
From: Peter Münster @ 2010-11-18 13:39 UTC (permalink / raw)
To: mailing list for ConTeXt users
On Thu, Nov 18 2010, Peter Rolf wrote:
> \setuplayout[fullpage]
"fullpage" is not needed. There is already \setuplayout[page].
Cheers, Peter
--
Contact information: http://pmrb.free.fr/contact/
___________________________________________________________________________________
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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Scaling with \filterpages not working?
2010-11-18 13:12 ` Peter Rolf
2010-11-18 13:39 ` Peter Münster
@ 2010-11-18 14:56 ` Procházka Lukáš Ing. - Pontex s. r. o.
2010-11-19 20:44 ` Hans Hagen
2 siblings, 0 replies; 7+ messages in thread
From: Procházka Lukáš Ing. - Pontex s. r. o. @ 2010-11-18 14:56 UTC (permalink / raw)
To: mailing list for ConTeXt users
Thank you, this works nicely.
Lukas
On Thu, 18 Nov 2010 14:12:36 +0100, Peter Rolf <indiego@gmx.net> wrote:
> Am 18.11.2010 10:53, schrieb Procházka Lukáš Ing. - Pontex s. r. o.:
>> Hello,
>>
>> I'm trying similar code as described on
>> http://wiki.contextgarden.net/Including_pages_from_PDF_document:
>>
>> ---
>> \starttext
>> \filterpages[1.pdf][2][width=15cm]
>> \page
>> \filterpages[1.pdf][2][width=5cm]
>> \stoptext
>> ---
>>
>> But I'm still getting the same picture - scaled to (probably) \textwidth.
>>
>> Bug? My mistake?
>>
> Only the horizontal shift of \copypages looks fishy (as all other values
> seem to fit).
>
>> So how to scale to paper width (or any arbitrary value)?
>>
> maybe
>
>
> \definelayout[fullpage]
> [height=\paperheight,
> width=\paperwidth,
> header=0mm,
> footer=0mm,
> margin=0mm,
> topspace=0mm,
> bottomspace=0mm,
> backspace=0mm,
> ]
>
>
> \starttext
> \showframe
> AAA\page
> \setuplayout[fullpage]
> \copypages[1.pdf]
> \setuplayout[reset]
> \page
> BBB
> \stoptext
>
>
>
> Best wishes, Peter
--
Ing. Lukáš Procházka [mailto:LPr@pontex.cz]
Pontex s. r. o. [mailto:pontex@pontex.cz] [http://www.pontex.cz]
Bezová 1658
147 14 Praha 4
Tel: +420 244 062 238
Fax: +420 244 461 038
___________________________________________________________________________________
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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Scaling with \filterpages not working?
2010-11-18 13:12 ` Peter Rolf
2010-11-18 13:39 ` Peter Münster
2010-11-18 14:56 ` Procházka Lukáš Ing. - Pontex s. r. o.
@ 2010-11-19 20:44 ` Hans Hagen
2010-11-20 12:37 ` Procházka Lukáš
2 siblings, 1 reply; 7+ messages in thread
From: Hans Hagen @ 2010-11-19 20:44 UTC (permalink / raw)
To: mailing list for ConTeXt users
On 18-11-2010 2:12, Peter Rolf wrote:
> Am 18.11.2010 10:53, schrieb Procházka Lukáš Ing. - Pontex s. r. o.:
>> Hello,
>>
>> I'm trying similar code as described on
>> http://wiki.contextgarden.net/Including_pages_from_PDF_document:
>>
>> ---
>> \starttext
>> \filterpages[1.pdf][2][width=15cm]
>> \page
>> \filterpages[1.pdf][2][width=5cm]
>> \stoptext
>> ---
commands like \filterpages are for special purposes (and will probably
move to modules), you probably want:
\starttext
\externalfigure[1.pdf][page=2,width=15cm]
\page
\externalfigure[1.pdf][page=2,width=5cm]
\stoptext
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| 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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Scaling with \filterpages not working?
2010-11-19 20:44 ` Hans Hagen
@ 2010-11-20 12:37 ` Procházka Lukáš
2010-11-20 13:29 ` Hans Hagen
0 siblings, 1 reply; 7+ messages in thread
From: Procházka Lukáš @ 2010-11-20 12:37 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1: Type: text/plain, Size: 2063 bytes --]
Thanks all for the answers.
The solution by both Peters works well:
---
\starttext
\filterpages[1.pdf][1:2]
\page
\setuplayout[page]
\filterpages[1.pdf][1:2]
\setuplayout[reset]
\page
\stoptext
---
To Hans:
I really needed to filter out some pages.
(In this case, I wanted to use pages 1-2 from a pdf which has exactly 2 pages, but it won't happen in general - this was only a special sample case.)
My task IN GENERAL is - let's have a pdf of a scanned document. Let it have e.g. 20 pages. And I need to insert pages 1-10 at one place and 16-20 at another place (scanned pages 11-15 won't be used).
These pages are to be placed UNSCALED to the document. So:
- I can't use \externalfigure as it places just ONE specific page to the document.
- I can't use \insertpages as I can determine only the NUMBER of pages to include, but not the FIRST page (see the "n=..." option).
- I can't use \copypages for the same reason as \insertpages.
- So the one possibility is to use \filterpages as it offers possibility to select exact pages or their ranges.
The initial problem was that \filterpages scales inserted pages to \textwidth so I tried to play with the "width" option. And the "width" option works - how exactly? (See the previous trials.)
Best regards,
Lukas
On Fri, 19 Nov 2010 21:44:16 +0100, Hans Hagen <pragma@wxs.nl> wrote:
> On 18-11-2010 2:12, Peter Rolf wrote:
>> Am 18.11.2010 10:53, schrieb Procházka Lukáš Ing. - Pontex s. r. o.:
>>> Hello,
>>>
>>> I'm trying similar code as described on
>>> http://wiki.contextgarden.net/Including_pages_from_PDF_document:
>>>
>>> ---
>>> \starttext
>>> \filterpages[1.pdf][2][width=15cm]
>>> \page
>>> \filterpages[1.pdf][2][width=5cm]
>>> \stoptext
>>> ---
>
> commands like \filterpages are for special purposes (and will probably
> move to modules), you probably want:
>
> \starttext
> \externalfigure[1.pdf][page=2,width=15cm]
> \page
> \externalfigure[1.pdf][page=2,width=5cm]
> \stoptext
[-- Attachment #2: 1.pdf --]
[-- Type: application/pdf, Size: 10965 bytes --]
[-- Attachment #3: IncSc3.mkiv --]
[-- Type: application/octet-stream, Size: 148 bytes --]
%\showframe
\starttext
\filterpages[1.pdf][1:2]
\page
\setuplayout[page]
\filterpages[1.pdf][1:2]
\setuplayout[reset]
\page
\stoptext
[-- Attachment #4: Type: text/plain, Size: 486 bytes --]
___________________________________________________________________________________
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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Scaling with \filterpages not working?
2010-11-20 12:37 ` Procházka Lukáš
@ 2010-11-20 13:29 ` Hans Hagen
0 siblings, 0 replies; 7+ messages in thread
From: Hans Hagen @ 2010-11-20 13:29 UTC (permalink / raw)
To: mailing list for ConTeXt users
On 20-11-2010 1:37, Procházka Lukáš wrote:
> - I can't use \externalfigure as it places just ONE specific page to the
> document.
\dostepwiserecurse{3}{5{1}{
\startTEXpage
\externalfigure[whatever.pdf][page=\recurselevel]
\stopTEXpage
}
----------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
| 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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2010-11-20 13:29 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-18 9:53 Scaling with \filterpages not working? Procházka Lukáš Ing. - Pontex s. r. o.
2010-11-18 13:12 ` Peter Rolf
2010-11-18 13:39 ` Peter Münster
2010-11-18 14:56 ` Procházka Lukáš Ing. - Pontex s. r. o.
2010-11-19 20:44 ` Hans Hagen
2010-11-20 12:37 ` Procházka Lukáš
2010-11-20 13:29 ` Hans Hagen
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).