unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Cannot get set-fontset-font do what I need
@ 2008-03-03  1:49 yavuz164
  2008-03-03  5:35 ` Dmitri Minaev
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: yavuz164 @ 2008-03-03  1:49 UTC (permalink / raw)
  To: help-gnu-emacs

Hi everyone,

I need to ps-print a buffer with Turkish text. I read some info from
various sources, and did the "eval"ed the folowing in Lisp buffer.


(create-fontset-from-fontset-spec "-etl-fixed-medium-r-
normal--24-240-72-72-c-120-iso8859-9" t 'noerror)
(set-fontset-font "-etl-fixed-medium-r-normal--24-240-72-72-c-120-
iso8859-9" 'latin-iso8859-9 '("etl" . "iso8859-9"))

After that I chose the newly-appering fontset from Options->SetFont/
Fontset, but when I ps-spool-buffer, it comes back reporting all the
Turkish characters in text unprintable.

Please tell me what am I missing.

Thanks in advance.





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

* Re: Cannot get set-fontset-font do what I need
  2008-03-03  1:49 Cannot get set-fontset-font do what I need yavuz164
@ 2008-03-03  5:35 ` Dmitri Minaev
  2008-03-03 12:04 ` Peter Dyballa
  2008-03-04  6:57 ` Dmitri Minaev
  2 siblings, 0 replies; 4+ messages in thread
From: Dmitri Minaev @ 2008-03-03  5:35 UTC (permalink / raw)
  To: yavuz164; +Cc: help-gnu-emacs

