[TxMt] Re: Problems handling Windows-encoded files
mailinglist at textmate.org
Wed Jan 4 03:24:03 UTC 2012
On 04/01/2012, at 07.45, Trevor Harmon wrote:
> […] Is there any way to have TextMate autodetect the encoding so that opening and searching files works as expected? Thanks,
The thing is, it’s impossible to do auto-detection with 100% certainty.
UTF-8 though comes very close to being 100% auto-detectable, so TM2 tests for that, and lets user do the hard work when it is not UTF-8 to remind users that they really should be using UTF-8.
What you can do is set a file’s encoding via Apple’s encoding attribute or via .tm_properties — but really, use UTF-8!
TM2 is likely to introduce some heuristics down the road and the current sheets during opening should also be considered provisional, still no excuse not to use UTF-8.
So bottom line: if you want to use cutting-edge alpha builds, don’t use legacy encodings from last century ;)
More information about the textmate