Skip to content

GNOME/gimp-help

Repository files navigation

GIMP-Help

GIMP-Help is a help system designed for use with the internal GIMP help browser, external web browser and HTML renderers.
DocBook is used to create a highly customizable documentation system.

The current manual documents features for the 2.99 development branch of GIMP which is a moving target for the future GIMP 3.0.
The manual for GIMP 2.10 is also still being maintained in a separate branch called gimp-help-2-10.

Contents

  1. Published manuals
  2. Tips for contribution
    2.1 Translating
    2.2 Manual writing
  3. Documentation issues
  4. Creating a Release
  5. Updating supported languages
  6. History of the gimp-help module

Published manuals

The online, daily updated, manuals for all supported languages are available at:

The offline manuals are available for download from the same location. However, they are a lot more outdated.

Tips for contribution

How to help translating the manual

If you are interested in translating the manual the best way to start is going to the DamnedLies translation platform. Register an account there, if you don't have one yet, and apply to be a member of the language team for the language you want to translate.

All our translations are done through DamnedLies. To start translating the manual go to the translatable po files for the manual. After you finish translating, you upload it to DamnedLies. Your language team will be able to give you more details on this procedure.

Note: If your language does not have any po files listed there, your language first needs to be added to our repository. In that case, please open an issue stating which language and languagecode you would like to have added.

How to test your translation

If you have set up a build environment for gimp-help you can test the translation by running make html-LANG, where LANG is your two/four-letter language code. This will generate an HTML version of the user manual, e.g. make html-nl to make the HTML for the Dutch language. When that is successful, you can find the index.html file in the /html/LANG/ folder under your gimp-help build folder.

How to add localized screenshots

As far as I am aware localized images can't be handled directly through DamnedLies. Discuss with your language team what to do first, but in the end they need to be committed to the gimp-help repository, by your language team.

All images are stored in the top-level 'images' folder. Original screenshots in English are in the 'C' subfolder. Localized screenshots are in 'LANG' folders, where LANG is your two/four-letter language code.

It is important to preserve both paths and names when saving localized versions of the screenshots. Otherwise documentation won't build properly, or the localized images will not be used.

More in general, also follow the relevant guidelines regarding image handling.

How to help writing the manual

If instead you would like to help out writing and improving the manual then this is the right place to start.

First, it would be a good idea to subscribe to messages that have the GIMP or documentation tags on Gnome's Discourse server. Note: when asking a question on Discourse make sure you add tags for GIMP and documentation (or i18n if it is related to translations), or we may not see your message.

Most of the GIMP developers can also be reached on the #gimp IRC channel on irc.gimp.org. The best chances to talk are usually during European evening hours.

If some of the instructions below are unclear, don't hesitate to ask in one of the places mentioned above.

