• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Unicode to plain text
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unicode to plain text


  • Subject: Re: Unicode to plain text
  • From: Paul Berkowitz <email@hidden>
  • Date: Wed, 18 Sep 2002 14:04:26 -0700

On 9/18/02 12:02 PM, "Jon Pugh" <email@hidden> wrote:

> So I've been bashing my head on CodeWarrior too much. I'm running 10.2.
>
> do shell script returns Unicode, class utxt.
>
> CodeWarrior wants plain text to insert into its windows, class TEXT.
>
> I cannot find a way to coerce utxt to TEXT, aside from feeding it to ACME
> Replace, which works for me, but not for others without this great scripting
> addition.
>
> Does anyone know how to convert utxt to TEXT in plain AppleScript? I'm
> beginning to doubt that there's a way.

Is utxt the same as 'as Unicode text'? Arthur has shown us many times that
this works with Unicode:

on AsText(str)
--coerce Unicode or other text to styled string to plain text
try
return (((str as string) as record)'s <<class ktxt>>)
end try
return str -- if plain text to begin with

end AsText

Or are you getting that raw data stuff we used to get for utxt back in OS
8.5?

--
Paul Berkowitz
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Unicode to plain text (From: Jon Pugh <email@hidden>)

  • Prev by Date: Re: Quark doc as ASCII
  • Next by Date: RE: applescript-users digest, Vol 3 #867 - 14 msgs
  • Previous by thread: Re: Unicode to plain text
  • Next by thread: Re: Unicode to plain text
  • Index(es):
    • Date
    • Thread