working with unicodeFormattedText

Dr. Hawkins dochawk at gmail.com
Mon Jun 10 16:30:04 EDT 2013


On Mon, Jun 10, 2013 at 12:37 PM, Dar Scott <dsc at swcp.com> wrote:

> That sequence is not really invalid UTF-8.  NUL-SPACE is valid in a strict
> sense, just unlikely.  However, it does look very much like UTF-16BE.
>

It came, at some point, from a mac keyboard, hung around in an openoffice
spreadsheet, and now I'm cutting & pasting into a field that processes it.


> You need to convert this to UTF-8 using uniDecode().  The property
> unicodeFormattedText will give you UTF-16 in native ordering.
>

I tried
     put unidecode(fld "newAbrevs", "UTF8") into theData

and get the same error.  similarly for

         put unidecode(fld "newAbrevs") into theData


(And unicodeFormattedText will insert extra line-ends.  If you don't want
> that, use unicodeText.)
>

All I really want to do is stay utf8 from start to finish :)

And what's in the DB needs to be directly usable by openoffice and the like
without any pre-processing.

Is there some way that everything pasted in would automatically be
converted from the host system character set (mac/windows/linux) to UTF8?

-- 
Dr. Richard E. Hawkins, Esq.
(702) 508-8462



More information about the use-livecode mailing list