Create  Edit  FrontPage  Index  Search  Changes  History  RSS  Login

Gtk::SourceLanguageManager

class Gtk::SourceLanguageManager

Gtk SourceLanguageManager is an object which provides access to GtkSourceLanguages. It processes language description files, creates and stores SourceLanguage objects, and provides *simple APIs* to access them.

It is quite useful to apply to Gtk::SourceView.

Use #guess_language to get a SourceLanguage for the given file name and content type.

Class Methods

Gtk::SourceLanguageManager.default
  • Returns: self: FIXME
Gtk::SourceLanguageManager.new
  • Returns: self: FIXME

This can be used to obtain colours for a specific language. Example for Ruby:

ruby_lang = Gtk::SourceLanguageManager.new.get_language('ruby')

Instance Methods

get_language
  • Returns: self: FIXME
guess_language
  • Returns: self: FIXME
language_ids
Gets the List of the ids of the available languages.
  • Returns: List of the ids of the available languages
search_path
Gets the List of directories where the language specification files (.lang) are located.
  • Returns: List of directories where the language specification files (.lang) are located
search_path=(search_path)
Sets the List of directories where the language specification files (.lang) are located.
  • search_path: List of directories where the language specification files (.lang) are located
  • Returns: search_path
set_search_path(search_path)
Same as search_path=.
  • search_path: List of directories where the language specification files (.lang) are located
  • Returns: self

Properties

language-ids: Array (Read)
List of the ids of the available languages
search-path: Array (Read/Write)
List of directories where the language specification files (.lang) are located
Last modified:2011/08/29 23:06:08
Keyword(s):
References:[Gtk::SourceLanguageManager] [index-ruby-gtk2]