This file is indexed.

/usr/share/gtk-doc/html/pygtksourceview2/class-gtksourcegutter2.html is in python-gtksourceview2 2.10.1-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>gtksourceview2.Gutter</title><link rel="stylesheet" href="style.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.75.2"><link rel="home" href="index.html" title="PyGtksourceview2 Reference Manual"><link rel="up" href="index.html" title="PyGtksourceview2 Reference Manual"><link rel="prev" href="class-gtksourcebuffer2.html" title="gtksourceview2.Buffer"><link rel="next" href="class-gtksourcelanguage2.html" title="gtksourceview2.Language"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">gtksourceview2.Gutter</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="class-gtksourcebuffer2.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="class-gtksourcelanguage2.html">Next</a></td></tr></table><hr></div><div class="refentry" title="gtksourceview2.Gutter"><a name="class-gtksourcegutter2"></a><div class="titlepage"></div><div class="refnamediv"><h2>gtksourceview2.Gutter</h2><p>gtksourceview2.Gutter — Mark object for gtksourceview.SourceView</p></div><div class="refsect1" title="Synopsis"><a name="idp6301136"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">gtksourceview2.Gutter</span></span>(<span class="ooclass"><span class="classname"><a
href="../pygobject/class-gobject.html"
>gobject.GObject</a></span></span>):
<code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--get-window" title="gtksourceview2.Gutter.get_window">get_window</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--insert" title="gtksourceview2.Gutter.insert">insert</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>position</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--queue-draw" title="gtksourceview2.Gutter.queue_draw">queue_draw</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--remove" title="gtksourceview2.Gutter.remove">remove</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--reorder" title="gtksourceview2.Gutter.reorder">reorder</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>position</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--set-cell-data-func" title="gtksourceview2.Gutter.set_cell_data_func">set_cell_data_func</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func_data</code></strong></span><span class="initializer">=None</span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--set-cell-size-func" title="gtksourceview2.Gutter.set_cell_size_func">set_cell_size_func</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func_data</code></strong></span><span class="initializer">=None</span></span>)</code><br></pre></td></tr></table></div><div class="refsect1" title="Ancestry"><a name="idp9581632"></a><h2>Ancestry</h2><pre class="synopsis">+-- <a
href="../pygobject/class-gobject.html"
>gobject.GObject</a>
    +-- <a class="link" href="class-gtksourcegutter2.html" title="gtksourceview2.Gutter">gtksourceview2.Gutter</a>
</pre></div><div class="refsect1" title="Properties"><a name="idp9585696"></a><h2>Properties</h2><div class="blockquote"><table width="100%" border="0" bgcolor="#E0E0E0"><tr><td valign="top"><div class="informaltable"><table width="100%" border="0"><colgroup><col width="1in"><col width="1in"><col width="4in"></colgroup><tbody><tr valign="top"><td valign="top">"view"</td><td valign="top">Read-Write-Construct Only</td><td valign="top">
                The <a class="link" href="class-gtksourceview2.html" title="gtksourceview2.View"><code class="classname">gtksourceview2.View</code></a> of the gutter.
              </td></tr><tr valign="top"><td valign="top">"window-type"</td><td valign="top">Read-Write-Construct Only</td><td valign="top">
                The text window type on which the window is placed. Default value: gtk.TEXT_WINDOW_PRIVATE.
              </td></tr></tbody></table></div></td></tr></table></div></div><div class="refsect1" title="Signal Prototypes"><a name="idp10265200"></a><h2>Signal Prototypes</h2><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><a class="link" href="class-gtksourcegutter2.html#signal-gtksourcegutter--cell-activated" title='The "cell-activated" gtksourceview2.Gutter Signal'>"cell-activated"</a></span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>gutter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>renderer</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>iter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>event</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr><tr><td><p><span class="term"><a class="link" href="class-gtksourcegutter2.html#signal-gtksourcegutter--query-tooltip" title='The "query-tooltip" gtksourceview2.Gutter Signal'>"query-tooltip"</a></span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>gutter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>renderer</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>iter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>tooltip</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></td></tr></tbody></table></div><div class="refsect1" title="Description"><a name="description-gtktextgutter"></a><h2>Description</h2><p>
    The <a class="link" href="class-gtksourcegutter2.html" title="gtksourceview2.Gutter"><code class="classname">gtksourceview2.Gutter</code></a>
    object represents the left and right gutters of the text view. It is used by
    <a class="link" href="class-gtksourceview2.html" title="gtksourceview2.View"><code class="classname">gtksourceview2.View</code></a>
    to draw the line numbers and category marks that might be present on a line.
    By packing additional
    <code class="classname">gtk.CellRenderer</code>
    objects in the gutter, you can extend the gutter by your own custom drawings. 
    
  </p><p>
    The gutter works very much the same way as cells rendered in a
    <code class="classname">gtk.TreeView</code>.
    The concept is similar, with the exception that the gutter does not have an
    underlying <code class="classname">gtk.TreeModel</code>.
    Instead, you should use
    <code class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--set-cell-data-func" title="gtksourceview2.Gutter.set_cell_data_func">gtksourceview2.Gutter.set_cell_data_func</a></code>()
    to set a callback to fill in any of the cell renderers properties, given the
    line for which the cell is to be rendered. Renderers are inserted into the gutter
    at a certain position. The builtin line number renderer is at position
    GTK_SOURCE_VIEW_GUTTER_POSITION_LINES (-30) and the marks renderer is at
    GTK_SOURCE_VIEW_GUTTER_POSITION_MARKS (-20). You can use these values to position
    custom renderers accordingly. 
  </p><p>
    The width of a cell renderer can be specified as either fixed (using
    <code class="methodname">gtk.CellRenderer.set_fixed_size</code>()
    ) or dynamic, in which case you MUST set
    <code class="methodname"><a class="link" href="class-gtksourcegutter2.html#method-gtksourcemark2--set-cell-size-func" title="gtksourceview2.Gutter.set_cell_size_func">gtksourceview2.Gutter.set_cell_size_func</a></code>().
    This callback is used to set the properties of the renderer such that
    <code class="methodname">gtk.CellRenderer.get_size</code>()
    yields the maximum width of the cell. 
  </p></div><div class="refsect1" title="Methods"><a name="idp10301456"></a><h2>Methods</h2><div class="refsect2" title="gtksourceview2.Gutter.get_window"><a name="method-gtksourcemark2--get-window"></a><h3>gtksourceview2.Gutter.get_window</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_window</span>(<span class="methodparam"></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>the <code class="classname">gtk.gdk.Window</code>
          of the gutter, or <code class="literal">None</code> if the gutter has no window.</td></tr></tbody></table><p>
      The <code class="methodname">get_window</code>() method returns the
      <code class="classname">gtk.gdk.Window</code>
      of the gutter. The window will only be available when the gutter has at
      least one, non-zero width, cell renderer packed.
    </p></div><div class="refsect2" title="gtksourceview2.Gutter.insert"><a name="method-gtksourcemark2--insert"></a><h3>gtksourceview2.Gutter.insert</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">insert</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>position</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>renderer</code></strong> :</span></p></td><td>a <code class="classname">gtk.CellRenderer</code>
        </td></tr><tr><td><p><span class="term"><strong class="parameter"><code>position</code></strong> :</span></p></td><td>the renderers position.
        </td></tr></tbody></table><p>
      The <code class="methodname">insert</code>() method inserts renderer into gutter at position.
    </p></div><div class="refsect2" title="gtksourceview2.Gutter.queue_draw"><a name="method-gtksourcemark2--queue-draw"></a><h3>gtksourceview2.Gutter.queue_draw</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">queue_draw</span>(<span class="methodparam"></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody></tbody></table><p>
      The <code class="methodname">queue_draw</code>() method invalidates the drawable area of
      the gutter. You can use this to force a redraw of the gutter if something has
      changed and needs to be redrawn.
    </p></div><div class="refsect2" title="gtksourceview2.Gutter.remove"><a name="method-gtksourcemark2--remove"></a><h3>gtksourceview2.Gutter.remove</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">remove</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>renderer</code></strong> :</span></p></td><td>a <code class="classname">gtk.CellRenderer</code>
        </td></tr></tbody></table><p>
      The <code class="methodname">renderer</code>() method removes renderer from gutter.
    </p></div><div class="refsect2" title="gtksourceview2.Gutter.reorder"><a name="method-gtksourcemark2--reorder"></a><h3>gtksourceview2.Gutter.reorder</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">reorder</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>position</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>renderer</code></strong> :</span></p></td><td>a <code class="classname">gtk.CellRenderer</code>
        </td></tr><tr><td><p><span class="term"><strong class="parameter"><code>position</code></strong> :</span></p></td><td>the new renderer position.
        </td></tr></tbody></table><p>
      The <code class="methodname">renderer</code>() method reorders renderer in gutter to new position.
    </p></div><div class="refsect2" title="gtksourceview2.Gutter.set_cell_data_func"><a name="method-gtksourcemark2--set-cell-data-func"></a><h3>gtksourceview2.Gutter.set_cell_data_func</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_cell_data_func</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func_data</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>renderer</code></strong> :</span></p></td><td>a <code class="classname">gtk.CellRenderer</code>
        </td></tr><tr><td><p><span class="term"><strong class="parameter"><code>func</code></strong> :</span></p></td><td>the function.
        </td></tr><tr><td><p><span class="term"><strong class="parameter"><code>func_data</code></strong> :</span></p></td><td>the data to pass whitin func.
        </td></tr></tbody></table><p>
      The <code class="methodname">set_cell_data_func</code>() method sets the func to use for renderer.
      This function is used to setup the cell renderer properties for rendering the current cell.
    </p><pre class="programlisting">
    def gutterdatafunc(cell, line_number, current_line, user_data)</pre><p>
        Where cell is the <code class="classname">gtk.CellRenderer</code> to use,
        line_number is the line number for the gutter and current_line is a boolean indicating if it's the current line,
        user_data is the data passed to set_cell_data_func().
    </p></div><div class="refsect2" title="gtksourceview2.Gutter.set_cell_size_func"><a name="method-gtksourcemark2--set-cell-size-func"></a><h3>gtksourceview2.Gutter.set_cell_size_func</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_cell_data_func</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>renderer</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>func_data</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>renderer</code></strong> :</span></p></td><td>a <code class="classname">gtk.CellRenderer</code>
        </td></tr><tr><td><p><span class="term"><strong class="parameter"><code>func</code></strong> :</span></p></td><td>the function.
        </td></tr><tr><td><p><span class="term"><strong class="parameter"><code>func_data</code></strong> :</span></p></td><td>the data to pass whitin func.
        </td></tr></tbody></table><p>
      The <code class="methodname">set_cell_size_func</code>() method sets the func to use for renderer.
      This function is used to setup the cell renderer properties for measuring the maximum size of the cell.
    </p><pre class="programlisting">
    def guttersizefunc(cell, user_data)</pre><p>
        Where cell is the <code class="classname">gtk.CellRenderer</code> to use,
        and user_data is the data passed to set_cell_data_func().
    </p></div></div><div class="refsect1" title="Signals"><a name="idp10390640"></a><h2>Signals</h2><div class="refsect2" title='The "cell-activated" gtksourceview2.Gutter Signal'><a name="signal-gtksourcegutter--cell-activated"></a><h3>The "cell-activated" gtksourceview2.Gutter Signal</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>gutter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>renderer</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>iter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>event</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>gutter</code></em> :</span></p></td><td>the <a class="link" href="class-gtksourcegutter2.html" title="gtksourceview2.Gutter">gtksourceview2.Gutter</a>
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>renderer</code></em> :</span></p></td><td>the <code class="classname">gtk.CellRenderer</code> which was activated.
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>iter</code></em> :</span></p></td><td>the <code class="classname">gtk.TextIter</code> at which the cell was activated 
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>event</code></em> :</span></p></td><td>the <code class="classname">gtk.gdk.Event</code> with which the cell was activated 
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>user_param1</code></em> :</span></p></td><td>the first user parameter (if any) specified with the
          <a
href="../pygobject/class-gobject.html#method-gobject--connect"
><code class="methodname">connect</code>()</a>
          method</td></tr><tr><td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td><td>additional user parameters (if any)</td></tr></tbody></table><p>
        The "cell-activated" signal is emitted when a cell has been activated (for instance
        when there was a button press on the cell). The signal is only emitted for cells
        that have the activatable property set to <code class="literal">True</code>.
      </p></div><div class="refsect2" title='The "query-tooltip" gtksourceview2.Gutter Signal'><a name="signal-gtksourcegutter--query-tooltip"></a><h3>The "query-tooltip" gtksourceview2.Gutter Signal</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">callback</span>(<span class="methodparam"><span class="parameter"><em class="parameter"><code>gutter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>renderer</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>iter</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>tooltip</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>user_param1</code></em></span></span>, <span class="methodparam"><span class="parameter"><em class="parameter"><code>...</code></em></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>gutter</code></em> :</span></p></td><td>the <a class="link" href="class-gtksourcegutter2.html" title="gtksourceview2.Gutter">gtksourceview2.Gutter</a>
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>renderer</code></em> :</span></p></td><td>the <code class="classname">gtk.CellRenderer</code> which was activated.
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>iter</code></em> :</span></p></td><td>the <code class="classname">gtk.TextIter</code> at which the cell was activated 
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>tooltip</code></em> :</span></p></td><td>the <code class="classname">gtk.Tooltip</code>
          </td></tr><tr><td><p><span class="term"><em class="parameter"><code>user_param1</code></em> :</span></p></td><td>the first user parameter (if any) specified with the
          <a
href="../pygobject/class-gobject.html#method-gobject--connect"
><code class="methodname">connect</code>()</a>
          method</td></tr><tr><td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td><td>additional user parameters (if any)</td></tr></tbody></table><p>
        The "query-tooltip" signal is emitted when a tooltip is requested for a specific cell.
        Signal handlers can return <code class="literal">True</code> to notify the tooltip has been handled.
      </p></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="class-gtksourcebuffer2.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="class-gtksourcelanguage2.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">gtksourceview2.Buffer </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> gtksourceview2.Language</td></tr></table></div></body></html>