all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Latin-1 under MacOS
@ 2004-01-14 23:11 Konrad Hinsen
  2004-01-15  0:42 ` Thomas F. Burdick
  0 siblings, 1 reply; 7+ messages in thread
From: Konrad Hinsen @ 2004-01-14 23:11 UTC (permalink / raw)


I have spent a couple of hours trying to get Emacs on my Mac (the Carbon 
build) display Latin-1 correctly, with no luck.

The FAQ recommends (if I interpret it correctly) to add

(create-fontset-from-fontset-spec 
"-apple-monaco-medium-r-normal--9-*-*-*-*-*-fontset-monaco,ascii:-apple-m
onaco-medium-r-normal--9-90-75-75-m-90-mac-roman,latin-iso8859-1:-apple-m
onaco-medium-r-normal--9-90-75-75-m-90-mac-roman")

(set-frame-font 
"-apple-monaco-medium-r-normal--9-*-*-*-*-*-fontset-monaco")


to .emacs. That doesn't do anything on my system. Everything looks like 
before (the font is larger than 9 point) and my German and French 
accented characters (in Latin-1 encoded files copied over from a Linux 
machine) look messy as before. I also tried

  (set-frame-font "fontset-monaco")

(no effect either) and

  (set-frame-font 'fontset-monaco)

(puts Emacs into a strange meditation state that only killing seems to 
be able to terminate).

The other suggestion is using the GNU intlfonts. The promised link isn't 
there, but I found the generic tar archive plus some add-on files to 
install them under MacOS 8/9 using a tool called MPW that I have never 
heard of. I tried the standard Unix installation, specifying 
/Library/Fonts as the destination. By itself that does nothing either, I 
suppose I also need something for my .emacs, but I don't have the 
slightest idea what that should be.

I found a couple of other hints on the Web, but none of them was any 
more successful.

Any more suggestions? Working .emacs files are particularly welcome.

Konrad (slightly frustrated)

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

* Re: Latin-1 under MacOS
  2004-01-14 23:11 Latin-1 under MacOS Konrad Hinsen
@ 2004-01-15  0:42 ` Thomas F. Burdick
  2004-01-15  2:21   ` Tim McNamara
                     ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Thomas F. Burdick @ 2004-01-15  0:42 UTC (permalink / raw)


Konrad Hinsen <konrad.hinsen@laposte.net> writes:

> I have spent a couple of hours trying to get Emacs on my Mac (the Carbon 
> build) display Latin-1 correctly, with no luck.
> 
> The FAQ recommends (if I interpret it correctly) to add
> 
> (create-fontset-from-fontset-spec 
> "-apple-monaco-medium-r-normal--9-*-*-*-*-*-fontset-monaco,ascii:-apple-m
> onaco-medium-r-normal--9-90-75-75-m-90-mac-roman,latin-iso8859-1:-apple-m
> onaco-medium-r-normal--9-90-75-75-m-90-mac-roman")
> 
> (set-frame-font 
> "-apple-monaco-medium-r-normal--9-*-*-*-*-*-fontset-monaco")
> 
> 
> to .emacs. That doesn't do anything on my system. Everything looks like 
> before (the font is larger than 9 point) and my German and French 
> accented characters (in Latin-1 encoded files copied over from a Linux 
> machine) look messy as before. I also tried
> 
>   (set-frame-font "fontset-monaco")
> 
> (no effect either) and
> 
>   (set-frame-font 'fontset-monaco)
> 
> (puts Emacs into a strange meditation state that only killing seems to 
> be able to terminate).

I'm not sure why that isn't working for you.  Here's what I have in my
.emacs:

;; Apparently we need to create a "fontset" for every Mac font that we use.
;; We need to tell the fontset to include the font for *every* encoding
;; we want it to support, otherwise, we'll get little boxes.  This *sucks*.
(create-fontset-from-fontset-spec
 "-apple-monaco-medium-r-normal--10-*-*-*-*-*-fontset-monaco,
ascii:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman,
latin-iso8859-1:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman")

(setq default-frame-alist
      `((font . "fontset-monaco")
	(width . 85) (height . 30)
	,@default-frame-alist))

Try evaluating the call to create-fontset-from-fontset-spec that you
have by pasting it into the *scratch* buffer, then hitting C-j.  Do
you get any errors?  If not, M-x
set-frame-font<RET>fontset-monaco<RET> should work.

> Konrad (slightly frustrated)

(I'm not sure why it has to be so hard.  It was painful for me getting
this up, too.)

-- 
           /|_     .-----------------------.                        
         ,'  .\  / | No to Imperialist war |                        
     ,--'    _,'   | Wage class war!       |                        
    /       /      `-----------------------'                        
   (   -.  |                               
   |     ) |                               
  (`-.  '--.)                              
   `. )----'                               

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

* Re: Latin-1 under MacOS
  2004-01-15  0:42 ` Thomas F. Burdick
