public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Re: FW: Can you offer enscript.cfg file for cygwin?
       [not found] <46DC955A66CED411B9D3000629A864B602CAB71F@rw-msg-03.broadvision.com>
@ 2002-04-17 23:25 ` Gerrit P. Haase
  2002-04-19  9:41   ` Dave McLaughlin
  0 siblings, 1 reply; 10+ messages in thread
From: Gerrit P. Haase @ 2002-04-17 23:25 UTC (permalink / raw)
  To: Ma, Xiangjiang; +Cc: cygwin

Hallo Xiangjiang,

> It is better, though I still could not make it print out
>  anything

Enscript uses 'lpr' from the cygutils package for printing
to PRN.

Printing under Cygwin was discussed a lot of times on this
list and there is a really good reason why 'lpr' is in the
cygutils package included.

Please search the archives, I'm sorry that I cannot tell you
some more right now, I will have to search the archives too
before I know why you cannot print;)


Gerrit
-- 
=^..^=
Please keep communication about Cygwin and Cygwin Aplications
on the Cygwin mailinglist.


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: FW: Can you offer enscript.cfg file for cygwin?
  2002-04-17 23:25 ` FW: Can you offer enscript.cfg file for cygwin? Gerrit P. Haase
@ 2002-04-19  9:41   ` Dave McLaughlin
  2002-04-19 11:13     ` lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?) Gerrit P. Haase
  2002-04-19 12:54     ` FW: Can you offer enscript.cfg file for cygwin? Charles Wilson
  0 siblings, 2 replies; 10+ messages in thread
From: Dave McLaughlin @ 2002-04-19  9:41 UTC (permalink / raw)
  To: cygwin

Like Xiangjiang, I am also stumped on how to configure the Cygwin 'lpr'
so that it can be used by enscript.  I searched the archives but didn't
succeed in finding anything that seemed to help.

Here are the messages I get:

lpr: can't open 'prn' for writing
lpr: The printer name is invalid.

If it helps any, the printer I want to use is on the network but
associated with lpt1 through an NT login script.  It is able to print
either PCL or PS.

TIA....

"Gerrit P. Haase" wrote:
> 
> Hallo Xiangjiang,
> 
> > It is better, though I still could not make it print out
> >  anything
> 
> Enscript uses 'lpr' from the cygutils package for printing
> to PRN.
> 
> Printing under Cygwin was discussed a lot of times on this
> list and there is a really good reason why 'lpr' is in the
> cygutils package included.
> 
> Please search the archives, I'm sorry that I cannot tell you
> some more right now, I will have to search the archives too
> before I know why you cannot print;)
> 
> Gerrit
> --
> =^..^=
> Please keep communication about Cygwin and Cygwin Aplications
> on the Cygwin mailinglist.
> 
> --
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> Bug reporting:         http://cygwin.com/bugs.html
> Documentation:         http://cygwin.com/docs.html
> FAQ:                   http://cygwin.com/faq/

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?)
  2002-04-19  9:41   ` Dave McLaughlin
@ 2002-04-19 11:13     ` Gerrit P. Haase
  2002-04-19 13:03       ` Charles Wilson
  2002-04-19 12:54     ` FW: Can you offer enscript.cfg file for cygwin? Charles Wilson
  1 sibling, 1 reply; 10+ messages in thread
From: Gerrit P. Haase @ 2002-04-19 11:13 UTC (permalink / raw)
  To: Dave McLaughlin; +Cc: cygwin

Dave schrieb:

> Like Xiangjiang, I am also stumped on how to configure the Cygwin 'lpr'
> so that it can be used by enscript.  I searched the archives but didn't
> succeed in finding anything that seemed to help.

> Here are the messages I get:

> lpr: can't open 'prn' for writing
> lpr: The printer name is invalid.

> If it helps any, the printer I want to use is on the network but
> associated with lpt1 through an NT login script.  It is able to print
> either PCL or PS.

I have also problems with printing through lpr.  Unfortunately I
couldn't figure out how to set it up correct yet.
There are some threads in the archives about printing without lpr,
maybe there are some hints?


Gerrit
-- 
=^..^=


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: FW: Can you offer enscript.cfg file for cygwin?
  2002-04-19  9:41   ` Dave McLaughlin
  2002-04-19 11:13     ` lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?) Gerrit P. Haase
