This file is indexed.

/usr/share/doc/python-flask-silk-doc/html/index.html is in python-flask-silk-doc 0.2-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
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>Flask-Silk &mdash; Flask-Silk 0.1.2 documentation</title>
    
    <link rel="stylesheet" href="_static/flasky.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '',
        VERSION:     '0.1.2',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/underscore.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>
    <link rel="top" title="Flask-Silk 0.1.2 documentation" href="#" /> 
  </head>
  <body>
  
  
  <div class=indexwrapper>
  


    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <div class="section" id="module-flask_silk">
<span id="flask-silk"></span><h1>Flask-Silk<a class="headerlink" href="#module-flask_silk" title="Permalink to this headline"></a></h1>
<p>Flask-Silk is small Flask extension. It adds <a class="reference external" href="http://www.famfamfam.com/lab/icons/silk">silk</a> icons to your Flask
application or blueprint, or extension!</p>
<p>Silk is very awesome. It will be good for your Flask extensions. But if
someone use many Flask extensions which contains silk icons, they will lose
their storage space too much. They can solve the problem with Flask-Silk.</p>
<p>If you want to preview silk icons, visit <a class="reference internal" href="dict.html"><em>Silk Icon Dictionary</em></a>.</p>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">Silk is licensed under <a class="reference external" href="http://creativecommons.org/licenses/by/2.5">Creative Commons Attribution 2.5 License</a> or
<a class="reference external" href="http://creativecommons.org/licenses/by/3.0">3.0 License</a>. Before using
the icons, read the license.</p>
</div>
<div class="section" id="installation">
<h2>Installation<a class="headerlink" href="#installation" title="Permalink to this headline"></a></h2>
<p>Install via <a class="reference external" href="http://pypi.python.org/pypi/Flask-Silk">PyPI</a>:</p>
<div class="highlight-python"><pre>$ easy_install Flask-Silk</pre>
</div>
<p>Or check out development version:</p>
<div class="highlight-python"><pre>$ git clone git://github.com/sublee/flask-silk.git</pre>
</div>
</div>
<div class="section" id="how-to-use">
<h2>How to Use<a class="headerlink" href="#how-to-use" title="Permalink to this headline"></a></h2>
<p>If you want to contain silk icons to your application, follow the below
example:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">flask</span> <span class="kn">import</span> <span class="n">Flask</span>
<span class="kn">from</span> <span class="nn">flask.ext.silk</span> <span class="kn">import</span> <span class="n">Silk</span>
<span class="n">app</span> <span class="o">=</span> <span class="n">Flask</span><span class="p">(</span><span class="n">__name__</span><span class="p">)</span>
<span class="n">silk</span> <span class="o">=</span> <span class="n">Silk</span><span class="p">(</span><span class="n">app</span><span class="p">)</span>
</pre></div>
</div>
<p>In your application, you can get an icon&#8217;s url by:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="n">url_for</span><span class="p">(</span><span class="s">&#39;silkicon&#39;</span><span class="p">,</span> <span class="n">filename</span><span class="o">=</span><span class="s">&#39;bug.png&#39;</span><span class="p">)</span>
</pre></div>
</div>
<p>It also works with Flask blueprint:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">flask</span> <span class="kn">import</span> <span class="n">Blueprint</span>
<span class="kn">from</span> <span class="nn">flask.ext.silk</span> <span class="kn">import</span> <span class="n">Silk</span>
<span class="n">blu</span> <span class="o">=</span> <span class="n">Blueprint</span><span class="p">(</span><span class="n">__name__</span><span class="p">,</span> <span class="n">__name__</span><span class="p">)</span>
<span class="n">silk</span> <span class="o">=</span> <span class="n">Silk</span><span class="p">(</span><span class="n">blu</span><span class="p">)</span>
</pre></div>
</div>
</div>
<div class="section" id="api">
<h2>API<a class="headerlink" href="#api" title="Permalink to this headline"></a></h2>
<dl class="class">
<dt id="flask_silk.Silk">
<em class="property">class </em><tt class="descclassname">flask_silk.</tt><tt class="descname">Silk</tt><big>(</big><em>base</em>, <em>silk_path='/icons'</em><big>)</big><a class="headerlink" href="#flask_silk.Silk" title="Permalink to this definition"></a></dt>
<dd><p>This small extension adds <tt class="xref py py-meth docutils literal"><span class="pre">silkicon()</span></tt> to your Flask application:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">flask</span> <span class="kn">import</span> <span class="n">Flask</span>
<span class="kn">from</span> <span class="nn">flask.ext.silk</span> <span class="kn">import</span> <span class="n">Silk</span>
<span class="n">app</span> <span class="o">=</span> <span class="n">Flask</span><span class="p">(</span><span class="n">__name__</span><span class="p">)</span>
<span class="n">silk</span> <span class="o">=</span> <span class="n">Silk</span><span class="p">(</span><span class="n">app</span><span class="p">)</span>
</pre></div>
</div>
<p>Or it works with your Flask blueprint:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">flask</span> <span class="kn">import</span> <span class="n">Blueprint</span>
<span class="kn">from</span> <span class="nn">flask.ext.silk</span> <span class="kn">import</span> <span class="n">Silk</span>
<span class="n">blu</span> <span class="o">=</span> <span class="n">Blueprint</span><span class="p">(</span><span class="n">__name__</span><span class="p">,</span> <span class="n">__name__</span><span class="p">)</span>
<span class="n">silk</span> <span class="o">=</span> <span class="n">Silk</span><span class="p">(</span><span class="n">blu</span><span class="p">)</span>
</pre></div>
</div>
<p>Now the application or blueprint&#8217;s <tt class="docutils literal"><span class="pre">/icons/&lt;filaname&gt;</span></tt> is bound to
<tt class="xref py py-meth docutils literal"><span class="pre">silkicon()</span></tt> for serves a prepared silk icon.</p>
<p>Also you can work with your own icon directory:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">import</span> <span class="nn">os.path</span>
<span class="n">my_icons</span> <span class="o">=</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">silk</span><span class="o">.</span><span class="n">base</span><span class="o">.</span><span class="n">static_path</span><span class="p">,</span> <span class="s">&#39;icons&#39;</span><span class="p">)</span>
<span class="n">my_icons2</span> <span class="o">=</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">silk</span><span class="o">.</span><span class="n">base</span><span class="o">.</span><span class="n">static_path</span><span class="p">,</span> <span class="s">&#39;other-icons&#39;</span><span class="p">)</span>
<span class="n">silk</span><span class="o">.</span><span class="n">register_icon_directory</span><span class="p">(</span><span class="n">my_icons</span><span class="p">)</span>
<span class="n">silk</span><span class="o">.</span><span class="n">register_icon_directory</span><span class="p">(</span><span class="n">my_icons2</span><span class="p">)</span>
</pre></div>
</div>
<p>Silk finds the icon in the registered directories first. If the icon does
not exist in any directories, Silk finds the prepared silk icon.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>base</strong> &#8211; the flask application or blueprint.</li>
<li><strong>silk_path</strong> &#8211; the path to serve silk icons. Defaults to <tt class="docutils literal"><span class="pre">/icons</span></tt>.</li>
</ul>
</td>
</tr>
</tbody>
</table>
</dd></dl>