To get started, here is a checklist of things you should do:

  • If you don't have a Gnome GitLab account yet then create one (you can use GitHub credentials to login), see: https://gitlab.gnome.org/
  • Next go to https://gitlab.gnome.org/GNOME/gimp-help and create your own fork by clicking on "Fork" on the top right of the page.
  • Go to your fork at https://gitlab.gnome.org/YOUR_USERNAME/gimp-help
  • gimp-help uses a CI pipeline to validate the contents of the repo at each commit. Make sure to setup the CI settings for your fork correctly:
    • Settings > General > Visibility:
      • Set Project visibility to Public
      • Enable Repository with Everyone With Access
      • Enable CI/CD with Everyone With Access
      • Enable Container registry (any visibility level)
    • Settings > CI/CD > General pipelines:
      • Enable Public pipelines
  • Make sure to read our documentation guidelines.
  • For relatively small and simple edits you can use the web-ide if you don't want to set up a build environment on your computer.
    • On the left under Repository click Files, then navigate to the /src/ folder. Find the file you want to work on then click WEB-IDE.
    • I have no personal experience with this, so it's difficult to give further details. Anyway, start editing your file and when ready I assume you have to click save or finish or similar.
    • I assume this will create a new commit. If possible also create a new branch for every change. Make sure you give a descriptivev name to your commit. That way others can understand what your change is about.
    • Make sure the CI pipeline succeeds. Otherwise, inspect the pipeline for the cause of failure and fix it.
    • Next you need to create a Merge Request (MR) for the commit.
    • This MR will show up in the main gimp-help repository and will be reviewed and evaluated.
  • For more complicated edits, reordering parts of the help, or adding screenshots, you should clone the repository to your computer and work on it locally.
    • On your fork of gimp-help click the blue Clone button and choose your preferred method.
    • In case you are on Windows, it is strongly advised to set up a MSYS2 environment, so that you can build and test the gimp-help repository.
    • TODO: Other OS's may need some setting up too. Add details here as needed.
    • TODO: Add details about setting up MSYS2 with required packages for gimp-help.
    • Try to build the English manual without any changes, to make sure everything is set up correctly.
    • Assuming you have cloned the git repo on your computer, make a build dir inside or outside your tree depending on your personal preference, then run from the build dir: ../autogen.sh --prefix=${INSTALL_PREFIX} --without-gimp,
    • TODO: On Windows you may have to add --build=mingw64, possibly also DESTDIR=$BUILD_DIR $SRCDIR.
    • After running autogen once, you can use the following command repeatedly for making the English manual: make html-en.
    • You can check the output in your build dir in the /html/en/ folder.
    • If that is working, select a file from the /src/ folder that you want to work on and start editing.
    • When finished with a set of related edits, you should first validate your changes to check that you didn't make any mistakes in the docbook XML format. The command for this is make validate-en.
    • If everything is fine commit your changes with a descriptive commit message. Make sure you always do related changes in a separate branch.
    • Push your changes to your fork on Gnome GitLab.
    • Make sure the CI pipeline succeeds. Otherwise, inspect the pipeline for the cause of failure and fix it.
    • Go to your online fork and click the Merge Request button.
  • Make sure that you have notifications enabled, because you may be asked to change certain things, or need to explain why you made certain changes.
  • Don't expect a reply immediately. There is only a small team working on this. A review can sometimes take weeks or even months, although we try to get back to you sooner.
  • Some additional info can also be read in the manual, see https://docs.gimp.org/2.10/en/gimp-contributing.html (although some parts there need to be revised).

TODO

  • Mention that make sometimes causes certain po translations to get updated. They should not be committed together with source documentation changes.
  • What packages are required and/or optional to build gimp-help.
  • Add style guide and add link to it here.

Preferably build the most up to date manual yourself or check the latest uploaded version at https://docs.gimp.org/2.10/en/.

The source of the manual can be found in XML files in the /src directory of this repository. Find a topic that interests you or that needs updating and start writing.

You could also take a look at our issue tracker at https://gitlab.gnome.org/GNOME/gimp-help/issues

What you should know

You should know a bit about Docbook and XML, or be smart enough to learn the syntax yourself. You can get more information about Docbook and XML by using your preferred search engine. Also make sure you read our documentation guidelines.

Editors, Programs and Setups

Use any editor that supports editing XML. Please keep in mind, that the tab width in XML Mode should be 2 spaces.

Provided you have xmllint installed, you can validate the XML and check the well-formedness of the XML files by running

make validate-en

Running make validate is also possible, but validating for all languages takes considerable time. Translators are encouraged to validate their language by replacing en above with their language code.

When you edit an XML file and want to quickly check your changes, you can create a single quick-and-dirty HTML draft file with

make src/of/the/xml-file.draft

where the target is the path name with extension ".draft" instead of ".xml", or with

make preview-src/of/the/xml-file.xml

where the path name is preceded with "preview-".

The name of the HTML draft file depends on its id (not on the name of the XML source file!) and is displayed when the file is created.

Hints for making good screenshots

  • Please make screenshots only with the system default theme, which is of course just the plain gtk+ default look - FIXME Nowadays dark mode is often used. Using a dark theme is totally ok to me. If we want a unified look that would mean creating all images on one platform with one chosen theme. At this moment that doesn't seem feasible.
  • Use default fonts like Bitstream Vera Sans - FIXME This is not a crossplatform default font, we need a better suggestion.
  • Crop the window manager borders; or even more if the image is intended to only show a limited set of things that need an explanation.
  • Before saving an image as PNG, check if you can convert it to indexed mode without loss of quality (saves space and bandwidth) FIXME: see pngnq that does that for you including reducing size, but beware for small images size may increase. This also only works well with screenshots that do not show any photos or similar. You have to check first if the resulting image does not differ too much from the original. Maybe tell not to add metadata unless needed, no comment, no thumbnail, maybe also no color profile or is it better to have that included.
  • TODO Add info about the different pngcrush programs pngnq in my tests is often the smallest (default settings), but check if the result isn't too different from the original.
  • Provide your source images (eg. for making new screenshots in other languages) - add info where in the source tree they should be added, info to keep xcf size as small as possible, small image dimensions where possible (64 x 64?) - set "use better but slower compression" when saving to xcf; for most example imagess using 8 bit integer precision is enough, unless specifically demonstrating higher bit depth.

