On Thu, 02 Sep 2010 21:32:21 Kenichi Handa wrote: > > Then, in he_IL locale, by which coding-system your file is > decoded? C-h C RET shows that coding-system near the top > under the line "Coding system for saving this buffer:". The coding-system-for-read is hebrew-iso-8bit. > And I don't understand this part. > > > I then set the DOS Hebrew chars (128-144) each to a vector: > > [ 169 ] > > 169 is not a "UNIX Hebrew char", i.e. not a Unicode > character code of a Hebrew char, nor a code-point of a > Hebrew character in iso-8859-8 character set. Yes, that's my problem, I have Hebrew in #xE0-#xFA (iso-8859-8) but I have other 8 bit bytes (most of them are graphic shapes from the cp862 set). > And, you wrote "a small part have MSDOS Hebrew (#x80-#x9A)", > but #x9a is 154, not 144. Is "144" above just a typo? Just a typo, it should be 154. All my data files are 8bit bytes, so for me it is always, character = byte (at least externally). > Perhaps, the following is the best way to understand what > you want: > > (1) You at first make sample files and give me them. > (2) Tell me how you want read that file exactly. > Just C-x C-f FILENAME RET, or M-x find-file-literally ...., > or C-x C-m c no-convesion RET C-x C-f FILENAME RET, > or ... > (3) Show me how it should be displayed on a terminal by an > image. I attach a tar.bz2 file with 3 files: 1. lit1 - the sample file. 2. lit1-tty.png - how it should show on text terminal. 3. lit1-x.png - how it should show on X. I can do it if I read the file with the iso-latin-1 coding-system and change the display table to show the Hebrew glyphs for the Hebrew [#xE0-#xFA] bytes. But in this way it is not Hebrew characters (e.g. for the new bidi display). I want it the other way around, to read it with hebrew-iso-8bit and to to tweak the display table to show all the bytes not belonging to the Hebrew set. I had similar problem a long time ago. In 2001 you suggested to use the following code: (make-coding-system 'hebrew-iso-8bit 2 ?8 "ISO 2022 based 8-bit encoding for Hebrew (MIME:ISO-8859-8)" '(ascii hebrew-iso8859-8 nil nil nil ascii-eol ascii-cntl nil nil nil nil nil t) '((safe-charsets ascii hebrew-iso8859-8 eight-bit-control) (mime-charset . iso-8859-8))) May be I can define a new coding system that will have bytes #x80-#xFF as legal characters and be recognized as Hebrew variant. Ehud. -- Ehud Karni Tel: +972-3-7966-561 /"\ Mivtach - Simon Fax: +972-3-7976-561 \ / ASCII Ribbon Campaign Insurance agencies (USA) voice mail and X Against HTML Mail http://www.mvs.co.il FAX: 1-815-5509341 / \ GnuPG: 98EA398D Better Safe Than Sorry