Re: xterm and right click and 'print window'

2005-06-09 Thread J. David Boyd
Igor Pechtchanski [EMAIL PROTECTED] wrote in
news:[EMAIL PROTECTED]: 

 On Wed, 8 Jun 2005, J. David Boyd wrote:
 
 Has anyone found a way to make this feature work, on any version of
 windows, with any printer?
 
 This works for me.  WinXP, networked printer.  As long as the PRINTER
 variable is exported.
 
 I've had no luck so far, and am grasping for clues.

 I've defined my $PRINTER as //quantex2/hplaserj, which prints okay
 from windows, but not cygwin.
 
 Open a regular bash window (no X), and type echo $PRINTER.  If that
 prints the correct thing, try bash -c 'echo $PRINTER'.  If that
 works too, type xterm -display 127.0.0.1:0, and from that xterm type
 echo $PRINTER.  If you see the correct printer in all 3 cases, the
 Print Window command should work (it does for me).
 
 Alternatively, since all xterm does is pipe stuff to lpr, does lpr -P
 //quantex2/hplaserj /etc/passwd print /etc/passwd to that printer
 (just to make sure lpr works)?
  Igor


All the variable expansion looks fine, so maybe it is an lpr problem.

When I try the command line 

lpr -P //quantex2/HPLaserJ /etc/passwd

I get the error printer name is invalid.

When I go back to what my profile set up, which is 
HP LaserJet 6P, I actually get output.  I was thinking all along 
that I couldn't use that name, but perhaps cygwin's lpr has been 
patched to use the windows resource name? 

I also noticed that nothing came out of the printer until I 
sent another file... 

And, are you setup for DOS endings or Unix?

So, I can print from the command line.  But, after closing my 
terms and opening some new ones (just to be sure I have the correct 
environment), and verifying that $PRINTER is still HP LaserJet 6P, 
I get nothing from 'Print window', and I don't see any errors.  
I wonder if there is a log somewhere that I can peruse. 

Anyway, thanks for the help. I guess I won't worry about it 
for now.  I can always do an Alt-PrtScn and paste it 
somewhere to print it. 

Dave



Re: xterm and right click and 'print window'

2005-06-09 Thread Igor Pechtchanski
On Thu, 9 Jun 2005, J. David Boyd wrote:

 Igor Pechtchanski [EMAIL PROTECTED] wrote:

http://cygwin.com/acronyms/#PCYMTNQREAIYR.  Thanks.

  On Wed, 8 Jun 2005, J. David Boyd wrote:
 
  Has anyone found a way to make this feature work, on any version of
  windows, with any printer?
 
  This works for me.  WinXP, networked printer.  As long as the PRINTER
  variable is exported.
 
  I've had no luck so far, and am grasping for clues.
 
  I've defined my $PRINTER as //quantex2/hplaserj, which prints okay
  from windows, but not cygwin.
 
  Open a regular bash window (no X), and type echo $PRINTER.  If that
  prints the correct thing, try bash -c 'echo $PRINTER'.  If that
  works too, type xterm -display 127.0.0.1:0, and from that xterm type
  echo $PRINTER.  If you see the correct printer in all 3 cases, the
  Print Window command should work (it does for me).
 
  Alternatively, since all xterm does is pipe stuff to lpr, does lpr -P
  //quantex2/hplaserj /etc/passwd print /etc/passwd to that printer
  (just to make sure lpr works)?
   Igor

 All the variable expansion looks fine, so maybe it is an lpr problem.

 When I try the command line

 lpr -P //quantex2/HPLaserJ /etc/passwd

 I get the error printer name is invalid.

 When I go back to what my profile set up, which is
 HP LaserJet 6P, I actually get output.  I was thinking all along
 that I couldn't use that name, but perhaps cygwin's lpr has been
 patched to use the windows resource name?

lpr interacts directly with the print spooler, so whatever name is used
for the printer in Windows, lpr will also use.

 I also noticed that nothing came out of the printer until I
 sent another file...

That may be because your driver needs to be set up to send a FF after each
job.  There may be an lpr option for that as well, not sure.

 And, are you setup for DOS endings or Unix?

Unix, of course.  But it doesn't matter for lpr -- it's all pipes anyway.

 So, I can print from the command line.  But, after closing my
 terms and opening some new ones (just to be sure I have the correct
 environment), and verifying that $PRINTER is still HP LaserJet 6P,
 I get nothing from 'Print window', and I don't see any errors.
 I wonder if there is a log somewhere that I can peruse.

If you start an xterm from a bash console window, all error messages from
that xterm go into the console window.  Otherwise, you can redirect the
stdout/stderr of the xterm to a file.

 Anyway, thanks for the help. I guess I won't worry about it
 for now.  I can always do an Alt-PrtScn and paste it
 somewhere to print it.

