This file is indexed.

/usr/share/gtk-doc/html/caja-python/class-caja-python-menu-provider.html is in python-caja-common 1.20.0-1.

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
<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>Caja.MenuProvider</title><link rel="stylesheet" type="text/css" href="style.css"><meta name="generator" content="DocBook XSL Stylesheets V1.79.1"><link rel="home" href="index.html" title="caja-python Reference Manual"><link rel="up" href="caja-python-provider-reference.html" title="Provider Interfaces"><link rel="prev" href="class-caja-python-location-widget-provider.html" title="Caja.LocationWidgetProvider"><link rel="next" href="class-caja-python-property-page-provider.html" title="Caja.PropertyPageProvider"></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">Caja.MenuProvider</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="class-caja-python-location-widget-provider.html">Prev</a> </td><th width="60%" align="center">Provider Interfaces</th><td width="20%" align="right"> <a accesskey="n" href="class-caja-python-property-page-provider.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="class-caja-python-menu-provider"></a><div class="titlepage"></div><div class="refnamediv"><h2>Caja.MenuProvider</h2><p>Caja.MenuProvider — Caja.MenuProvider Reference</p></div><div class="refsect1"><a name="idm1164"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">Caja.MenuProvider</span></span>:
<code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-caja-python-menu-provider.html#method-caja-python-menu-provider--get-file-items" title="Caja.MenuProvider.get_file_items">get_file_items</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-caja-python-menu-provider.html#method-caja-python-menu-provider--get-file-items-full" title="Caja.MenuProvider.get_file_items_full">get_file_items_full</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>provider</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-caja-python-menu-provider.html#method-caja-python-menu-provider--get-background-items" title="Caja.MenuProvider.get_background_items">get_background_items</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>folder</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-caja-python-menu-provider.html#method-caja-python-menu-provider--get-background-items-full" title="Caja.MenuProvider.get_background_items_full">get_background_items_full</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>provider</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>folder</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-caja-python-menu-provider.html#method-caja-python-menu-provider--emit-items-updated-signal" title="Caja.menu_provider_emit_items_updated_signal">Caja.menu_provider_emit_items_updated_signal</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>provider</code></strong></span></span>)</code><br></pre></td></tr></table></div><div class="refsect1"><a name="description-menu-provider"></a><h2>Description</h2><p>
        If subclassed, Caja will request a list of <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code></a> objects, 
        which are then attached to various menus.  Caja expects at least one of
        the following methods to be defined (or their *_full variants): get_file_items or
        get_background_items.</p><p>The get_toolbar_items methods were removed in caja-python 1.0 because they were removed from Caja 3.  Technically, you should still be 
        able to call those methods with caja-python 1.0 if you are running Caja 2.x with annotations.
        </p><div class="example"><a name="idm1212"></a><p class="title"><b>Example 5. Caja.MenuProvider Example</b></p><div class="example-contents"><pre class="programlisting">
from gi.repository import Caja, GObject

