[gtksourceview] docs: add links to GRegex and Regular expression syntax page



commit 64b63a15d8a519d631632827abea703ff4bc113b
Author: Sébastien Wilmet <swilmet gnome org>
Date:   Fri Jun 3 11:04:59 2016 +0200

    docs: add links to GRegex and Regular expression syntax page
    
    It doesn't seem possible to link to the glib-regex-syntax page in a
    better manner.
    
    This doesn't work:
    [Regular expression syntax][glib-regex-syntax]
    
    So a simple link is better than "look at the page titled <foo> in the
    GLib reference manual".
    
    And in Devhelp when we click on the link, it is smart enough to stay in
    Devhelp and find the right page in the GLib book. So it is not that bad.
    I hope the URL will not be modified every 5 years.
    
    Thanks to Stefan Salewski for pointing out the missing info.

 docs/reference/lang-reference.xml       |   29 ++++++++++++++++++-----------
 gtksourceview/gtksourcesearchsettings.c |    4 ++++
 2 files changed, 22 insertions(+), 11 deletions(-)
---
diff --git a/docs/reference/lang-reference.xml b/docs/reference/lang-reference.xml
index 71cbf44..59dd005 100644
--- a/docs/reference/lang-reference.xml
+++ b/docs/reference/lang-reference.xml
@@ -414,17 +414,24 @@ Contained elements:
 <title>Tag <code>&lt;define-regex&gt;</code></title>
 
 <para>
-Defines a regular expression that can be reused inside other regular
-expression, to avoid replicating common portions.  Those regular
-expressions are PCRE regular expressions in the form <code>/regex/options</code> (see
-the documentation of PCRE for details). If there are no options to be
-specified and you don't need to match the spaces at the start and at the
-end of the regular expression, you can omit the slashes, putting here only
-<code>regex</code>.  The possible options are those specified above in the description
-of the <code>&lt;default-regex-options&gt;</code> element. To disable a group of
-options, instead, you have to prepend an hyphen <code>-</code> to them.  In
-GtkSourceView are also available some extensions to the standard Perl style
-regular expressions:
+The syntax highlighting engine of GtkSourceView uses
+<link linkend="GRegex"><type>GRegex</type></link>,
+which uses the PCRE library. See the
+<ulink url="https://developer.gnome.org/glib/stable/glib-regex-syntax.html";>Regular expression syntax</ulink>
+page in the GLib reference manual.
+</para>
+
+<para>
+The <code>&lt;define-regex&gt;</code> tag defines a regular expression that can
+be reused inside other regular expression, to avoid replicating common portions.
+Those regular expressions are in the form <code>/regex/options</code>.  If there
+are no options to be specified and you don't need to match the spaces at the
+start and at the end of the regular expression, you can omit the slashes,
+putting here only <code>regex</code>.  The possible options are those specified
+above in the description of the <code>&lt;default-regex-options&gt;</code>
+element. To disable a group of options, instead, you have to prepend an hyphen
+<code>-</code> to them.  In GtkSourceView are also available some extensions to
+the standard Perl style regular expressions:
 </para>
 
 <itemizedlist>
diff --git a/gtksourceview/gtksourcesearchsettings.c b/gtksourceview/gtksourcesearchsettings.c
index 9aaf36d..b24b869 100644
--- a/gtksourceview/gtksourcesearchsettings.c
+++ b/gtksourceview/gtksourcesearchsettings.c
@@ -453,6 +453,10 @@ gtk_source_search_settings_get_wrap_around (GtkSourceSearchSettings *settings)
  * If enabled, the #GtkSourceSearchSettings:search-text property contains the
  * pattern of the regular expression.
  *
+ * #GtkSourceSearchContext uses #GRegex when regex search is enabled. See the
+ * [Regular expression syntax](https://developer.gnome.org/glib/stable/glib-regex-syntax.html)
+ * page in the GLib reference manual.
+ *
  * Since: 3.10
  */
 void


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