[gtk+] Document @binding-set and the gtk-key-bindings css parser property



commit c70b65f0eb651cfbb4154f2b1b35cc1359db3e91
Author: Carlos Garnacho <carlosg gnome org>
Date:   Fri Jan 28 10:25:17 2011 +0100

    Document @binding-set and the gtk-key-bindings css parser property

 gtk/gtkcssprovider.c |   29 +++++++++++++++++++++++++++++
 1 files changed, 29 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkcssprovider.c b/gtk/gtkcssprovider.c
index 95e3807..df80587 100644
--- a/gtk/gtkcssprovider.c
+++ b/gtk/gtkcssprovider.c
@@ -291,6 +291,28 @@
  * </programlisting>
  * </example>
  * <para>
+ * In order to extend key bindings affecting different widgets, GTK+
+ * supports the &commat;binding-set rule to parse a set of bind/unbind
+ * directives, see #GtkBindingSet for the syntax supported
+ * </para>
+ * <example>
+ * <title>Using the &commat;binding rule</title>
+ * <programlisting language="text">
+ * &commat;binding-set binding-set1 {
+ *   bind "&lt;alt&gt;Left" { "move-cursor" (visual-positions, -3, 0) };
+ *   unbind "End";
+ * };
+ *
+ * &commat;binding-set binding-set1 {
+ *   bind "&lt;alt&gt;Right" { "move-cursor" (visual-positions, 3, 0) };
+ * };
+ *
+ * GtkEntry {
+ *   gtk-binding-set: binding-set1, binding-set2;
+ * }
+ * </programlisting>
+ * </example>
+ * <para>
  * GTK+ also supports an additional &commat;define-color rule, in order
  * to define a color name which may be used instead of color numeric
  * representations. Also see the #GtkSettings:gtk-color-scheme setting
@@ -666,6 +688,13 @@
  * transition: 1s linear loop;</literallayout>
  *         </entry>
  *       </row>
+ *       <row>
+ *         <entry>gtk-key-bindings</entry>
+ *         <entry>binding set name list</entry>
+ *         <entry>internal use only</entry>
+ *         <entry><literallayout>gtk-bindings: binding1, binding2, ...;</literallayout>
+ *         </entry>
+ *       </row>
  *     </tbody>
  *   </tgroup>
  * </informaltable>



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