@ 2004-01-15  2:21   ` Tim McNamara
  2004-01-15  9:13   ` Konrad Hinsen
  2004-01-15 19:09   ` Kai-Mikael Jää-Aro
  2 siblings, 0 replies; 7+ messages in thread
From: Tim McNamara @ 2004-01-15  2:21 UTC (permalink / raw)


tfb@famine.OCF.Berkeley.EDU (Thomas F. Burdick) writes:

> (create-fontset-from-fontset-spec
> "-apple-monaco-medium-r-normal--10-*-*-*-*-*-fontset-monaco,
> ascii:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman,
> latin-iso8859-1:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman")
>
> (setq default-frame-alist
>       `((font . "fontset-monaco")
> 	(width . 85) (height . 30)
> 	,@default-frame-alist))

Should the result be:

((font . "fontset-monaco") (width . 85) (height . 30)
(vertical-scroll-bars . right) (tool-bar-lines . 1) (menu-bar-lines .
1) (width . 100) (height . 35))



Running Mac OS X 10.3.2, CVS Emacs (21.3.50.1)

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

* Re: Latin-1 under MacOS
  2004-01-15  0:42 ` Thomas F. Burdick
  2004-01-15  2:21   ` Tim McNamara
@ 2004-01-15  9:13   ` Konrad Hinsen
  2004-01-15 19:09   ` Kai-Mikael Jää-Aro
  2 siblings, 0 replies; 7+ messages in thread
From: Konrad Hinsen @ 2004-01-15  9:13 UTC (permalink / raw)


In article <xcv7jzukppf.fsf@famine.OCF.Berkeley.EDU>,
 tfb@famine.OCF.Berkeley.EDU (Thomas F. Burdick) wrote:

