Sophie

Sophie

distrib > Fedora > 14 > x86_64 > media > updates > by-pkgid > 602241b8321661130683fd3b8e2d3965 > files > 6

latexila-2.0.8-1.fc14.x86_64.rpm

Guidelines for LaTeXila
=======================

LaTeXila source code is maintained using the Git version control system and is
available at the following location:

    git://git.gnome.org/latexila

A Web Interface is available at:

    http://git.gnome.org/browse/latexila

You can download the source code from the Git repository by doing:

    $ git clone git://git.gnome.org/latexila

Later, to take the new commits you just have to do:

    $ git pull


If you want to contribute to LaTeXila, contact the main developer (see the
file AUTHORS).

To create a patch, make first one or several commits (in another branch) and
then use the 'git format-patch' command. You can submit your patch to the
GNOME bugzilla.

Alternatively, if you have a GitHub account, you can make a pull request.
A GitHub repository is available, so you can fork it easily:

    https://github.com/swilmet/latexila

There are some rules to follow when coding:
    - indentation: 4 spaces
    - lines: 90 characters maximum (in some cases it can be a little more)
    - no trailing spaces
    - /* ... */ comments for delimiting code sections
    - // ... comments otherwise (e.g. for explaining just one line)
    - some spaces almost everywhere:
        - function (blah);                // not function(blah);
        - int num = 5;                    // not int num=5;
        - if (! foo)                      // not if (!foo)
        - for (int i = 0 ; i < max ; i++) // not for(int i=0;i<max;i++)
        - etc...
    - do not use 'var' for declaring variables, unless the type is very long
    - same coding style everywhere

How to generate the C code from Vala files?
    See the file "INSTALL".

How to debug LaTeXila with gdb?
    If you are using the master branch, the debug stuff is enabled by default.
    Here is how you can get the backtrace after a crash:

    $ gdb ./latexila
    > run
    [segmentation fault]
    > bt

    The debug stuff is disabled in the releases-* branches.


Translations
============

How to generate latexila.pot?

    $ ./update_pot.sh

How to update the *.po files with latexila.pot file?

    $ cd build/ ; cmake ../
    $ make translations

How to create a new *.po for a new language?

    A lot of sentences are the same as in Gedit, so you can avoid
    re-translating them:
        - download Gedit 2.30 sources:
          http://ftp.acc.umu.se/pub/GNOME/sources/gedit/2.30/
        - take the Gedit *.po of your language and copy it in the po/ directory
        - update the *.po files with latexila.pot (see above)
        - at the end of the *.po file, you'll see a lot of lines commented
          (i.e. beginning with #). That's all the sentences from Gedit that are
          not present in LaTeXila. You can remove these lines.

    Anyway, if you want to create a completely new *.po, you can do:
    $ cd po/ ; msginit -l xx -o xx.po -i latexila.pot

How to translate LaTeXila?

    When someone begins translating LaTeXila, an announcement is made on the
    Mailing List. So to avoid duplicated work, make sure nobody else is already
    translating LaTeXila in your language. If it's not the case, then you can
    make the announcement. You can find the link to the Mailing List there:

        http://projects.gnome.org/latexila/#contact

    The first thing to do is to take the *.po file from Gedit (see above). When
    it's done, you can use Poedit for example to complete the translation. Here
    are some strange items to translate:
        - translator-credits: Your name <your@email> (so your name will appear
          in the about dialog)

        Templates:
        - article-en.tex: article-xx.tex ("en" stands for English)
        - beamer-en.tex: beamer-xx.tex
        - book-en.tex: book-xx.tex
        - letter-en.tex: letter-xx.tex
        - report-en.tex: report-xx.tex

        Build Tools:
        - build_tools-en.xml: build_tools-xx.xml

        You will see a lot of items with an underscore. It's used for
        shortcuts (Alt + Letter underlined). If possible it is better to avoid
        having several times the same letter in the same menu.

    There is also the templates to translate in data/templates/ and the build
    tools in data/build_tools/. For the templates, add support for your
    language (in most cases add the babel package).

    Finally, there are two little sentences in data/latexila.desktop.

    Thanks!