• 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
Coercing Styled Text to Text
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Coercing Styled Text to Text


  • Subject: Coercing Styled Text to Text
  • From: Ehsan Saffari <email@hidden>
  • Date: Thu, 14 Jun 2001 02:55:58 -0600

On Wed, 13 Jun 2001 17:24:46 +0100, Nigel Garvey
<email@hidden> wrote:

>Subject:Re: Subject: Error geetting offset of char in errMsg
>
>Shane Stanley wrote on Wed, 13 Jun 2001 14:31:44 +1000:
>
>>On 13/6/01 9:48 AM +1000, Nigel Garvey, email@hidden, wrote:
>>
>>> work-rounds that have worked in the past include:
>>>
>>> on error message
>>> set message to message as unicode text as text
>>
>>Why do we have to go via Unicode, though?
>
>It was just a fast way that Jeff Baumann (I think) discovered to convert
>styled text into plain text. Obviously it would obviously be nicer if
>there were a more direct coercion. More recently, there's been Richard
>23's method, which I carelessly forgot to mention in my previous post:
>
> on error message
> set message to <<class ktxt>> of (message as record)
>
>('<<' and '>>' are of course the single characters produced on
>English-language keyboards by typing option-"\" and shift-option-"\"
>respectively.)

or a slightly differnt variation

set plainTxt to item 1 of (((stylTextObj) as record) as list)

cheers
ehsan


  • Prev by Date: handle CGI Request - client address parameters - error and gotcha
  • Next by Date: Re: replacing text
  • Previous by thread: handle CGI Request - client address parameters - error and gotcha
  • Next by thread: Re: Coercing Styled Text to Text
  • Index(es):
    • Date
    • Thread