Hi,

You're probably aware that reading Hebrew sites with the Linux
Netscape is very hard, especially those that set the Content-Type to
iso8859-8. You can't switch to User-Defined encoding in Netscape and
set your fonts there, it doesn't let you. Once Stanislav Malyshev (?)
mentioned on Linux-IL that you can edit your Netscape binary and "take
over" some another encoding and turn it to iso8895-8. I then tried it
and it didn't work well, so I forgot about it; today I needed it
really bad and succeeded. So I though that perhaps it's a good idea to
distribute a script that does it to linux-il, probably some people
here are interested in this.

So here it is. Modify the netscape= line to point to your Netscape
binary and run. Then do what it tells you. What it does is hijack the
Turkish enconding and turn it to Hebrew. As the echoed message at the
end of the script says, it only works if you set your fonts for the
Hebrew encoding (in Netscape Preferences) to the Fixed (Misc) fonts
that come with the X server. If you have Eli's H.fonts package
installed, fonts from there won't work -- if you select one of them,
Netscape simply loads the standard "fixed" font instead. I don't know
why it happens. The Fixed (Misc) font is good enough to read Hebrew
sites though. Go to walla and see how it automatically switches to
Hebrew for you. :-)

Disclaimer: use at your own risk. The script makes a backup of the
binary, but be careful anyway if you don't want to download Netscape
again.


-- 
Alex Shnitman                            | http://www.debian.org
[EMAIL PROTECTED], [EMAIL PROTECTED]   +-----------------------  
http://alexsh.hectic.net    UIN 188956    PGP key on web page
       E1 F2 7B 6C A0 31 80 28  63 B8 02 BA 65 C7 8B BA

/real/ kernel hackers
    dd if=/dev/urandom of=/vmlinuz
and influence the Universal Randomosity Field.
        -- Gaal Yahas
#!/bin/sh

# Change this to the location of your binary:
netscape=/usr/X11R6/bin/netscape

echo "Moving $netscape to ${netscape}.old..."
mv $netscape ${netscape}.old
echo "Editing the binary... (this can take a LONG time)"
sed -e 's/8859-8/8859-z/g' -e 's/88598/8859z/g' -e 's/8859_8/8859_z/g' ${netscape}.old 
| sed -e 's/8859-9/8859-8/g' -e 's/88599/88598/g' -e 's/8859_9/8859_8/g' -e 
's/Turkish/Hebrew /g' -e 's/turkish/hebrew /g' -e 's/\[tr\]/[hb]/g' | sed -e 
's/8859-z/8859-9/g' -e 's/8859z/88599/g' -e 's/8859_z/8859_9/g' > $netscape
chmod +x $netscape

cat <<EOF
Done. Now launch Netscape, go to Preferences, select Fonts, select Hebrew,
and select the Fixed (Misc) font for both the variable width and fixed width
categories.
EOF

PGP signature

Reply via email to