Old API changes for gedit plugins
For later versions of gedit
See the gtk-doc reference manual of gedit, there is a section that lists the API breaks.
Note that https://developer.gnome.org/gedit/ is outdated, it is no longer updated since the port of the build system to Meson.
For gedit 3.14
Due to a new file loading and saving API in GtkSourceView, there are some changes in the gedit API, mainly in GeditDocument.
If your plugin relies on some of the removed API, and if it is not possible to use GtkSourceFile, explain your use case and we'll see what we can do.
GeditEncoding has been removed, use GtkSourceEncoding instead.
- New functions:
- gedit_document_get_file()
- gedit_commands_save_document_async()
- gedit_commands_save_document_finish()
The following GeditDocument functions have been removed:
- gedit_document_load()
- gedit_document_load_stream()
- gedit_document_load_cancel()
- gedit_document_save()
- gedit_document_save_as()
The GeditDocumentCompressionType and GeditDocumentNewlineType enums have been removed, use the enums available in GtkSourceFile instead.
The GeditDocument "loading" and "saving" signals (used for progress info) have been removed.
All the parameters of the GeditDocument "load" and "save" signals have been removed.
The error parameters of the GeditDocument "loaded" and "saved" signals have been removed. For saving a document and get the result of the operation, you can use gedit_commands_save_document_async() and gedit_commands_save_document_finish().
The following properties in GeditDocument have been removed: "compression-type", "newline-type", "encoding" and "location".
- The following functions are deprecated:
- gedit_document_get_location()
- gedit_document_set_location()
- gedit_document_get_encoding()
- gedit_document_get_newline_type()
- gedit_document_get_compression_type()
For gedit 3.12
Due to the new design of gedit, some plugins need to be ported.
There is a new menu system, see this commit for an example on how to port a plugin. See this file for the sections of the menus you can use.
The search and replace API in GeditDocument was deprecated, and has been removed in gedit 3.12. Use the GtkSourceView API (the GtkSourceSearchContext and GtkSourceSearchSettings classes).
For gedit 3.8
Python plugins must be ported to Python 3 to work on gedit 3.8 and above. Usually this is not hard.