help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Printing fonts


From: Giorgos Keramidas
Subject: Re: Printing fonts
Date: Fri, 19 Oct 2007 17:43:04 +0300
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/23.0.50 (berkeley-unix)

On Thu, 18 Oct 2007 14:00:56 -0400, address@hidden (Joel J. Adamson) wrote:
> address@hidden (Joel J. Adamson) writes:
>
> [...]
>
>> I only discovered enscript after writing my initial message.
>
> Here's a little function to do the hard work, suggestions welcome:
>
>
> (defun my-print-buffer (font)
>   (interactive "sFont: ")
>   (let ((cmd-string
>        (format "enscript -u\"Joel J. Adamson\" --ul-font=Times-Roman100 
> --ul-style=filled -f%s -G --style=a2ps" font))) ;include page title of 
> current buffer
>     (shell-command-on-region
>      (point-min) (point-max) cmd-string)))
>
> Can I split that string across lines?

I'm sure there are probably better ways to do this, but the following
may help:

    (let ((ps-options '("-u\"Joel J. Adamson\""
                        "--ul-font=Times-Roman100")))
      (apply 'concat
             (apply 'append
                    (mapcar (lambda (s)
                              (list s " "))
                            ps-options))))

    => "-u\"Joel J. Adamson\" --ul-font=Times-Roman100 "



reply via email to

[Prev in Thread] Current Thread [Next in Thread]