* glitch when printing from Win 7
@ 2013-06-02 20:12 zeb7k
2013-06-03 2:38 ` Eli Zaretskii
` (2 more replies)
0 siblings, 3 replies; 9+ messages in thread
From: zeb7k @ 2013-06-02 20:12 UTC (permalink / raw)
To: help-gnu-emacs
When in Windows 7 I often use the print-region command from EMACS (23.2.1) to send text to the printer. My lpr-command is the name of simple .bat file I use which simply accepts the temp file name that EMACS passes it and tells NotePad.exe to print it.
Well, under conditions I cannot fathom, the name that EMACS passes has some weird escape character at its beginning. This happens about 5% of the times I try to print. Once it does happen, it happens consistently. I end up having to print manually: running NotePad, yanking from EMACS, pasting into NotePad and printing from the NotePad menu. The next day, the problem is gone. Kind of annoying. Any ideas?
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: glitch when printing from Win 7
2013-06-02 20:12 glitch when printing from Win 7 zeb7k
@ 2013-06-03 2:38 ` Eli Zaretskii
[not found] ` <mailman.904.1370227127.22516.help-gnu-emacs@gnu.org>
2013-07-11 11:12 ` zeb7k
2 siblings, 0 replies; 9+ messages in thread
From: Eli Zaretskii @ 2013-06-03 2:38 UTC (permalink / raw)
To: help-gnu-emacs
> Date: Sun, 2 Jun 2013 13:12:29 -0700 (PDT)
> From: zeb7k@hotmail.com
> Injection-Date: Sun, 02 Jun 2013 20:12:29 +0000
>
> When in Windows 7 I often use the print-region command from EMACS (23.2.1) to send text to the printer. My lpr-command is the name of simple .bat file I use which simply accepts the temp file name that EMACS passes it and tells NotePad.exe to print it.
>
> Well, under conditions I cannot fathom, the name that EMACS passes has some weird escape character at its beginning. This happens about 5% of the times I try to print. Once it does happen, it happens consistently. I end up having to print manually: running NotePad, yanking from EMACS, pasting into NotePad and printing from the NotePad menu. The next day, the problem is gone. Kind of annoying. Any ideas?
Show us the "weird escape character" you get. Is it the same
character every time?
^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <mailman.904.1370227127.22516.help-gnu-emacs@gnu.org>]
* Re: glitch when printing from Win 7
2013-06-02 20:12 glitch when printing from Win 7 zeb7k
2013-06-03 2:38 ` Eli Zaretskii
[not found] ` <mailman.904.1370227127.22516.help-gnu-emacs@gnu.org>
@ 2013-07-11 11:12 ` zeb7k
2013-07-11 17:02 ` Eli Zaretskii
[not found] ` <mailman.843.1373562166.12400.help-gnu-emacs@gnu.org>
2 siblings, 2 replies; 9+ messages in thread
From: zeb7k @ 2013-07-11 11:12 UTC (permalink / raw)
To: help-gnu-emacs
It finally happened again.
Here are the pertinent commands in my .EMACS startup file:
(setq lpr-command "P:/PrintFile/PrintFile.bat")
(setq printer-name nil)
(setq lpr-headers-switches "/p")
Here is the batch file PrintFile.bat:
echo appdrive is %APPDRIVE% > x:\PrintTrace.log
echo 1 is %1 >> x:\PrintTrace.log
echo 2 is %2 >> x:\PrintTrace.log
regedit.exe /s %APPDRIVE%:\PrintFile\NotePad.reg
NotePad.exe %1 %2
(Sometimes I adjust the font in Notepad and forget to switch it back. The regedit command simply makes sure Notepad.exe is working with the same font size I always use for printing.)
Here is the contents of PrintTrace.log as viewed in fundamental mode:
appdrive is P
1 is /p
2 is \213\257\250t:\Temp\EP4252h0o
Note the three octal characters in front of the file name. This is what's gumming things up. Why is this happening?
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: glitch when printing from Win 7
2013-07-11 11:12 ` zeb7k
@ 2013-07-11 17:02 ` Eli Zaretskii
[not found] ` <mailman.843.1373562166.12400.help-gnu-emacs@gnu.org>
1 sibling, 0 replies; 9+ messages in thread
From: Eli Zaretskii @ 2013-07-11 17:02 UTC (permalink / raw)
To: help-gnu-emacs
> Date: Thu, 11 Jul 2013 04:12:25 -0700 (PDT)
> From: zeb7k@hotmail.com
>
> Here are the pertinent commands in my .EMACS startup file:
>
> (setq lpr-command "P:/PrintFile/PrintFile.bat")
> (setq printer-name nil)
> (setq lpr-headers-switches "/p")
>
> Here is the batch file PrintFile.bat:
>
> echo appdrive is %APPDRIVE% > x:\PrintTrace.log
> echo 1 is %1 >> x:\PrintTrace.log
> echo 2 is %2 >> x:\PrintTrace.log
> regedit.exe /s %APPDRIVE%:\PrintFile\NotePad.reg
> NotePad.exe %1 %2
>
> (Sometimes I adjust the font in Notepad and forget to switch it back. The regedit command simply makes sure Notepad.exe is working with the same font size I always use for printing.)
>
> Here is the contents of PrintTrace.log as viewed in fundamental mode:
>
> appdrive is P
> 1 is /p
> 2 is \213\257\250t:\Temp\EP4252h0o
>
> Note the three octal characters in front of the file name. This is what's gumming things up. Why is this happening?
Which version of Emacs is that? And what is the value of
buffer-file-coding-system in the buffer which you tried to print?
^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <mailman.843.1373562166.12400.help-gnu-emacs@gnu.org>]
end of thread, other threads:[~2013-07-11 21:12 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-02 20:12 glitch when printing from Win 7 zeb7k
2013-06-03 2:38 ` Eli Zaretskii
[not found] ` <mailman.904.1370227127.22516.help-gnu-emacs@gnu.org>
2013-06-03 10:05 ` zeb7k
2013-06-04 13:41 ` Kevin Rodgers
2013-07-11 11:12 ` zeb7k
2013-07-11 17:02 ` Eli Zaretskii
[not found] ` <mailman.843.1373562166.12400.help-gnu-emacs@gnu.org>
2013-07-11 17:33 ` zeb7k
2013-07-11 18:21 ` Eli Zaretskii
[not found] ` <mailman.858.1373567307.12400.help-gnu-emacs@gnu.org>
2013-07-11 21:12 ` zeb7k
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).