@ 2002-04-19 12:54     ` Charles Wilson
  2002-05-02 15:00       ` Dave McLaughlin
  1 sibling, 1 reply; 10+ messages in thread
From: Charles Wilson @ 2002-04-19 12:54 UTC (permalink / raw)
  To: damcl, cygwin

Try this
$ export PRINTER=\\\\\\\\computer\\\\printername
(or maybe)
$ export PRINTER=\\\\computer\\printername

and then run enscript.

--Chuck


Dave McLaughlin wrote:

> Like Xiangjiang, I am also stumped on how to configure the Cygwin 'lpr'
> so that it can be used by enscript.  I searched the archives but didn't
> succeed in finding anything that seemed to help.
> 
> Here are the messages I get:
> 
> lpr: can't open 'prn' for writing
> lpr: The printer name is invalid.
> 
> If it helps any, the printer I want to use is on the network but
> associated with lpt1 through an NT login script.  It is able to print
> either PCL or PS.
> 
> TIA....



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?)
  2002-04-19 11:13     ` lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?) Gerrit P. Haase
@ 2002-04-19 13:03       ` Charles Wilson
  2002-04-21 13:28         ` Rick Rankin
  0 siblings, 1 reply; 10+ messages in thread
From: Charles Wilson @ 2002-04-19 13:03 UTC (permalink / raw)
  To: Gerrit P. Haase; +Cc: cygwin



> I have also problems with printing through lpr.  Unfortunately I
> couldn't figure out how to set it up correct yet.
> There are some threads in the archives about printing without lpr,
> maybe there are some hints?


See my message posted a few minutes ago.

Currently, lpr.exe from the cygutils package is not documented (at all), 
and it expects printer shares to be specified using backslash notation:

\\computer\share

of course, since those are backslashes, they have to be escaped:

\\\\computer\\share

and what's odd, is that sometimes they must be escaped twice


\\\\\\\\computer\\\\share

because two shells parse it.  It would be nice (tm) if someone wanted to 
contribute a man page, and perhaps some code to allow

a) specifying printer names with forward slashes (autodetect and 
automatically convert to backslashes before GetHandle'ing the printer)

b) figure out (and document) how to use local mount names (e.g. instead 
of \\bob\bigprinter, I've used the Add Printer Wizard and have added 
this remote printer to my local printer list as "My Friend Bob's Big 
Fancy Printer".

c) access to lpt1, lpt2, etc (although prn: seems to work already)

All together now....patches gratefully accepted.

--Chuck




--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?)
  2002-04-19 13:03       ` Charles Wilson
@ 2002-04-21 13:28         ` Rick Rankin
  2002-04-22  2:16           ` Gerrit P. Haase
  0 siblings, 1 reply; 10+ messages in thread
From: Rick Rankin @ 2002-04-21 13:28 UTC (permalink / raw)
  To: Charles Wilson, Gerrit P. Haase; +Cc: cygwin

I'll spend a little time and try to fix it up. Generally, lpr has worked for my
original intent, but when I wrote it, I never intended to publish it. I posted
the source a year or two ago in respose to someone's printing question, and was
very surprised when Chuck asked for permission to include it in cygutils.

I started down a path of adding some features to it a few months ago, then
found out that the Windows printer API didn't support what I was trying to do
in the way I was trying to do it. I was trying to add support for duplex
printing, different paper sizes, et. al., and found out that since lpr wasn't
actually rendering the page, but rather just dumping raw data formatted by
another program (e.g., enscript), I couldn't use those features if the Windows
printer interface. Instead, I would have to have a database of printer commands
for any printer I wanted to support and send the raw commands. I wasn't sure
that level of effort was worth persuing.

Anyway, I generally use a network printer by adding to my local list and giving
it a name such as HPLJ8000-PS, then set my PRINTER environment variable to that
value. So far, that has worked well for me.

As I said, I'll spend some time over the next few days and see if I can fix up
the code a bit and add support for using '/'s in network printer names. Who
knows, I may even generate a man page ;-)