On Mon, Mar 3, 2008 at 5:49 AM,  <yavuz164@gmail.com> wrote:
>  (create-fontset-from-fontset-spec "-etl-fixed-medium-r-
>  normal--24-240-72-72-c-120-iso8859-9" t 'noerror)
>  (set-fontset-font "-etl-fixed-medium-r-normal--24-240-72-72-c-120-
>  iso8859-9" 'latin-iso8859-9 '("etl" . "iso8859-9"))
>

Frankly, I never really understood fontsets :). However, I've been
using GNU Intlfonts (the 'etl' font you use is from Intlfonts) by
setting them in X resources (the text was taken from Intlfonts
distribution):

!! BEGIN intlfonts setup
!! By default, use 16 dots fonts
Emacs.Font: fontset-16
!! For small screen users (eg. 640x480 or 800x600)
Emacs.Fontset-0: -etl-*-medium-r-normal-*-14-*-*-*-*-*-fontset-14
!! For medium screen users (eg. 1024x780)
Emacs.Fontset-1: -etl-*-medium-r-normal-*-16-*-*-*-*-*-fontset-16
!! For medium screen users (eg. 1024x780) suitable for Thai characters
Emacs.Fontset-2: -etl-*-medium-r-normal-*-18-*-*-*-*-*-fontset-18
!! For large screen users (eg. 1280x1024 or larger)
Emacs.Fontset-3: -etl-*-medium-r-normal-*-24-*-*-*-*-*-fontset-24
!! END intlfonts setup


-- 
With best regards,
Dmitri Minaev

Russian history blog: http://minaev.blogspot.com




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

* Re: Cannot get set-fontset-font do what I need
  2008-03-03  1:49 Cannot get set-fontset-font do what I need yavuz164
  2008-03-03  5:35 ` Dmitri Minaev
@ 2008-03-03 12:04 ` Peter Dyballa
  2008-03-04  6:57 ` Dmitri Minaev
  2 siblings, 0 replies; 4+ messages in thread
From: Peter Dyballa @ 2008-03-03 12:04 UTC (permalink / raw)
  To: yavuz164; +Cc: help-gnu-emacs


Am 03.03.2008 um 02:49 schrieb yavuz164:

> After that I chose the newly-appering fontset from Options->SetFont/
> Fontset, but when I ps-spool-buffer, it comes back reporting all the
> Turkish characters in text unprintable.


The problem has many different layers ...

The fontsets you define are only a helpful means for presenting  
(displaying) the encoded characters from the file in some window in  
GNU Emacs. Printing the (still unchanged) file's contents or its view  
in a GNU Emacs buffer is completely independent from this. And it  
gives you two new problems: you'll need to find at least one font  
that contains the Turkish glyphs and you'll need to provide a  
PostScript encoding for Turkish/ISO 8859-9/ISO Latin-7.

The first PostScript problem, the font, is the big problem, from my  
point of view: I don't know of a PostScript font with Turkish glyphs  
like:

	;   oct   dec   hex    UCS2    UTF-8
	;=====================================
	Ğ = 320 = 208 = D0 = U+011E =    C4 9E : LATIN CAPITAL LETTER G WITH  
BREVE
	İ = 335 = 221 = DD = U+0130 =    C4 B0 : LATIN CAPITAL LETTER I WITH  
DOT ABOVE
	Ş = 336 = 222 = DE = U+015E =    C5 9E : LATIN CAPITAL LETTER S WITH  
CEDILLA
	ğ = 360 = 240 = F0 = U+011F =    C4 9F : LATIN SMALL LETTER G WITH  
BREVE
	ş = 376 = 254 = FE = U+015F =    C5 9F : LATIN SMALL LETTER S WITH  
CEDILLA

The PostScript encoding problem is at least solved in GNU Emacs  
23.0.60 from CVS. If you had this version (I presume you are using  
GNU Emacs 22.1 or elder) you could set up proper PostScript fonts to  
use via the customisation interface. Then all could be fine.

In the meantime you can use a perfect work-around: htmlize-view.el by  
Lennart Borgmann (http://
piprim.tuxfamily.org/home/pi/emacs.d/site-lisp/htmlize-view.el ?) and  
htmlize.el by Hrvoje Nikšić (http://fly.srk.fer.hr/~hniksic/emacs/ 
htmlize.el). Htmlize-view creates an HTML buffer by means of htmlize.  
This buffer is sent to your web browser. Now you can print from the  
browser in (complete) Unicode, using your system's capabilities,  
which are more elaborate than GNU Emacs.

If you can't find htmlize-view.el I can send you my copy privately.


BTW, you know that the ps-spool-* commands don't print but just  
create *PostScript* buffers?

--
Greetings

   Pete

Hard Disk, n.:
	A device that allows users to delete vast quantities
	of data with simple mnemonic commands.








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

* Re: Cannot get set-fontset-font do what I need
  2008-03-03  1:49 Cannot get set-fontset-font do what I need yavuz164
  2008-03-03  5:35 ` Dmitri Minaev
  2008-03-03 12:04 ` Peter Dyballa
@ 2008-03-04  6:57 ` Dmitri Minaev
  2 siblings, 0 replies; 4+ messages in thread
From: Dmitri Minaev @ 2008-03-04  6:57 UTC (permalink / raw)
  To: yavuz164; +Cc: help-gnu-emacs

On Mon, Mar 3, 2008 at 5:49 AM,  <yavuz164@gmail.com> wrote:
>  After that I chose the newly-appering fontset from Options->SetFont/
>  Fontset, but when I ps-spool-buffer, it comes back reporting all the
>  Turkish characters in text unprintable.

I thought of another possibility. To print non-Latin characters with
Intlfonts, you should have not only PCF fonts, but also the BDF
version. Are BDF fonts installed as described in the PostScript
Variables chapter of the manual? See
http://www.gnu.org/software/emacs/manual/html_node/emacs/PostScript-Variables.html#PostScript-Variables

-- 
With best regards,
Dmitri Minaev

Russian history blog: http://minaev.blogspot.com




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

end of thread, other threads:[~2008-03-04  6:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-03  1:49 Cannot get set-fontset-font do what I need yavuz164
2008-03-03  5:35 ` Dmitri Minaev
2008-03-03 12:04 ` Peter Dyballa
2008-03-04  6:57 ` Dmitri Minaev

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).