> I'm not sure why that isn't working for you.  Here's what I have in my
> .emacs:
> 
> ;; Apparently we need to create a "fontset" for every Mac font that we use.
> ;; We need to tell the fontset to include the font for *every* encoding
> ;; we want it to support, otherwise, we'll get little boxes.  This *sucks*.
> (create-fontset-from-fontset-spec
>  "-apple-monaco-medium-r-normal--10-*-*-*-*-*-fontset-monaco,
> ascii:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman,
> latin-iso8859-1:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman")
> 
> (setq default-frame-alist
>       `((font . "fontset-monaco")
> 	(width . 85) (height . 30)
> 	,@default-frame-alist))

Thanks!  It didn't work at first, but then I decided to remove 
everything else from my .emacs and from site-start.el. I kept just those 
lines and

(setq mac-keyboard-text-encoding kTextEncodingISOLatin1)

for the keyboard. And that works!

I will have to work through all the remaining stuff to see what causes 
the conflict. Nothing evident of course, nothing that touches the 
display. But who knows what those mode initialization files do...

> Try evaluating the call to create-fontset-from-fontset-spec that you
> have by pasting it into the *scratch* buffer, then hitting C-j.  Do
> you get any errors?  If not, M-x

The fontset generation was not the problem, no error message and 
"list-fontsets" always showed the new one. It is activating the font set 
that seems to be a bit fragile.

More later...

Konrad (cheering up :-)

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

* Re: Latin-1 under MacOS
  2004-01-15  0:42 ` Thomas F. Burdick
  2004-01-15  2:21   ` Tim McNamara
  2004-01-15  9:13   ` Konrad Hinsen
@ 2004-01-15 19:09   ` Kai-Mikael Jää-Aro
  2004-01-15 23:58     ` Thomas F. Burdick
  2 siblings, 1 reply; 7+ messages in thread
From: Kai-Mikael Jää-Aro @ 2004-01-15 19:09 UTC (permalink / raw)


tfb@famine.OCF.Berkeley.EDU (Thomas F. Burdick) writes:

> Konrad Hinsen <konrad.hinsen@laposte.net> writes:
> 
> ;; Apparently we need to create a "fontset" for every Mac font that we use.
> ;; We need to tell the fontset to include the font for *every* encoding
> ;; we want it to support, otherwise, we'll get little boxes.  This *sucks*.
> (create-fontset-from-fontset-spec
>  "-apple-monaco-medium-r-normal--10-*-*-*-*-*-fontset-monaco,
> ascii:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman,
> latin-iso8859-1:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman")
> 
> (setq default-frame-alist
>       `((font . "fontset-monaco")
> 	(width . 85) (height . 30)
> 	,@default-frame-alist))
> 
> Try evaluating the call to create-fontset-from-fontset-spec that you
> have by pasting it into the *scratch* buffer, then hitting C-j.  Do
> you get any errors?

I get errors, but then I already have that create-fontset-... in my .emacs, 
to be precise I have the following:

(cond ((string-equal window-system "mac")
       (set-language-environment "Latin-1")
       (set-keyboard-coding-system 'mac-roman) 
       (create-fontset-from-fontset-spec
         "-apple-monaco-medium-r-normal--10-*-*-*-*-*-fontset-monaco,ascii:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman,latin-iso8859-1:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman")
       ))

and I still get little boxes for the interesting characters.

I have what claims to be Emacs 21.3.50.1, running under OS X 10.2.8.

-- 
Kai-Mikael Jää-Aro	email:  kai@nada.kth.se	    "Don't win, don't lose."
NADA, KTH 		voice:  +46 8 790 61 18		-- Yoshigasaki-sensei
SE-100 44  Stockholm	fax:    +46 8 10 24 77
SWEDEN			

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

* Re: Latin-1 under MacOS
  2004-01-15 19:09   ` Kai-Mikael Jää-Aro
@ 2004-01-15 23:58     ` Thomas F. Burdick
  2004-01-16 10:13       ` Kai-Mikael Jää-Aro
  0 siblings, 1 reply; 7+ messages in thread
From: Thomas F. Burdick @ 2004-01-15 23:58 UTC (permalink / raw)


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1319 bytes --]

kai@achernar.nada.kth.se   (Kai-Mikael Jää-Aro) writes:

> I get errors, but then I already have that create-fontset-... in my .emacs, 
> to be precise I have the following:
> 
> (cond ((string-equal window-system "mac")
>        (set-language-environment "Latin-1")
>        (set-keyboard-coding-system 'mac-roman) 
>        (create-fontset-from-fontset-spec
>          "-apple-monaco-medium-r-normal--10-*-*-*-*-*-fontset-monaco,ascii:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman,latin-iso8859-1:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman")
>        ))
> 
> and I still get little boxes for the interesting characters.

Once you create the fontset, you need to actually use it.  Try

M-x set-frame-font fontset-monaco, and if that works, add something
like (push '(font . "fontset-monaco") default-frame-alist) to your
.emacs

-- 
           /|_     .-----------------------.                        
         ,'  .\  / | No to Imperialist war |                        
     ,--'    _,'   | Wage class war!       |                        
    /       /      `-----------------------'                        
   (   -.  |                               
   |     ) |                               
  (`-.  '--.)                              
   `. )----'                               

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

* Re: Latin-1 under MacOS
  2004-01-15 23:58     ` Thomas F. Burdick
@ 2004-01-16 10:13       ` Kai-Mikael Jää-Aro
  0 siblings, 0 replies; 7+ messages in thread
From: Kai-Mikael Jää-Aro @ 2004-01-16 10:13 UTC (permalink / raw)


tfb@famine.OCF.Berkeley.EDU (Thomas F. Burdick) writes:

> kai@achernar.nada.kth.se   (Kai-Mikael Jää-Aro) writes:
> 
> > I get errors, but then I already have that create-fontset-... in my .emacs, 
> > to be precise I have the following:
> > 
> > (cond ((string-equal window-system "mac")
> >        (set-language-environment "Latin-1")
> >        (set-keyboard-coding-system 'mac-roman) 
> >        (create-fontset-from-fontset-spec
> >          "-apple-monaco-medium-r-normal--10-*-*-*-*-*-fontset-monaco,ascii:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman,latin-iso8859-1:-apple-monaco-medium-r-normal--10-100-75-75-m-100-mac-roman")
> >        ))
> > 
> > and I still get little boxes for the interesting characters.
> 
> Once you create the fontset, you need to actually use it.  Try
> 
> M-x set-frame-font fontset-monaco, and if that works, add something
> like (push '(font . "fontset-monaco") default-frame-alist) to your
> .emacs

Haaa!  It works, it works!  *Finally* being able to read my text, thank you, thank you!

-- 
Kai-Mikael Jää-Aro	email:  kai@nada.kth.se	    "Don't win, don't lose."
NADA, KTH 		voice:  +46 8 790 61 18		-- Yoshigasaki-sensei
SE-100 44  Stockholm	fax:    +46 8 10 24 77
SWEDEN			

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

end of thread, other threads:[~2004-01-16 10:13 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-01-14 23:11 Latin-1 under MacOS Konrad Hinsen
2004-01-15  0:42 ` Thomas F. Burdick
2004-01-15  2:21   ` Tim McNamara
2004-01-15  9:13   ` Konrad Hinsen
2004-01-15 19:09   ` Kai-Mikael Jää-Aro
2004-01-15 23:58     ` Thomas F. Burdick
2004-01-16 10:13       ` Kai-Mikael Jää-Aro

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.