<dl class="function">
<dt id="flask_silk.send_silkicon">
<tt class="descclassname">flask_silk.</tt><tt class="descname">send_silkicon</tt><big>(</big><em>filename</em>, <em>directories=</em><span class="optional">[</span><span class="optional">]</span><big>)</big><a class="headerlink" href="#flask_silk.send_silkicon" title="Permalink to this definition"></a></dt>
<dd><p>Sends an icon. The icon is in a shared directory or specified
directories. Here&#8217;s a simple examples of how to send an icon:</p>
<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">flask.ext.silk</span> <span class="kn">import</span> <span class="n">send_silkicon</span>
<span class="kn">from</span> <span class="nn">myapplication</span> <span class="kn">import</span> <span class="n">app</span>

<span class="n">my_icons</span> <span class="o">=</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">app</span><span class="o">.</span><span class="n">static_path</span><span class="p">,</span> <span class="s">&#39;icons&#39;</span><span class="p">)</span>
<span class="n">my_icons2</span> <span class="o">=</span> <span class="n">os</span><span class="o">.</span><span class="n">path</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">app</span><span class="o">.</span><span class="n">static_path</span><span class="p">,</span> <span class="s">&#39;other-icons&#39;</span><span class="p">)</span>

<span class="nd">@app.route</span><span class="p">(</span><span class="s">&#39;/static/icons/&lt;filename&gt;&#39;</span><span class="p">)</span>
<span class="k">def</span> <span class="nf">icon</span><span class="p">(</span><span class="n">filename</span><span class="p">):</span>
    <span class="k">return</span> <span class="n">send_silkicon</span><span class="p">(</span><span class="n">filename</span><span class="p">,</span> <span class="n">directories</span><span class="o">=</span><span class="p">[</span><span class="n">my_icons</span><span class="p">,</span> <span class="n">my_icons2</span><span class="p">])</span>
</pre></div>
</div>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
<li><strong>filename</strong> &#8211; the filename for icon.</li>
<li><strong>directories</strong> &#8211; specified icon directories.</li>
</ul>
</td>
</tr>
</tbody>
</table>
</dd></dl>

</div>
<div class="section" id="indices-and-tables">
<h2>Indices and tables<a class="headerlink" href="#indices-and-tables" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li><a class="reference internal" href="dict.html"><em>Silk Icon Dictionary</em></a></li>
<li><a class="reference internal" href="genindex.html"><em>Index</em></a></li>
<li><a class="reference internal" href="py-modindex.html"><em>Module Index</em></a></li>
<li><a class="reference internal" href="search.html"><em>Search Page</em></a></li>
</ul>
</div>
</div>


          </div>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
  
    <a href="http://github.com/sublee/flask-silk"><img style="position: fixed; top: 0; right: 0; border: 0;"
    src="http://s3.amazonaws.com/github/ribbons/forkme_right_darkblue_121621.png" alt="Fork me on GitHub" /></a>
  

  
  </div>
  

  </body>
</html>