After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 652782 - Improvement of the gtksourceview lang documentation
Improvement of the gtksourceview lang documentation
Status: RESOLVED FIXED
Product: gtksourceview
Classification: Platform
Component: General
unspecified
Other All
: Normal enhancement
: ---
Assigned To: GTK Sourceview maintainers
GTK Sourceview maintainers
Depends on:
Blocks:
 
 
Reported: 2011-06-16 21:50 UTC by Carnë Draug
Modified: 2013-11-24 15:45 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Doc: some rules for language definition files (2.00 KB, patch)
2013-11-23 16:25 UTC, Sébastien Wilmet
accepted-commit_now Details | Review
Complete lang-reference documentation (4.58 KB, patch)
2013-11-23 16:25 UTC, Sébastien Wilmet
accepted-commit_now Details | Review

Description Carnë Draug 2011-06-16 21:50:54 UTC
Hi

the reference documentation to create new language files is a bit outdated. To start with it would be nice to list some of the developers preferences to them. I'm opening this bug report to myself as I plan on doing it myself in the future

Here's a list of things that needs to be added, please feel free to add to them:

--missing on the reference
  * class and class disable (comment, string, no-spell-check)
  * this value for 'original' (or something similar that I saw once to make invalid a replace tag)

-- devs preferences
 * have a main context at the bottom
 * 2 space indetation
 * use ref to def.lang
 * must be LGPL to be accepted
 * add e-mail for contact of original lang file developer
Comment 1 Ignacio Casal Quinteiro (nacho) 2011-06-19 20:21:36 UTC
I totally agree about this.
Comment 2 Sébastien Wilmet 2013-11-23 16:25:05 UTC
Created attachment 261302 [details] [review]
Doc: some rules for language definition files

The list is added in the reference, not the tutorial. The tutorial is
read once, after that the people use the reference.
Comment 3 Sébastien Wilmet 2013-11-23 16:25:10 UTC
Created attachment 261303 [details] [review]
Complete lang-reference documentation

- Like <match>, <start> and <end>, the <define-regex> tag can have regex
options attributes (e.g.  "extended" or "case-sensitive").

- Context classes (string, comment, no-spell-check)

- The "original" attribute for a reference context.
Comment 4 Paolo Borelli 2013-11-24 15:29:11 UTC
Review of attachment 261302 [details] [review]:

::: docs/reference/lang-reference.xml
@@ -35,1 +35,2 @@
 <refsect1>
+<title>Some rules</title>

maybe "rules" is a bit too strong. What about "Best practices"?


Other than that sure, go ahead
Comment 5 Paolo Borelli 2013-11-24 15:29:59 UTC
Review of attachment 261303 [details] [review]:

looks good
Comment 6 Sébastien Wilmet 2013-11-24 15:45:45 UTC
> maybe "rules" is a bit too strong. What about "Best practices"?

Yes, it's better.

The commits are pushed.