Using QTM's D-Bus interface
D-Bus is a system for facilitating communication between programs, and is used by the Unix desktops GNOME and KDE 4. This information is not useful to users of QTM; it is intended for developers who want their programs to communicate with QTM. Particular targets are developers of web browsers and RSS feed readers.
To see the D-Bus specification, including its data types, click here.
QTM's service and interface names are both uk.co.blogistan.catkin, the same as for QTM preferences purposes.
QTM exports three properties:
- organizationName - The "organisation" behind QTM
- organizationDomain - catkin.blogistan.co.uk
- applicationVersion - Returns the current version of QTM
The following methods are also available:
- getQuickpostTemplateTitles - Returns a string array containing a list of the titles of the available templates, formatted n.[title], where n is the number of the template
- getQuickpostTemplates - Returns a string array containing a list of the available templates, with titles, formatted n.[title].[template_content] - newlines and closing square brackets are escaped as \n and \] respectively.
- newDocumentWithTitleAndText - takes two arguments, both strings, title and text, representing the title and content of the entry respectively.
- quickpost - takes two arguments, both strings; url contains the web location and content contains the material to be fed to quickpost. A template will be applied if the 'url' argument contains a user-defined associated host string.
- newDocument - opens a blank new document
- open - opens a saved entry from the filesystem. Takes one argument, 'path', containing the full path of the file to be opened.