all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* emacs inject a prolog to print jobs?
@ 2010-12-18 22:57 Urs Rau (UK)
  2010-12-19  9:37 ` Peter Dyballa
  2010-12-19 10:46 ` Peter Dyballa
  0 siblings, 2 replies; 6+ messages in thread
From: Urs Rau (UK) @ 2010-12-18 22:57 UTC (permalink / raw)
  To: help-gnu-emacs

I am using the latest emacs under Mac OS X 10.6.x and would like to
print emacs buffers to a xerox printer that needs accounting codes
sent as a prolog to the print job.

Pretty sure I am not the first one that needs to do that, any hints or
links to a solution for this? How does one combine postscript files ?

Mac OS X uses, (or can use) lpr for printing, so maybe that would be
the easiest to get working?

The xerox accounting "prolog" looks something like this :


^[%-12345X@PJL JOB NAME = "new  2"
@PJL ENTER LANGUAGE = POSTSCRIPT
%!PS
%%XRXbegin
%%OID_ATT_JOB_OWNER "user1"
%%OID_ATT_JOB_NAME "new  2"
%%OID_ATT_JOB_TYPE OID_VAL_JOB_TYPE_PRINT;
%%OID_ATT_PROCESS_GRAYSCALE_GRAPHICS_ENABLED TRUE;
%%OID_ATT_CONTENT_ORIENTATION OID_VAL_CONTENT_ORIENTATION_PORTRAIT;
%%OID_ATT_START_SHEET OID_VAL_JOB_SHEET_FULL;
%%OID_ATT_ACCOUNTING_INFORMATION_AVP "XRX_USERID,usr";

%%OID_ATT_COLOR_MODE OID_VAL_COLOR_MODE_AUTOMATIC;

%%XRXend

The actual accouting line that makes all the difference is:
%%OID_ATT_ACCOUNTING_INFORMATION_AVP "XRX_USERID,usr";

How does one construct such a postscript filtering pipe to allow
printing form emacs?

Thanks for any pointers.

-- 
Urs Rau



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

* Re: emacs inject a prolog to print jobs?
  2010-12-18 22:57 emacs inject a prolog to print jobs? Urs Rau (UK)
@ 2010-12-19  9:37 ` Peter Dyballa
  2010-12-21 21:51   ` Urs Rau (UK)
  2010-12-19 10:46 ` Peter Dyballa
  1 sibling, 1 reply; 6+ messages in thread
From: Peter Dyballa @ 2010-12-19  9:37 UTC (permalink / raw)
  To: urs.rau; +Cc: help-gnu-emacs


Am 18.12.2010 um 23:57 schrieb Urs Rau (UK):

> I am using the latest emacs under Mac OS X 10.6.x

Not everyone is using the "latest emacs" – which version is this? Is  
it a terminal, X11, Carbon, Cocoa, or AppKit based variant? M-x emacs- 
version RET would give some information.

The Carbon variant has a print entry in the File menu (⌘-P) from mac- 
print-mode.el which interfaces to the Mac OS X printing system and  
offers the standard form to choose a printer, save to a file, etc.

--
Mit friedvollen Grüßen

   Pete

Treffen sich zwo Parallelen an einer Straßenecke. Sagt die eine zur  
anderen: "So, hier beginnt also die Unendlichkeit!"




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

* Re: emacs inject a prolog to print jobs?
  2010-12-18 22:57 emacs inject a prolog to print jobs? Urs Rau (UK)
  2010-12-19  9:37 ` Peter Dyballa
@ 2010-12-19 10:46 ` Peter Dyballa
  2010-12-21 21:51   ` Urs Rau (UK)
  1 sibling, 1 reply; 6+ messages in thread
From: Peter Dyballa @ 2010-12-19 10:46 UTC (permalink / raw)
  To: urs.rau; +Cc: help-gnu-emacs


Am 18.12.2010 um 23:57 schrieb Urs Rau (UK):

> would like to
> print emacs buffers to a xerox printer that needs accounting codes
> sent as a prolog to the print job.


Setting ps-print-prologue-header, a variable, might be helpful.

--
Mit friedvollen Grüßen

   Pete

Email is a wonderful thing for people whose role in life is to be on  
top of things. But not for me; my role is to be on the bottom of  
things. What I do takes long hours of studying and uninterruptible  
concentration.
				– Donald Knuth




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

* Re: emacs inject a prolog to print jobs?
  2010-12-19 10:46 ` Peter Dyballa
@ 2010-12-21 21:51   ` Urs Rau (UK)
  0 siblings, 0 replies; 6+ messages in thread
From: Urs Rau (UK) @ 2010-12-21 21:51 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: help-gnu-emacs

Peter,

On 19 December 2010 10:46, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>
> Am 18.12.2010 um 23:57 schrieb Urs Rau (UK):
>
>> would like to
>> print emacs buffers to a xerox printer that needs accounting codes
>> sent as a prolog to the print job.
>
>
> Setting ps-print-prologue-header, a variable, might be helpful.
>

This is an interesting feature, but it did not seem to insert the
lines in the right seciton and my printer did not understand it. But
tannks anyway. Your other comment did get me to solve the problem.

Thanks.


> --
> Mit friedvollen Grüßen

Und zurück. ;-)

