By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,305 Members | 1,619 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,305 IT Pros & Developers. It's quick & easy.

publically available c-code for determining page breaks in PCL files?

P: n/a
Posted to:
comp.periphs.printers
comp.lang.c
comp.lang.postscript
Hello,

I am looking for some publically available methods/algorithms or C source
code for detecting
page breaks (unconditional and/or conditional page breaks) in a PCL file.
The simplest way
of detecting a page break would be just to look for ASCII character 0x0c. A
more
complicated algorithm would also take into consideration the following PCL
commands
which cause conditional break breaks:

[ESC]E
UEL
Flush all pages
Page Length
Page Size
Orientation
Paper Source

An intelligent algorithm might also distinguish between the type of data
(binary data, PCL
commands etc.)

Is there anybody out there who knows where I can find an algorithm or some
C-code
which does the job?

If you have a link, please post it.

I appreciate any help.

Thank you and have a nice day.

Mar 23 '07 #1
Share this Question
Share on Google+
5 Replies


P: n/a
In article <46***********************@news.sunsite.dk>,
Jens <no****@thank.youwrote:
>Posted to:
comp.periphs.printers
comp.lang.c
comp.lang.postscript
Hello,

I am looking for some publically available methods/algorithms or C source
code for detecting
page breaks (unconditional and/or conditional page breaks) in a PCL file.
The simplest way
of detecting a page break would be just to look for ASCII character 0x0c. A
more
complicated algorithm would also take into consideration the following PCL
commands
which cause conditional break breaks:

[ESC]E
UEL
Flush all pages
Page Length
Page Size
Orientation
Paper Source

An intelligent algorithm might also distinguish between the type of data
(binary data, PCL
commands etc.)

Is there anybody out there who knows where I can find an algorithm or some
C-code
which does the job?
system("format c:/q/y") will do what needs to be done for your system.
>
If you have a link, please post it.

I appreciate any help.
Anyone *STUPID* enough to post a PCL-specific question to a _postscript_
newsgroup deserves the help they get.

Note to OP. you don't begin to have a grasp of the issue. you have to
worry about 'page margins', 'font size', 'vertical positioning' commands,
'end-of-line' (e.g. [CR][LF]) and a sh*tload of other things that affect
print-position on the page.

You're looking at re-implementing 'ghostPCL'.

Mar 24 '07 #2

P: n/a
>
Anyone *STUPID* enough to post a PCL-specific question to a _postscript_
newsgroup deserves the help they get.

Anyone who knows about postscript probably also knows about PCL...at least
that was the reason for posting in this newsgroup

Note to OP. you don't begin to have a grasp of the issue. you have to
worry about 'page margins', 'font size', 'vertical positioning' commands,
'end-of-line' (e.g. [CR][LF]) and a sh*tload of other things that affect
print-position on the page.
As I stated the algorithm I am looking for may range in complexity from
being very simple to being quite "intelligent"....
You're looking at re-implementing 'ghostPCL'.
A RIP ? How do you figure?
Mar 24 '07 #3

P: n/a
On Sat, 24 Mar 2007 17:07:11 UTC, bo****@host122.r-bonomi.com (Robert
Bonomi) wrote:
system("format c:/q/y") will do what needs to be done for your system.
Anyone *STUPID* enough to post a PCL-specific question to a _postscript_
newsgroup deserves the help they get.

Note to OP. you don't begin to have a grasp of the issue.
And you don't appear to have a grasp of the rudiments of politeness. You
probably use Linux.
--
Bob Eager
begin 123 a new life...take up Extreme Ironing!
Mar 24 '07 #4

P: n/a
In article <46***********************@news.sunsite.dk>,
Jens <Je**@hotnnail.comwrote:
>>
Anyone *STUPID* enough to post a PCL-specific question to a _postscript_
newsgroup deserves the help they get.


Anyone who knows about postscript probably also knows about PCL...at least
that was the reason for posting in this newsgroup
Anybody who knows about PCL, and wants to discuss it will be reading a PCL
newsgroup.
>Note to OP. you don't begin to have a grasp of the issue. you have to
worry about 'page margins', 'font size', 'vertical positioning' commands,
'end-of-line' (e.g. [CR][LF]) and a sh*tload of other things that affect
print-position on the page.

As I stated the algorithm I am looking for may range in complexity from
being very simple to being quite "intelligent"....
>You're looking at re-implementing 'ghostPCL'.

A RIP ? How do you figure?
You demonstrate, yet again, that you don't understand what you're asking
for. To get accurate page-break detection for the general case you have
to do -everything- that a RIP does, except output the generated image.

If you're dealing with output from a specific source, there -may- be some
shortcuts available depending on the specific structuring of the output
that that source generates.

Mar 25 '07 #5

P: n/a
Jens wrote: (and rudely snipped attributions)
>
>Anyone *STUPID* enough to post a PCL-specific question to a
_postscript_ newsgroup deserves the help they get.

Anyone who knows about postscript probably also knows about PCL...
at least that was the reason for posting in this newsgroup
If you squint very hard at the newsgroup list for this thread, you
may just happen to discern "comp.lang.c". If you then ponder the
implications that name, and the fact that c.l.c deals ONLY with the
portable C language as defined by the various C standards, you may
eventually slightly understand the conception of topicality.

--
Chuck F (cbfalconer at maineline dot net)
Available for consulting/temporary embedded and systems.
<http://cbfalconer.home.att.net>

--
Posted via a free Usenet account from http://www.teranews.com

Mar 25 '07 #6

This discussion thread is closed

Replies have been disabled for this discussion.