[gedit] docs: add gedit-development-getting-started



commit 1a7bc37dbc66ce3f5f4a7cd679075e2010642b7a
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Sun Aug 25 10:55:17 2019 +0200

    docs: add gedit-development-getting-started
    
    Based on (written several years ago by me):
    https://wiki.gnome.org/Apps/Gedit/DevGettingStarted
    
    But adapted and updated. And rewritten in Markdown so that GitLab can
    render it.
    
    I've added some TODO comments in the text, I have the intention to write
    other pages.

 docs/gedit-development-getting-started.md | 102 ++++++++++++++++++++++++++++++
 1 file changed, 102 insertions(+)
---
diff --git a/docs/gedit-development-getting-started.md b/docs/gedit-development-getting-started.md
new file mode 100644
index 000000000..4a180f12b
--- /dev/null
+++ b/docs/gedit-development-getting-started.md
@@ -0,0 +1,102 @@
+gedit development - getting started
+===================================
+
+The following explanations can be improved over time, if you see something
+missing.
+
+Programming languages and paradigms
+-----------------------------------
+
+gedit is mostly written in C, with some plugins in Python or
+[Vala](https://wiki.gnome.org/Projects/Vala/). The build system is in
+[Meson](https://mesonbuild.com/).
+
+The code is object-oriented and event-driven. In C, it's thanks to the use of
+the GObject library (see next section). If you open some `*.c` or `*.h` files,
+you may think “what is this horror?!” but – don't panic – it's just some
+C/GObject boilerplate code, and that boilerplate can be generated by a tool. So
+once you've learned GObject, you will no longer be afraid ;-)
+
+Libraries used
+--------------
+
+As every GNOME application, gedit uses the GLib, GObject and GTK libraries. To
+modify the gedit source code, you should be familiar with those libraries. See
+the [GTK website](https://www.gtk.org/) and the document
+[The GLib/GTK Development Platform – A Getting Started 
Guide](https://people.gnome.org/~swilmet/glib-gtk-book/).
+
+The main widget used by gedit is GtkTextView, a general-purpose multiline text
+editor. To learn that widget API, read the excellent
+[GtkTextView tutorial](http://www.bravegnu.org/gtktext/) (a bit old but still
+mostly valid). But GtkTextView is not enough for source code edition. gedit
+actually uses the
+[GtkSourceView](https://wiki.gnome.org/Projects/GtkSourceView) library, which
+contains a subclass of GtkTextView with syntax highlighting, a completion
+framework, the search and replace, and many other features useful for a text
+editor or an IDE.
+
+For its plugin system, gedit uses the
+[libpeas](https://wiki.gnome.org/Projects/Libpeas) library.
+
+Plugins may have other dependencies, for example the spell-checking plugin uses
+[gspell](https://wiki.gnome.org/Projects/gspell).
+
+gedit architecture
+------------------
+
+The [gedit Git repository](https://gitlab.gnome.org/GNOME/gedit) contains the
+_gedit core_ plus the default plugins. There is also the
+[gedit-plugins Git repository](https://gitlab.gnome.org/GNOME/gedit-plugins)
+for additional official plugins. The gedit core source code is in the `gedit/`
+directory. The plugins are in … `plugins/`!
+
+gedit core provides:
+- A basic text editor.
+- The integration of libpeas, with an API for plugins.
+
+There is a class diagram of gedit core in the file `class-diagram.dia` (but it
+may be outdated, see the Git log for that file).
+
+Build
+-----
+
+To compile the gedit source code from the Git repository, plus all the GNOME
+dependencies from Git as well, it is recommended to use one of the following
+build tool:
+- [Jhbuild](https://developer.gnome.org/jhbuild/unstable/)
+- Or [BuildStream](https://buildstream.build/)
+- Or [Flatpak](https://flatpak.org/)
+
+Jhbuild tips:
+- Try `ignore_suggests = True` in your jhbuildrc to have fewer dependencies to
+  build (see the difference with "jhbuild list gedit"). Another solution is to
+  put some modules in the skip variable in jhbuildrc.
+- Build also the dconf module to get preferences saved.
+
+First contribution
+------------------
+
+See the [Newcomers](https://wiki.gnome.org/Newcomers/) page to start
+contributing to GNOME in general.
+
+To know how to contribute to gedit specifically, read the `README.md` and
+`HACKING` files present in the Git repository.
+
+To find something interesting to do, […]. TODO: provide list of easy tasks in
+gedit itself.
+
+A good way to learn a lot of things is to write a new plugin (as a third-party
+plugin first). TODO: provide list of new plugins ideas.
+
+A potentially easy task (but not always) is to fix compilation warnings, for
+example when a deprecated function is used. If you encounter a runtime warning
+or critical message, it is also a good idea to fix it.
+
+Improvements to the documentation (for users or developers) or the wiki is also
+useful.
+
+Interesting article to read, written by a GNOME developer:
+[Working on Free Software](http://ometer.com/hacking.html)
+
+Happy hacking!\
+the gedit developers.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]