From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: myglc2 Newsgroups: gmane.emacs.help Subject: Re: make ps-print-buffer-with-faces all bold Date: Mon, 25 Jul 2016 11:08:06 -0400 Message-ID: References: <86invvxk1v.fsf@student.uu.se> <86shuyhio1.fsf@student.uu.se> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1469459443 13708 80.91.229.3 (25 Jul 2016 15:10:43 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 25 Jul 2016 15:10:43 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jul 25 17:10:34 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1bRhWa-0006Do-2t for geh-help-gnu-emacs@m.gmane.org; Mon, 25 Jul 2016 17:10:32 +0200 Original-Received: from localhost ([::1]:32894 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bRhWZ-0003ag-8C for geh-help-gnu-emacs@m.gmane.org; Mon, 25 Jul 2016 11:10:31 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59779) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bRhWA-0003YG-IK for help-gnu-emacs@gnu.org; Mon, 25 Jul 2016 11:10:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bRhW6-00021Q-B7 for help-gnu-emacs@gnu.org; Mon, 25 Jul 2016 11:10:05 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:42807) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bRhW6-00021G-41 for help-gnu-emacs@gnu.org; Mon, 25 Jul 2016 11:10:02 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1bRhW4-0005q4-7l for help-gnu-emacs@gnu.org; Mon, 25 Jul 2016 17:10:00 +0200 Original-Received: from c-73-167-118-254.hsd1.ma.comcast.net ([73.167.118.254]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 25 Jul 2016 17:10:00 +0200 Original-Received: from myglc2 by c-73-167-118-254.hsd1.ma.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 25 Jul 2016 17:10:00 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 36 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: c-73-167-118-254.hsd1.ma.comcast.net User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) Cancel-Lock: sha1:+Q3Ct8Nou1b5H6ZffZgWYvII9Lg= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:110925 Archived-At: Emanuel Berg writes: > myglc2 wrote: > >>> Last, aren't there other attributes than >>> foreground and background? Perhaps you can >>> find a function that returns the whole >>> thing, and then just set it to bold? >> >> The ps-print.el public interface requires >> this custom structure. > > OK, because if you use `describe-function' you > get a whole lot of stuff! > > But perhaps PostScript in this case (?) only > uses what you mention? Restating the function under discussion for handy reference ... ;; ps-print in all bold fonts (ps-extend-face-list (mapcar (function (lambda (x) (list x (face-attribute x :foreground) (face-attribute x :background) 'bold))) (face-list)) 'MERGE) OK I think I missed your earlier point. Yes, you can specify additional attributes, to the extent that ps-print supports them, using the 'ps-extend-face-list' interface. The reason I specify the colors is that with nil or t for foreground and background, ps-print prints in B&W. So this function re-states the colors that ps-print already knows about in order to bold the faces w/o clobbering the color. HTH - George