-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Snippets: Add common pragma names & values as snippets
This is worse than a completion that could be provided by a plugin or an LSP, but until LSP is developed enough to be useful for KDE, this should be good enough for common use-cases.
- Loading branch information
Showing
8 changed files
with
70 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
Snippets/qml_pragma_ComponentBehavior_Bound.sublime-snippet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<snippet> | ||
<!-- Note: The extra line break is intentional --> | ||
<!-- See also: qtdeclarative/src/qmlcompiler/qqmljsimportvisitor.cpp --> | ||
<content><![CDATA[ | ||
pragma ComponentBehavior: Bound | ||
]]></content> | ||
<tabTrigger>pragma ComponentBehavior: Bound</tabTrigger> | ||
<scope>source.qml - meta.block.qml</scope> | ||
<description>pragma</description> | ||
</snippet> |
11 changes: 11 additions & 0 deletions
11
Snippets/qml_pragma_FunctionSignatureBehavior_Enforced.sublime-snippet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<snippet> | ||
<!-- Note: The extra line break is intentional --> | ||
<!-- See also: qtdeclarative/src/qmlcompiler/qqmljsimportvisitor.cpp --> | ||
<content><![CDATA[ | ||
pragma FunctionSignatureBehavior: Enforced | ||
]]></content> | ||
<tabTrigger>pragma FunctionSignatureBehavior: Enforced</tabTrigger> | ||
<scope>source.qml - meta.block.qml</scope> | ||
<description>pragma</description> | ||
</snippet> |
11 changes: 11 additions & 0 deletions
11
Snippets/qml_pragma_ListPropertyAssignBehavior.sublime-snippet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<snippet> | ||
<!-- Note: The extra line break is intentional --> | ||
<!-- See also: qtdeclarative/src/qmlcompiler/qqmljsimportvisitor.cpp --> | ||
<content><![CDATA[ | ||
pragma ListPropertyAssignBehavior:${1: Append}${2: Replace}${3: ReplaceIfNotDefault} | ||
]]></content> | ||
<tabTrigger>pragma ListPropertyAssignBehavior:</tabTrigger> | ||
<scope>source.qml - meta.block.qml</scope> | ||
<description>pragma</description> | ||
</snippet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<snippet> | ||
<!-- Note: The extra line break is intentional --> | ||
<!-- See also: qtdeclarative/src/qmlcompiler/qqmljsimportvisitor.cpp --> | ||
<content><![CDATA[ | ||
pragma Singleton | ||
]]></content> | ||
<tabTrigger>pragma Singleton</tabTrigger> | ||
<scope>source.qml - meta.block.qml</scope> | ||
<description>pragma</description> | ||
</snippet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<snippet> | ||
<!-- Note: The extra line break is intentional --> | ||
<!-- See also: qtdeclarative/src/qmlcompiler/qqmljsimportvisitor.cpp --> | ||
<content><![CDATA[ | ||
pragma Strict | ||
]]></content> | ||
<tabTrigger>pragma Strict</tabTrigger> | ||
<scope>source.qml - meta.block.qml</scope> | ||
<description>pragma</description> | ||
</snippet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<snippet> | ||
<!-- Note: The extra line break is intentional --> | ||
<!-- See also: qtdeclarative/src/qmlcompiler/qqmljsimportvisitor.cpp --> | ||
<content><![CDATA[ | ||
pragma ValueTypeBehavior: ${1:Copy}${2:, Reference}${3:, Addressable}${4:, Inaddressable} | ||
]]></content> | ||
<tabTrigger>pragma ValueTypeBehavior:</tabTrigger> | ||
<scope>source.qml - meta.block.qml</scope> | ||
<description>pragma</description> | ||
</snippet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters