[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Windogz & utf-8



On Tuesday 13 April 2004 14:31, Mohammed Elzubeir wrote:
> On Tue, 2004-04-13 at 18:26, Mohammed Sameer wrote:
> > On Tue, Apr 13, 2004 at 02:59:13PM +0300, Ahmad Al-rasheedan wrote:
> > > Every time a friend that uses Windogz send me a message in Arabic I
> > > have to switch my kmail to Windogz-1265 char set to read it and then
> > > switch it back to utf-8. Any reason microsoft NOT using utf-8 by
> > > default?
> >
>
> Now, your question is probably -- what do I do about it? One option
> (depending on how you check your mail) is to use procmail to run a
> script which would check the filetype with file(1) and if not UTF-8 run
> iconv(1) on it. I'm not sure that would yield 100% accuracy, but you
> could give it a shot. I don't know how KMail works, but you could do the
> same if it has a filtering option where you can plug in scripts to do
> things for you before you read the mail.
>

  I do use KMail, and it has advanced filtering abilities.
  + First make sure you are using KMail 1.6.1 (shipped with KDE 3.2, AFAIK)
     if you have KDE 3.2 or 3.2.1 it's fine.
  + Now choose Settings/Configure Filters from the main menu.
  + Click on the blank page button at the bottom left corner to create a new
     filter.
  + on "Filter Criteria" choose from the first combo box "<any header>"
     and type "content-type" on the first text box. (You could typed
     the encoding name explicitly but not all emails set that value, this
     criteria should match any email utf8, cp1256 or even iso-8859-1).
  + on the "Filter Actions" choose from the combo box "pipe through" and
     type "iconv -f WINDOWS-1256 -t UTF-8" on the text box to its left.
  + Now press OK and you are done.
  
  + If you have some emails already in your box, mark all of them and
     choose "Message/Apply Filters" or Ctrl-J and they should be converted
     if needed to.