【发布时间】:2012-10-25 06:43:07
【问题描述】:
我正在尝试在 Sublime Text 2 中创建一个 Objective-C sn-p。我想定义 sn-p 的范围,以便 sn-p 在所有 Objective-C 文件中都可用。
但我就是找不到 Objective-C 的范围选择器。这是我的sn-p...
<snippet>
<content><![CDATA[
- (void)didRotateFromInterfaceOrientation:(UIInterfaceOrientation)fromInterfaceOrientation
{
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>objdid</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<!-- <scope>source.html</scope> -->
</snippet>
我尝试了.m、.h、.Objective-C、.objective-c 等范围,但没有任何效果。像上面一样保存 sn-p 会使 sn-p 在所有文件中弹出,无论是 .txt 还是其他任何文件。
【问题讨论】:
标签: code-snippets sublimetext2