class ColumnExtension(GObject.GObject, Caja.MenuProvider):
    def __init__(self):
        pass
        
    def get_file_items(self, window, files):
        top_menuitem = Caja.MenuItem(name='ExampleMenuProvider::Foo', 
                                         label='Foo', 
                                         tip='',
                                         icon='')

        submenu = Caja.Menu()
        top_menuitem.set_submenu(submenu)

        sub_menuitem = Caja.MenuItem(name='ExampleMenuProvider::Bar', 
                                         label='Bar', 
                                         tip='',
                                         icon='')
        submenu.append_item(sub_menuitem)

        return top_menuitem,

    def get_background_items(self, window, file):
        submenu = Caja.Menu()
        submenu.append_item(Caja.MenuItem(name='ExampleMenuProvider::Bar2', 
                                         label='Bar2', 
                                         tip='',
                                         icon=''))

        menuitem = Caja.MenuItem(name='ExampleMenuProvider::Foo2', 
                                         label='Foo2', 
                                         tip='',
                                         icon='')
        menuitem.set_submenu(submenu)

        return menuitem,

    </pre></div></div><br class="example-break"><div class="refsect1"><a name="idm1215"></a><h2>Signals</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-caja-python-menu-provider.html#signal-caja-python-menu-provider--items-updated" title='The "items-updated" Caja.MenuProvider Signal'>"items-updated"</a></span></p></td><td><code class="methodsynopsis">    def <span class="methodname">callback</span>()</code></td></tr></tbody></table></div></div><div class="refsect1"><a name="idm1224"></a><h2>Passive Methods</h2><div class="refsect2"><a name="method-caja-python-menu-provider--get-file-items"></a><h3>Caja.MenuProvider.get_file_items</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_file_items</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</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>window</code></strong> :</span></p></td><td>the current <code class="classname">gtk.Window</code> instance</td></tr><tr><td><p><span class="term"><strong class="parameter"><code>menu</code></strong> :</span></p></td><td>a list of <a class="link" href="class-caja-python-file-info.html" title="Caja.FileInfo"><code class="classname">Caja.FileInfo</code></a> objects.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a list of <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code></a> objects</td></tr></tbody></table><p>
            The <code class="methodname">get_file_items</code>() method returns a list of
            <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code></a> objects.
          </p></div><div class="refsect2"><a name="method-caja-python-menu-provider--get-file-items-full"></a><h3>Caja.MenuProvider.get_file_items_full</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_file_items_full</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>provider</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>files</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>provider</code></strong> :</span></p></td><td>the current <a class="link" href="class-caja-python-menu-provider.html" title="Caja.MenuProvider"><code class="classname">Caja.MenuProvider</code></a> instance</td></tr><tr><td><p><span class="term"><strong class="parameter"><code>window</code></strong> :</span></p></td><td>the current <code class="classname">gtk.Window</code> instance</td></tr><tr><td><p><span class="term"><strong class="parameter"><code>files</code></strong> :</span></p></td><td>a list of <a class="link" href="class-caja-python-file-info.html" title="Caja.FileInfo"><code class="classname">Caja.FileInfo</code></a> objects.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a list of <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code></a> objects</td></tr></tbody></table><p>
            The <code class="methodname">get_file_items_full</code>() method returns a list of
            <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code> objects</a>.
          </p><p>
            This method was created in order to allow extension writers to call the 
            Caja.menu_provider_emit_items_updated_signal, which must
            be passed the current provider instance.
          </p><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3>
            This method was introduced in caja-python 0.7.0.
          </div></div><div class="refsect2"><a name="method-caja-python-menu-provider--get-background-items"></a><h3>Caja.MenuProvider.get_background_items</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_background_items</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>folder</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>window</code></strong> :</span></p></td><td>the current <code class="classname">gtk.Window</code> instance</td></tr><tr><td><p><span class="term"><strong class="parameter"><code>folder</code></strong> :</span></p></td><td>the current folder, as a <a class="link" href="class-caja-python-file-info.html" title="Caja.FileInfo"><code class="classname">Caja.FileInfo</code></a> object.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a list of <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code></a> objects</td></tr></tbody></table><p>
            The <code class="methodname">get_background_items</code>() method returns a list of
            <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code> objects</a>.
          </p></div><div class="refsect2"><a name="method-caja-python-menu-provider--get-background-items-full"></a><h3>Caja.MenuProvider.get_background_items_full</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_background_items_full</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>provider</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>window</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>folder</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>provider</code></strong> :</span></p></td><td>the current <a class="link" href="class-caja-python-menu-provider.html" title="Caja.MenuProvider"><code class="classname">Caja.MenuProvider</code></a> instance</td></tr><tr><td><p><span class="term"><strong class="parameter"><code>window</code></strong> :</span></p></td><td>the current <code class="classname">gtk.Window</code> instance</td></tr><tr><td><p><span class="term"><strong class="parameter"><code>folder</code></strong> :</span></p></td><td>the current folder, as a <a class="link" href="class-caja-python-file-info.html" title="Caja.FileInfo"><code class="classname">Caja.FileInfo</code></a> object.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a list of <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code></a> objects</td></tr></tbody></table><p>
            The <code class="methodname">get_background_items_full</code>() method returns a list of
            <a class="link" href="class-caja-python-menu-item.html" title="Caja.MenuItem"><code class="classname">Caja.MenuItem</code> objects</a>.
          </p><p>
            This method was created in order to allow extension writers to call the 
            Caja.menu_provider_emit_items_updated_signal, which must
            be passed the current provider instance.
          </p><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3>
            This method was introduced in caja-python 0.7.0.
          </div></div></div><div class="refsect1"><a name="idm1390"></a><h2>Active Methods</h2><div class="refsect2"><a name="method-caja-python-menu-provider--emit-items-updated-signal"></a><h3>Caja.menu_provider_emit_items_updated_signal</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">menu_provider_emit_items_updated_signal</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>provider</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>provider</code></strong> :</span></p></td><td>the current <a class="link" href="class-caja-python-menu-provider.html" title="Caja.MenuProvider"><code class="classname">Caja.MenuProvider</code></a> instance</td></tr></tbody></table><p>
            Emits the "<a class="link" href="class-caja-python-menu-provider.html#signal-caja-python-menu-provider--items-updated" title='The "items-updated" Caja.MenuProvider Signal'>items-updated</a>" signal.
          </p><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3>
            This method was introduced in caja-python 0.7.0.
          </div></div></div><div class="refsect1"><a name="idm1410"></a><h2>Signal Details</h2><div class="refsect2"><a name="signal-caja-python-menu-provider--items-updated"></a><h3>The "items-updated" Caja.MenuProvider Signal</h3><p>
      Emits the "<a class="link" href="class-caja-python-menu-provider.html#signal-caja-python-menu-provider--items-updated" title='The "items-updated" Caja.MenuProvider Signal'>items-updated</a>" signal.
    </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-caja-python-location-widget-provider.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="caja-python-provider-reference.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="class-caja-python-property-page-provider.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Caja.LocationWidgetProvider </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Caja.PropertyPageProvider</td></tr></table></div></body></html>