Apparently, I've missed some past discussions of lpr. I'll peruse the mailing
list archives to see if I can find a list of other complaints or problems. If
anyone knows of other issues off the top of your head, send them to me and I'll
try to address them.

--Rick
--- Charles Wilson <cwilson@ece.gatech.edu> wrote:
> 
> 
> > I have also problems with printing through lpr.  Unfortunately I
> > couldn't figure out how to set it up correct yet.
> > There are some threads in the archives about printing without lpr,
> > maybe there are some hints?
> 
> 
> See my message posted a few minutes ago.
> 
> Currently, lpr.exe from the cygutils package is not documented (at all), 
> and it expects printer shares to be specified using backslash notation:
> 
> \\computer\share
> 
> of course, since those are backslashes, they have to be escaped:
> 
> \\\\computer\\share
> 
> and what's odd, is that sometimes they must be escaped twice
> 
> 
> \\\\\\\\computer\\\\share
> 
> because two shells parse it.  It would be nice (tm) if someone wanted to 
> contribute a man page, and perhaps some code to allow
> 
> a) specifying printer names with forward slashes (autodetect and 
> automatically convert to backslashes before GetHandle'ing the printer)
> 
> b) figure out (and document) how to use local mount names (e.g. instead 
> of \\bob\bigprinter, I've used the Add Printer Wizard and have added 
> this remote printer to my local printer list as "My Friend Bob's Big 
> Fancy Printer".
> 
> c) access to lpt1, lpt2, etc (although prn: seems to work already)
> 
> All together now....patches gratefully accepted.
> 
> --Chuck
> 
> 
> 
> 
> --
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> Bug reporting:         http://cygwin.com/bugs.html
> Documentation:         http://cygwin.com/docs.html
> FAQ:                   http://cygwin.com/faq/
> 


__________________________________________________
Do You Yahoo!?
Yahoo! Games - play chess, backgammon, pool and more
http://games.yahoo.com/

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?)
  2002-04-21 13:28         ` Rick Rankin
@ 2002-04-22  2:16           ` Gerrit P. Haase
  0 siblings, 0 replies; 10+ messages in thread
From: Gerrit P. Haase @ 2002-04-22  2:16 UTC (permalink / raw)
  To: Rick Rankin; +Cc: Charles Wilson, cygwin

Rick schrieb:

> Apparently, I've missed some past discussions of lpr. I'll peruse the mailing
> list archives to see if I can find a list of other complaints or problems. If
> anyone knows of other issues off the top of your head, send them to me and I'll
> try to address them.

Not much yet,  it came up because the enscript configure found the lpr
command at my box and decided to use it to write output to the printer.
Chuck already posted an example how it should work and I think it is
great that there is this way to get output to a printer.


Gerrit
-- 
=^..^=


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: FW: Can you offer enscript.cfg file for cygwin?
  2002-04-19 12:54     ` FW: Can you offer enscript.cfg file for cygwin? Charles Wilson
@ 2002-05-02 15:00       ` Dave McLaughlin
  0 siblings, 0 replies; 10+ messages in thread
From: Dave McLaughlin @ 2002-05-02 15:00 UTC (permalink / raw)
  To: cygwin

Thank you very much -- that did it for me.  I didn't try the first form,
but the second form worked just fine.  This enabled me to send my output
to a shared network printer.

Dave

Charles Wilson wrote:
> 
> Try this
> $ export PRINTER=\\\\\\\\computer\\\\printername
> (or maybe)
> $ export PRINTER=\\\\computer\\printername
> 
> and then run enscript.
> 
> --Chuck
> 
> Dave McLaughlin wrote:
> 
> > Like Xiangjiang, I am also stumped on how to configure the Cygwin 'lpr'
> > so that it can be used by enscript.  I searched the archives but didn't
> > succeed in finding anything that seemed to help.
> >
> > Here are the messages I get:
> >
> > lpr: can't open 'prn' for writing
> > lpr: The printer name is invalid.
> >
> > If it helps any, the printer I want to use is on the network but
> > associated with lpt1 through an NT login script.  It is able to print
> > either PCL or PS.
> >
> > TIA....
> 
> --
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> Bug reporting:         http://cygwin.com/bugs.html
> Documentation:         http://cygwin.com/docs.html
> FAQ:                   http://cygwin.com/faq/



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* RE: FW: Can you offer enscript.cfg file for cygwin?
@ 2002-04-20 15:38 Ma, Xiangjiang
  0 siblings, 0 replies; 10+ messages in thread