Regards,

-- 
Urs Rau



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

* Re: emacs inject a prolog to print jobs?
  2010-12-19  9:37 ` Peter Dyballa
@ 2010-12-21 21:51   ` Urs Rau (UK)
  2010-12-22  0:06     ` Peter Dyballa
  0 siblings, 1 reply; 6+ messages in thread
From: Urs Rau (UK) @ 2010-12-21 21:51 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: help-gnu-emacs

Pete,

Thank you.

On 19 December 2010 09:37, Peter Dyballa <Peter_Dyballa@web.de> wrote:
>
> Am 18.12.2010 um 23:57 schrieb Urs Rau (UK):
>
>> I am using the latest emacs under Mac OS X 10.6.x
>
> Not everyone is using the "latest emacs" – which version is this? Is it a
> terminal, X11, Carbon, Cocoa, or AppKit based variant? M-x emacs-version RET
> would give some information.
>

GNU Emacs 23.2.1 (x86_64-apple-darwin, NS apple-appkit-1038.29) of
2010-05-09 on black.local

> The Carbon variant has a print entry in the File menu (⌘-P) from
> mac-print-mode.el which interfaces to the Mac OS X printing system and
> offers the standard form to choose a printer, save to a file, etc.

That was great, thanks. I followed the mac-print-mode.el that I found
in tthe Aquamacs bundle and stumbled on a more generic one called
MacPritnMode from http://www.emacswiki.org/emacs/MacPrintMode which in
combination with "coral" actually calls up the standard Mac print
dialog, which then uses the noraml xerox drivers that handle the
accounting etc. The latest "coral" I could find was 1.3 from
http://hmdt.jp/coral/index.html

Basically MacPrintMode calls up a version of htmlize and then passes
the output to coral for ps or pdf -ication and then coral passes that
to the normal print handling dialogs.

>
> --
> Mit friedvollen Grüßen

Ebenfalls. ;-)

mfg

-- 
Urs Rau



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

* Re: emacs inject a prolog to print jobs?
  2010-12-21 21:51   ` Urs Rau (UK)
@ 2010-12-22  0:06     ` Peter Dyballa
  0 siblings, 0 replies; 6+ messages in thread
From: Peter Dyballa @ 2010-12-22  0:06 UTC (permalink / raw)
  To: urs.rau; +Cc: help-gnu-emacs


Am 21.12.2010 um 22:51 schrieb Urs Rau (UK):

> I followed the mac-print-mode.el that I found
> in tthe Aquamacs bundle and stumbled on a more generic one called
> MacPritnMode from http://www.emacswiki.org/emacs/MacPrintMode which in
> combination with "coral" actually calls up the standard Mac print
> dialog, which then uses the noraml xerox drivers that handle the
> accounting etc. The latest "coral" I could find was 1.3 from
> http://hmdt.jp/coral/index.html

Good to read that it works so well! And that Coral also still works!

>
> Basically MacPrintMode calls up a version of htmlize and then passes
> the output to coral for ps or pdf -ication and then coral passes that
> to the normal print handling dialogs.

Htmlize is also a rather perfect interface when it comes to printing  
non-Latin scripts. (Have you ever tried to print the HELLO buffer from  
C-h H?) Htmlize-view, another package, by Lennart Borgmann, sends the  
produced HTML code to the browser so that you can print with all  
comfort and all capabilities.

--
Mit friedvollen Grüßen

   Pete

The future will be much better tomorrow.
				– George W. Bush




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

end of thread, other threads:[~2010-12-22  0:06 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-18 22:57 emacs inject a prolog to print jobs? Urs Rau (UK)
2010-12-19  9:37 ` Peter Dyballa
2010-12-21 21:51   ` Urs Rau (UK)
2010-12-22  0:06     ` Peter Dyballa
2010-12-19 10:46 ` Peter Dyballa
2010-12-21 21:51   ` Urs Rau (UK)

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.