[TxMt] Re: Need help with custom language highlightning
nuke
sila.razuma at gmail.com
Mon Jun 7 09:59:48 UTC 2010
I do select Serpent language explicitly (or it is detected by the file
extension). The PHP insertions are not highlighted. However, if I select PHP
language, they are. So I am very confused. My guess is I need to do
something extra in addition to the simplest language definition I am using
now:
{ scopeName = 'source.serpent';
fileTypes = ( 'serpent' );
patterns = (
{ begin = '<\?';
end = '\?>';
patterns = ( { include = 'source.php'; } );
},
);
}
On Mon, Jun 7, 2010 at 11:04, Allan Odgaard <mailinglist at textmate.org>wrote:
> On 4 Jun 2010, at 15:49, nuke wrote:
>
> Could you help me to make a custom language colorization!
>> [...] What do I need to do?
>>
>
> In addition to creating a new language grammar you also need to select to
> use it for your file (in your case it should be automatically chosen for
> files with ‘serpent’ extension). This is done by using the status bar
> language selector.
>
> Your grammar doesn’t do anything though (other than include PHP), so
> selecting it wouldn’t be different to selecting PHP directly, except the
> root scope will be different (which you can check with ⌃⇧P).
>
> Perhaps though your issue is more with embedding of things in HTML. You
> should probably have a look at this page
> http://wiki.macromates.com/Troubleshooting/PHPSyntaxHighlight
>
>
> _______________________________________________
> textmate mailing list
> textmate at lists.macromates.com
> http://lists.macromates.com/listinfo/textmate
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macromates.com/textmate/attachments/20100607/7e34ab4c/attachment.html>
More information about the textmate
mailing list