Documentation issues

See our Gnome Gitlab issue tracker:

https://gitlab.gnome.org/GNOME/gimp-help/issues

Creating a Release

Note: this section needs to be updated.

Note2: For make dist and make dist-check automake 1.16.4 or newer is required. Older versions will not recognize README.md as a valid version instead of README.

Before you create a release you'll need:

* be a maintainer
* have ssh access to pentagon.gimp.org
* have access to http://www.gimp.org/admin/
* FIXME: Check if this is still up-to-date.

Steps

  • Make sure that all XML is valid. Run:

    make validate-all

  • Prepare the NEWS file, by adding an additional release, bugs fixed and contributors. You can use a little shortcut for compiling the contributors using git shortlog ( is the tag of the last release):

    git shortlog -sn ..HEAD

  • Note: the above is not always complete for translators since most translations are committed by language team coordinators, not necessarily the persons that did the actual translation.

  • Check if the authors.xml have to be adjusted for this release.

  • Bump the version number (help_(major, minor, micro)_version) in configure.ac, commit, push. Rule of thumb: It should document the current GIMP stable release. The minor version aligns therefore with the current stable release.

    vi configure.ac

  • Create a distribution package:

    make dist

  • Tag the release:

    git tag -s

    Rule of thumb: Use capital case, whitespace delimited by underscores.

  • Copy the *.bz2 on to pentagon.gimp.org:/srv/ftp/pub/gimp/help/:

    scp gimp-help-.tar. pentagon.gimp.org:/srv/ftp/pub/gimp/help/

    Verify the tarball appears on:

    http://download.gimp.org/pub/gimp/help/

  • Add the Windows installers

  • Update our websites: docs.gimp.org and gimp.org/docs

  • Announce the release on http://www.gimp.org/admin/. Click on Pending NewsNew News, fill in the form (subject, announce), choose a reading wilber and press Save. Depending if it needs review (ask one of the developers), approve it to publish it.

  • Announce the release on Discourse using gimp and documentation tags:

    Discourse https://discourse.gnome.org/

    Template:

    GIMP Manual <version> released
    
    We've released a new version of the user manual with:
    
      * <Changelog here>
    
    Download the packages from our download software.
    

    For easy installation we suggest that you wait until an installer for this release has been packaged for your platform. Find more releases and information about our goals and how you can help at https://docs.gimp.org.

Updating supported languages

When adding a new language for translation several files need to be updated. It's the intention to simplify this, but for now the list of languages needs to be updated in the following files:

Note: If your build directory is not a child of the source directory, then msginit will not fill in PACKAGE_VERSION in the header of the po files.
Since msginit tries to find configure, copying that to your build directory can solve that issue. In that case, make sure to update it when switching branches.

When all of the above are updated, run:

  • make po in the main build directory
  • make po in the quickreference directory
  • make update-po in the po-windows-installer directory (make sure that charset is UTF-8 here, it wasn't for me, need to check this sometime)

This should create the necessary po files for the newly added language.
Note: some po files for other languages may have been updated too, but you should only commit the files relevant for the new language.

History of the gimp-help module

The development on the original gimp-help modules came pretty much to a stop after the first few stable versions of GIMP 1.2 were released. This is due to several reasons, one of them being that all of the original documentation had been converted from HTML to DocBook/SGML and apart from a bit new content, lots of markup and proofreading not too much happened to the organization of the complete mess.

Daniel Egger and Mel Boyce were not too happy about the quirks with this help system. So they started completely from scratch creating a new manual based on Docbook/XML called gimp-help-2.

Later this was renamed to gimp-help.