It would be interesting to find out why your config doesn't work.  Do you
have PRINTER set in the global Windows environment?  How do you start your
xterm?
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
 |,4-  ) )-,_. ,\ (  `'-'   Igor Pechtchanski, Ph.D.
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

The Sun will pass between the Earth and the Moon tonight for a total
Lunar eclipse... -- WCBS Radio Newsbrief, Oct 27 2004, 12:01 pm EDT


Re: xterm and right click and 'print window'

2005-06-09 Thread J. David Boyd
Igor Pechtchanski [EMAIL PROTECTED] wrote in
news:[EMAIL PROTECTED]: 

 On Thu, 9 Jun 2005, J. David Boyd wrote:
 
 Igor Pechtchanski [EMAIL PROTECTED] wrote:
 
http://cygwin.com/acronyms/#PCYMTNQREAIYR.  Thanks.
 
  On Wed, 8 Jun 2005, J. David Boyd wrote:
 
  Has anyone found a way to make this feature work, on any version
  of windows, with any printer?
 
  This works for me.  WinXP, networked printer.  As long as the
  PRINTER variable is exported.
 
  I've had no luck so far, and am grasping for clues.
 
  I've defined my $PRINTER as //quantex2/hplaserj, which prints okay
  from windows, but not cygwin.
 
  Open a regular bash window (no X), and type echo $PRINTER.  If
  that prints the correct thing, try bash -c 'echo $PRINTER'.  If
  that works too, type xterm -display 127.0.0.1:0, and from that
  xterm type echo $PRINTER.  If you see the correct printer in all
  3 cases, the Print Window command should work (it does for me).
 
  Alternatively, since all xterm does is pipe stuff to lpr, does lpr
  -P //quantex2/hplaserj /etc/passwd print /etc/passwd to that
  printer (just to make sure lpr works)?
   Igor

 All the variable expansion looks fine, so maybe it is an lpr problem.

 When I try the command line

 lpr -P //quantex2/HPLaserJ /etc/passwd

 I get the error printer name is invalid.

 When I go back to what my profile set up, which is
 HP LaserJet 6P, I actually get output.  I was thinking all along
 that I couldn't use that name, but perhaps cygwin's lpr has been
 patched to use the windows resource name?
 
 lpr interacts directly with the print spooler, so whatever name is
 used for the printer in Windows, lpr will also use.
 
 I also noticed that nothing came out of the printer until I
 sent another file...
 
 That may be because your driver needs to be set up to send a FF after
 each job.  There may be an lpr option for that as well, not sure.
 
 And, are you setup for DOS endings or Unix?
 
 Unix, of course.  But it doesn't matter for lpr -- it's all pipes
 anyway. 
 
 So, I can print from the command line.  But, after closing my
 terms and opening some new ones (just to be sure I have the correct
 environment), and verifying that $PRINTER is still HP LaserJet 6P,
 I get nothing from 'Print window', and I don't see any errors.
 I wonder if there is a log somewhere that I can peruse.
 
 If you start an xterm from a bash console window, all error messages
 from that xterm go into the console window.  Otherwise, you can
 redirect the stdout/stderr of the xterm to a file.
 
 Anyway, thanks for the help. I guess I won't worry about it
 for now.  I can always do an Alt-PrtScn and paste it
 somewhere to print it.
 
 It would be interesting to find out why your config doesn't work.  Do
 you have PRINTER set in the global Windows environment?  How do you
 start your xterm?
  Igor


I start my xterm from startxwin.bat.  Four of them.

I've tried defining PRINTER in startxwin.bat, but it seems to make no 
difference.

Oh well, I have to go to Oregon tomorrow morning for a week, so I'll look 
into this when I get back.

Thanks again,

Dave



xterm and right click and 'print window'

2005-06-08 Thread J. David Boyd
Has anyone found a way to make this feature work, on any version of 
windows, with any printer?  

I've had no luck so far, and am grasping for clues.

I've defined my $PRINTER as //quantex2/hplaserj, which prints okay 
from windows, but not cygwin.

Dave in Largo, FL




Re: xterm and right click and 'print window'

2005-06-08 Thread Igor Pechtchanski
On Wed, 8 Jun 2005, J. David Boyd wrote:

 Has anyone found a way to make this feature work, on any version of
 windows, with any printer?

This works for me.  WinXP, networked printer.  As long as the PRINTER
variable is exported.

 I've had no luck so far, and am grasping for clues.

 I've defined my $PRINTER as //quantex2/hplaserj, which prints okay
 from windows, but not cygwin.

Open a regular bash window (no X), and type echo $PRINTER.  If that
prints the correct thing, try bash -c 'echo $PRINTER'.  If that works
too, type xterm -display 127.0.0.1:0, and from that xterm type echo
$PRINTER.  If you see the correct printer in all 3 cases, the Print
Window command should work (it does for me).

Alternatively, since all xterm does is pipe stuff to lpr, does lpr -P
//quantex2/hplaserj /etc/passwd print /etc/passwd to that printer (just
to make sure lpr works)?
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
 |,4-  ) )-,_. ,\ (  `'-'   Igor Pechtchanski, Ph.D.
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

The Sun will pass between the Earth and the Moon tonight for a total
Lunar eclipse... -- WCBS Radio Newsbrief, Oct 27 2004, 12:01 pm EDT