Tuesday, April 12, 2011

Adding new file type to Xcode

This will help you get color syntax on .txx files:

Create a file
/Users/isa/Library/Application Support/Apple/Developer Tools/Specifications/TXX.pbfilespec
or
/Library/Application Support/Apple/Developer Tools/Specifications/TXX.pbfilespec

containing the following

(
        {
            Identifier = sourcecode.cpp.tpp;
            BasedOn = sourcecode.cpp.cpp;
            Extensions = (txx);
            ComputerLanguage = c;
            AppliesToBuildRules = yes;
            IncludeInIndex = NO;
            CanSetIncludeInIndex = NO;
        },
)

You may need to re-add sources or regenerate project file