Class: GtkSource::SnippetContext
- Inherits:
-
Object
- Object
- GtkSource::SnippetContext
- Defined in:
- (unknown)
Instance Method Summary collapse
-
#clear_variables ⇒ nil
Removes all variables from the context.
- #expand(input) ⇒ String
-
#get_variable(key) ⇒ String
Gets the current value for a variable named key.
-
#initialize ⇒ GtkSource::SnippetContext
constructor
Creates a new Gtk::SourceSnippetContext.
- #line_prefix=(line_prefix) ⇒ nil
-
#set_constant(key, value) ⇒ nil
Sets a constatnt within the context.
-
#set_variable(key, value) ⇒ nil
Sets a variable within the context.
- #tab_width=(tab_width) ⇒ nil
- #use_spaces=(use_spaces) ⇒ nil
Constructor Details
#initialize ⇒ GtkSource::SnippetContext
Creates a new Gtk::SourceSnippetContext.
Generally, this isn't needed unless you are controlling the expansion of snippets manually.
Instance Method Details
#clear_variables ⇒ nil
Removes all variables from the context.
#expand(input) ⇒ String
#get_variable(key) ⇒ String
Gets the current value for a variable named key.
#line_prefix=(line_prefix) ⇒ nil
#set_constant(key, value) ⇒ nil
Sets a constatnt within the context.
This is similar to a variable set with [methodSnippetContext.set_variable] but is expected to not change during use of the snippet.
Examples would be the date or users name.
#set_variable(key, value) ⇒ nil
Sets a variable within the context.
This variable may be overridden by future updates to the context.