Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / General / General / May 2008



Tip: Looking for answers? Try searching our database.

Text file format

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Howard Brazee - 27 May 2008 17:26 GMT
I have used Text Wrangler to change the character coding and line ends
of some documents that I have imported from Windows systems but which
did not display correctly in Text Edit.

I saw lot of options, and decided to look at a OS X generated text
file to model my documents.

But the amount of options Text Wrangler has leads me to ask advice
about different formats for different uses.   For instance, a document
that I need to copy directly back and forth between OS X and Windows
might be different from one I use elsewhere.

Any recommendations about when a particular character coding and/or
LF/FF settings are appropriate?
Chris Ridd - 27 May 2008 21:15 GMT
> I have used Text Wrangler to change the character coding and line ends
> of some documents that I have imported from Windows systems but which
[quoted text clipped - 10 lines]
> Any recommendations about when a particular character coding and/or
> LF/FF settings are appropriate?

What app(s) are you intending to use the files with on Windows?

Cheers,

Chris
Howard Brazee - 27 May 2008 21:38 GMT
>> Any recommendations about when a particular character coding and/or
>> LF/FF settings are appropriate?
>
>What app(s) are you intending to use the files with on Windows?

The ones I use now are Ultra-Edit and Office.   Someday I'd like to
set up my Mac with compatible Java with work though (they use
JBuilder, but I may be using Eclipse) - although the apps run on Suns
under Unix.   I have also copied my Opera bookmarks, although I don't
need to do so with Firefox due to a nifty add-on that synchronizes via
the web.

Besides those, I'm hoping to advance my education in the many options
available on Macs for file formats.
Heath Raftery - 28 May 2008 01:42 GMT
> I have used Text Wrangler to change the character coding and line ends
> of some documents that I have imported from Windows systems but which
[quoted text clipped - 10 lines]
> Any recommendations about when a particular character coding and/or
> LF/FF settings are appropriate?

Line endings are easy:

LF: Unix, including Mac OS X
CR+LF: DOS, Windows
CR: Old Mac OS

Where LF is a line feed and CR is a carriage return (DOS uses two
characters).

Since the pattern is so simple, there are no real dramas converting
between one and the other. Just use that which is most convenient.
I always use LF since all the unix tools will have no dramas and it
is simple to add or change to a CR for apps that don't get it.

Encodings I don't know much about. As I understand it, if you want
to be universal (lots of characters, lots of support), go with a
UTF format like UTF-8 or UTF-16. If you specifically want to support
a certain language, go for the encoding for that language (eg.
ISO-2022-JP (JIS) for Japanese). If you want a good, widely
compatible encoding that covers all of the characters used in
Western Europe but doesn't have the complexity of UTF, use
ISO 8859-1 (Latin 1). There are adaptions of this encoding (-2, -3,
-4 etc.) that add more exotic characters.

Finally, use Mac OS Roman or Windows-1250 only if you want to be
compatible with those OS's.

HTH

Signature

*--------------------------------------------------------*

| ^Nothing is foolproof to a sufficiently talented fool^ |
|    Heath Raftery, HRSoftWorks          _\|/_           |
*______________________________________m_('.')_m_________*
Howard Brazee - 28 May 2008 14:55 GMT
>Line endings are easy:
>
[quoted text clipped - 4 lines]
>Where LF is a line feed and CR is a carriage return (DOS uses two
>characters).

That I understood.

>Since the pattern is so simple, there are no real dramas converting
>between one and the other. Just use that which is most convenient.
>I always use LF since all the unix tools will have no dramas and it
>is simple to add or change to a CR for apps that don't get it.

So there are Mac applications that don't adjust.   I wasn't sure about
that with my testing, other than some text documents I could open with
Text Edit and the text would be in paragraphs - with some wrong
characters, but when I opened it with Text Wrangler, they would have
super long lines with the correct characters.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.