From: Ma, Xiangjiang @ 2002-04-20 15:38 UTC (permalink / raw)
  To: 'cwilson@ece.gatech.edu'; +Cc: cygwin, 'Gerrit P. Haase'

Charles,

I found your message on cygwin ( http://cygwin.com/ml/cygwin/ )
but could not reply there.  I followed your advisor and made my
enscript worked!!!

I added one line on my cshrc.csh
setenv PRINTER  \\\\RW-PRT-02\\HP5SI-2
and use the default /etc/enscript.cfg

The only trouble I have is that for every job I printed,
I received an extra page with such contents:

PostScript Error Handler
Offending Command =
Error = nametype :undefined
Stack =

Any idea?
How to escape such error message?


> > I have also problems with printing through lpr.  Unfortunately I
> > couldn't figure out how to set it up correct yet.
> > There are some threads in the archives about printing without lpr,
> > maybe there are some hints?
> See my message posted a few minutes ago.
> Currently, lpr.exe from the cygutils package is not documented (at all), 
> and it expects printer shares to be specified using backslash notation:
> \\computer\share
> of course, since those are backslashes, they have to be escaped:
> \\\\computer\\share

--
Xiangjiang Ma
BroadVision, Inc
(650)542-4665




> -----Original Message-----
> From: Gerrit P. Haase [mailto:gp@familiehaase.de]
> Sent: Wednesday, April 17, 2002 9:44 PM
> To: Ma, Xiangjiang
> Cc: cygwin@cygwin.com
> Subject: Re: FW: Can you offer enscript.cfg file for cygwin?
> 
> 
> Hallo Xiangjiang,
> 
> > It is better, though I still could not make it print out
> >  anything
> 
> Enscript uses 'lpr' from the cygutils package for printing
> to PRN.
> 
> Printing under Cygwin was discussed a lot of times on this
> list and there is a really good reason why 'lpr' is in the
> cygutils package included.
> 
> Please search the archives, I'm sorry that I cannot tell you
> some more right now, I will have to search the archives too
> before I know why you cannot print;)
> 
> 
> Gerrit
> -- 
> =^..^=
> Please keep communication about Cygwin and Cygwin Aplications
> on the Cygwin mailinglist.
> 

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: FW: Can you offer enscript.cfg file for cygwin?
       [not found] <46DC955A66CED411B9D3000629A864B602CAB71D@rw-msg-03.broadvision.com>
@ 2002-04-17 17:02 ` Gerrit P. Haase
  0 siblings, 0 replies; 10+ messages in thread
From: Gerrit P. Haase @ 2002-04-17 17:02 UTC (permalink / raw)
  To: Ma, Xiangjiang; +Cc: cygwin

Hallo Xiangjiang,

http://62.138.63.18/cywgin/enscript/enscript.cfg

Sorry, I saw it to late, a new release was already uploaded.


Gerrit
-- 
=^..^=


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2002-05-02 22:00 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <46DC955A66CED411B9D3000629A864B602CAB71F@rw-msg-03.broadvision.com>
2002-04-17 23:25 ` FW: Can you offer enscript.cfg file for cygwin? Gerrit P. Haase
2002-04-19  9:41   ` Dave McLaughlin
2002-04-19 11:13     ` lpr problem (was: Re: FW: Can you offer enscript.cfg file for cygwin?) Gerrit P. Haase
2002-04-19 13:03       ` Charles Wilson
2002-04-21 13:28         ` Rick Rankin
2002-04-22  2:16           ` Gerrit P. Haase
2002-04-19 12:54     ` FW: Can you offer enscript.cfg file for cygwin? Charles Wilson
2002-05-02 15:00       ` Dave McLaughlin
2002-04-20 15:38 Ma, Xiangjiang
     [not found] <46DC955A66CED411B9D3000629A864B602CAB71D@rw-msg-03.broadvision.com>
2002-04-17 17:02 ` Gerrit P. Haase

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 read-only IMAP folder(s) and NNTP newsgroup(s).