~ubuntu-branches/ubuntu/utopic/screenlets/utopic

« back to all changes in this revision

Viewing changes to docs/epydoc/screenlets.options.string_option-pysrc.html

  • Committer: Bazaar Package Importer
  • Author(s): Julien Lavergne
  • Date: 2011-07-02 11:06:42 UTC
  • mfrom: (1.1.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20110702110642-d0oqdiy8sye8cli2
Tags: 0.1.4-0ubuntu1
* New upstream release.
* debian/patches:
 - 90-disable-resize-grip.patch : Drop, merged upstream.
 - 91_use_webkit.patch: Drop, merged upstream.
* debian/rules:
 - Only fix the permission on 1 file.
* debian/copyright:
 - Update copyright holders.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0" encoding="ascii"?>
 
2
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
 
3
          "DTD/xhtml1-transitional.dtd">
 
4
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 
5
<head>
 
6
  <title>screenlets.options.string_option</title>
 
7
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
 
8
  <script type="text/javascript" src="epydoc.js"></script>
 
9
</head>
 
10
 
 
11
<body bgcolor="white" text="black" link="blue" vlink="#204080"
 
12
      alink="#204080">
 
13
<!-- ==================== NAVIGATION BAR ==================== -->
 
14
<table class="navbar" border="0" width="100%" cellpadding="0"
 
15
       bgcolor="#a0c0ff" cellspacing="0">
 
16
  <tr valign="middle">
 
17
  <!-- Home link -->
 
18
      <th>&nbsp;&nbsp;&nbsp;<a
 
19
        href="screenlets-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>
 
20
 
 
21
  <!-- Tree link -->
 
22
      <th>&nbsp;&nbsp;&nbsp;<a
 
23
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
 
24
 
 
25
  <!-- Index link -->
 
26
      <th>&nbsp;&nbsp;&nbsp;<a
 
27
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
 
28
 
 
29
  <!-- Help link -->
 
30
      <th>&nbsp;&nbsp;&nbsp;<a
 
31
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
 
32
 
 
33
  <!-- Project homepage -->
 
34
      <th class="navbar" align="right" width="100%">
 
35
        <table border="0" cellpadding="0" cellspacing="0">
 
36
          <tr><th class="navbar" align="center"
 
37
            >Screenlets 0.1.4</th>
 
38
          </tr></table></th>
 
39
  </tr>
 
40
</table>
 
41
<table width="100%" cellpadding="0" cellspacing="0">
 
42
  <tr valign="top">
 
43
    <td width="100%">
 
44
      <span class="breadcrumbs">
 
45
        <a href="screenlets-module.html">Package&nbsp;screenlets</a> ::
 
46
        <a href="screenlets.options-module.html">Package&nbsp;options</a> ::
 
47
        Module&nbsp;string_option
 
48
      </span>
 
49
    </td>
 
50
    <td>
 
51
      <table cellpadding="0" cellspacing="0">
 
52
        <!-- hide/show private -->
 
53
        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
 
54
    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
 
55
        <tr><td align="right"><span class="options"
 
56
            >[<a href="frames.html" target="_top">frames</a
 
57
            >]&nbsp;|&nbsp;<a href="screenlets.options.string_option-pysrc.html"
 
58
            target="_top">no&nbsp;frames</a>]</span></td></tr>
 
59
      </table>
 
60
    </td>
 
61
  </tr>
 
62
</table>
 
63
<h1 class="epydoc">Source Code for <a href="screenlets.options.string_option-module.html">Module screenlets.options.string_option</a></h1>
 
64
<pre class="py-src">
 
65
<a name="L1"></a><tt class="py-lineno"> 1</tt>  <tt class="py-line"><tt class="py-comment"># </tt> </tt>
 
66
<a name="L2"></a><tt class="py-lineno"> 2</tt>  <tt class="py-line"><tt class="py-comment"># Copyright (C) 2009 Martin Owens (DoctorMO) &lt;doctormo@gmail.com&gt;</tt> </tt>
 
67
<a name="L3"></a><tt class="py-lineno"> 3</tt>  <tt class="py-line"><tt class="py-comment"># Changed by Guido Tabbernuk 2011</tt> </tt>
 
68
<a name="L4"></a><tt class="py-lineno"> 4</tt>  <tt class="py-line"><tt class="py-comment">#</tt> </tt>
 
69
<a name="L5"></a><tt class="py-lineno"> 5</tt>  <tt class="py-line"><tt class="py-comment"># This program is free software; you can redistribute it and/or modify</tt> </tt>
 
70
<a name="L6"></a><tt class="py-lineno"> 6</tt>  <tt class="py-line"><tt class="py-comment"># it under the terms of the GNU General Public License as published by</tt> </tt>
 
71
<a name="L7"></a><tt class="py-lineno"> 7</tt>  <tt class="py-line"><tt class="py-comment"># the Free Software Foundation; either version 3 of the License, or</tt> </tt>
 
72
<a name="L8"></a><tt class="py-lineno"> 8</tt>  <tt class="py-line"><tt class="py-comment"># (at your option) any later version.</tt> </tt>
 
73
<a name="L9"></a><tt class="py-lineno"> 9</tt>  <tt class="py-line"><tt class="py-comment"># </tt> </tt>
 
74
<a name="L10"></a><tt class="py-lineno">10</tt>  <tt class="py-line"><tt class="py-comment"># This program is distributed in the hope that it will be useful,</tt> </tt>
 
75
<a name="L11"></a><tt class="py-lineno">11</tt>  <tt class="py-line"><tt class="py-comment"># but WITHOUT ANY WARRANTY; without even the implied warranty of</tt> </tt>
 
76
<a name="L12"></a><tt class="py-lineno">12</tt>  <tt class="py-line"><tt class="py-comment"># MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</tt> </tt>
 
77
<a name="L13"></a><tt class="py-lineno">13</tt>  <tt class="py-line"><tt class="py-comment"># GNU General Public License for more details.</tt> </tt>
 
78
<a name="L14"></a><tt class="py-lineno">14</tt>  <tt class="py-line"><tt class="py-comment"># </tt> </tt>
 
79
<a name="L15"></a><tt class="py-lineno">15</tt>  <tt class="py-line"><tt class="py-comment"># You should have received a copy of the GNU General Public License</tt> </tt>
 
80
<a name="L16"></a><tt class="py-lineno">16</tt>  <tt class="py-line"><tt class="py-comment"># along with this program; if not, write to the Free Software</tt> </tt>
 
81
<a name="L17"></a><tt class="py-lineno">17</tt>  <tt class="py-line"><tt class="py-comment"># Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA</tt> </tt>
 
82
<a name="L18"></a><tt class="py-lineno">18</tt>  <tt class="py-line"><tt class="py-comment"># </tt> </tt>
 
83
<a name="L19"></a><tt class="py-lineno">19</tt>  <tt class="py-line"><tt class="py-docstring">"""</tt> </tt>
 
84
<a name="L20"></a><tt class="py-lineno">20</tt>  <tt class="py-line"><tt class="py-docstring">String options, these classes will display a text box.</tt> </tt>
 
85
<a name="L21"></a><tt class="py-lineno">21</tt>  <tt class="py-line"><tt class="py-docstring">"""</tt> </tt>
 
86
<a name="L22"></a><tt class="py-lineno">22</tt>  <tt class="py-line"> </tt>
 
87
<a name="L23"></a><tt class="py-lineno">23</tt>  <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">gtk</tt> </tt>
 
88
<a name="L24"></a><tt class="py-lineno">24</tt>  <tt class="py-line"> </tt>
 
89
<a name="L25"></a><tt class="py-lineno">25</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-0" class="py-name" targets="Package screenlets=screenlets-module.html"><a title="screenlets" class="py-name" href="#" onclick="return doclink('link-0', 'screenlets', 'link-0');">screenlets</a></tt><tt class="py-op">.</tt><tt id="link-1" class="py-name" targets="Package screenlets.options=screenlets.options-module.html"><a title="screenlets.options" class="py-name" href="#" onclick="return doclink('link-1', 'options', 'link-1');">options</a></tt> <tt class="py-keyword">import</tt> <tt id="link-2" class="py-name" targets="Function screenlets._()=screenlets-module.html#_,Function screenlets.backend._()=screenlets.backend-module.html#_,Function screenlets.install._()=screenlets.install-module.html#_,Function screenlets.menu._()=screenlets.menu-module.html#_,Function screenlets.options._()=screenlets.options-module.html#_,Function screenlets.sensors._()=screenlets.sensors-module.html#_,Function screenlets.services._()=screenlets.services-module.html#_,Function screenlets.session._()=screenlets.session-module.html#_,Function screenlets.utils._()=screenlets.utils-module.html#_"><a title="screenlets._
 
90
screenlets.backend._
 
91
screenlets.install._
 
92
screenlets.menu._
 
93
screenlets.options._
 
94
screenlets.sensors._
 
95
screenlets.services._
 
96
screenlets.session._
 
97
screenlets.utils._" class="py-name" href="#" onclick="return doclink('link-2', '_', 'link-2');">_</a></tt> </tt>
 
98
<a name="L26"></a><tt class="py-lineno">26</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-3" class="py-name" targets="Module screenlets.options.base=screenlets.options.base-module.html"><a title="screenlets.options.base" class="py-name" href="#" onclick="return doclink('link-3', 'base', 'link-3');">base</a></tt> <tt class="py-keyword">import</tt> <tt id="link-4" class="py-name" targets="Class screenlets.options.base.Option=screenlets.options.base.Option-class.html"><a title="screenlets.options.base.Option" class="py-name" href="#" onclick="return doclink('link-4', 'Option', 'link-4');">Option</a></tt> </tt>
 
99
<a name="L27"></a><tt class="py-lineno">27</tt>  <tt class="py-line"> </tt>
 
100
<a name="StringOption"></a><div id="StringOption-def"><a name="L28"></a><tt class="py-lineno">28</tt> <a class="py-toggle" href="#" id="StringOption-toggle" onclick="return toggle('StringOption');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="screenlets.options.string_option.StringOption-class.html">StringOption</a><tt class="py-op">(</tt><tt class="py-base-class">Option</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
 
101
</div><div id="StringOption-collapsed" style="display:none;" pad="++" indent="++++"></div><div id="StringOption-expanded"><a name="L29"></a><tt class="py-lineno">29</tt>  <tt class="py-line">    <tt class="py-docstring">"""An Option for string options."""</tt> </tt>
 
102
<a name="L30"></a><tt class="py-lineno">30</tt>  <tt class="py-line">    <tt id="link-5" class="py-name" targets="Variable screenlets.options.string_option.StringOption.choices=screenlets.options.string_option.StringOption-class.html#choices"><a title="screenlets.options.string_option.StringOption.choices" class="py-name" href="#" onclick="return doclink('link-5', 'choices', 'link-5');">choices</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
 
103
<a name="L31"></a><tt class="py-lineno">31</tt>  <tt class="py-line">    <tt id="link-6" class="py-name" targets="Variable screenlets.options.string_option.StringOption.password=screenlets.options.string_option.StringOption-class.html#password,Variable screenlets.plugins.keyring.KeyRing.Key.password=screenlets.plugins.keyring.KeyRing.Key-class.html#password"><a title="screenlets.options.string_option.StringOption.password
 
104
screenlets.plugins.keyring.KeyRing.Key.password" class="py-name" href="#" onclick="return doclink('link-6', 'password', 'link-6');">password</a></tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
 
105
<a name="L32"></a><tt class="py-lineno">32</tt>  <tt class="py-line"> </tt>
 
106
<a name="StringOption.on_import"></a><div id="StringOption.on_import-def"><a name="L33"></a><tt class="py-lineno">33</tt> <a class="py-toggle" href="#" id="StringOption.on_import-toggle" onclick="return toggle('StringOption.on_import');">-</a><tt class="py-line">    <tt class="py-keyword">def</tt> <a class="py-def-name" href="screenlets.options.string_option.StringOption-class.html#on_import">on_import</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">strvalue</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
 
107
</div><div id="StringOption.on_import-collapsed" style="display:none;" pad="++" indent="++++++++"></div><div id="StringOption.on_import-expanded"><a name="L34"></a><tt class="py-lineno">34</tt>  <tt class="py-line">        <tt class="py-docstring">"""When a string is imported from the config."""</tt> </tt>
 
108
<a name="L35"></a><tt class="py-lineno">35</tt>  <tt class="py-line">        <tt class="py-keyword">return</tt> <tt class="py-name">strvalue</tt><tt class="py-op">.</tt><tt id="link-7" class="py-name" targets="Variable screenlets.plugins.Convert.Converter.replace=screenlets.plugins.Convert.Converter-class.html#replace"><a title="screenlets.plugins.Convert.Converter.replace" class="py-name" href="#" onclick="return doclink('link-7', 'replace', 'link-7');">replace</a></tt><tt class="py-op">(</tt><tt class="py-string">"\\n"</tt><tt class="py-op">,</tt> <tt class="py-string">"\n"</tt><tt class="py-op">)</tt> </tt>
 
109
</div><a name="L36"></a><tt class="py-lineno">36</tt>  <tt class="py-line"> </tt>
 
110
<a name="StringOption.on_export"></a><div id="StringOption.on_export-def"><a name="L37"></a><tt class="py-lineno">37</tt> <a class="py-toggle" href="#" id="StringOption.on_export-toggle" onclick="return toggle('StringOption.on_export');">-</a><tt class="py-line">    <tt class="py-keyword">def</tt> <a class="py-def-name" href="screenlets.options.string_option.StringOption-class.html#on_export">on_export</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
 
111
</div><div id="StringOption.on_export-collapsed" style="display:none;" pad="++" indent="++++++++"></div><div id="StringOption.on_export-expanded"><a name="L38"></a><tt class="py-lineno">38</tt>  <tt class="py-line">        <tt class="py-docstring">"""When a string is exported to the config."""</tt> </tt>
 
112
<a name="L39"></a><tt class="py-lineno">39</tt>  <tt class="py-line">        <tt class="py-keyword">return</tt> <tt id="link-8" class="py-name" targets="Method screenlets.plugins.Convert.Converter.str()=screenlets.plugins.Convert.Converter-class.html#str"><a title="screenlets.plugins.Convert.Converter.str" class="py-name" href="#" onclick="return doclink('link-8', 'str', 'link-8');">str</a></tt><tt class="py-op">(</tt><tt class="py-name">value</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-9" class="py-name"><a title="screenlets.plugins.Convert.Converter.replace" class="py-name" href="#" onclick="return doclink('link-9', 'replace', 'link-7');">replace</a></tt><tt class="py-op">(</tt><tt class="py-string">"\n"</tt><tt class="py-op">,</tt> <tt class="py-string">"\\n"</tt><tt class="py-op">)</tt> </tt>
 
113
</div><a name="L40"></a><tt class="py-lineno">40</tt>  <tt class="py-line"> </tt>
 
114
<a name="StringOption.generate_widget"></a><div id="StringOption.generate_widget-def"><a name="L41"></a><tt class="py-lineno">41</tt> <a class="py-toggle" href="#" id="StringOption.generate_widget-toggle" onclick="return toggle('StringOption.generate_widget');">-</a><tt class="py-line">    <tt class="py-keyword">def</tt> <a class="py-def-name" href="screenlets.options.string_option.StringOption-class.html#generate_widget">generate_widget</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
 
115
</div><div id="StringOption.generate_widget-collapsed" style="display:none;" pad="++" indent="++++++++"></div><div id="StringOption.generate_widget-expanded"><a name="L42"></a><tt class="py-lineno">42</tt>  <tt class="py-line">        <tt class="py-docstring">"""Generate a textbox for a string options"""</tt> </tt>
 
116
<a name="L43"></a><tt class="py-lineno">43</tt>  <tt class="py-line">        <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-10" class="py-name"><a title="screenlets.options.string_option.StringOption.choices" class="py-name" href="#" onclick="return doclink('link-10', 'choices', 'link-5');">choices</a></tt><tt class="py-op">:</tt> </tt>
 
117
<a name="L44"></a><tt class="py-lineno">44</tt>  <tt class="py-line">            <tt class="py-comment"># if a list of values is defined, show combobox</tt> </tt>
 
118
<a name="L45"></a><tt class="py-lineno">45</tt>  <tt class="py-line">            <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-11" class="py-name" targets="Variable screenlets.options.base.Option.widget=screenlets.options.base.Option-class.html#widget"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-11', 'widget', 'link-11');">widget</a></tt> <tt class="py-op">=</tt> <tt class="py-name">gtk</tt><tt class="py-op">.</tt><tt class="py-name">combo_box_new_text</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
 
119
<a name="L46"></a><tt class="py-lineno">46</tt>  <tt class="py-line">            <tt class="py-name">p</tt> <tt class="py-op">=</tt> <tt class="py-op">-</tt><tt class="py-number">1</tt> </tt>
 
120
<a name="L47"></a><tt class="py-lineno">47</tt>  <tt class="py-line">            <tt class="py-name">i</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt>
 
121
<a name="L48"></a><tt class="py-lineno">48</tt>  <tt class="py-line">            <tt class="py-keyword">for</tt> <tt class="py-name">s</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-12" class="py-name"><a title="screenlets.options.string_option.StringOption.choices" class="py-name" href="#" onclick="return doclink('link-12', 'choices', 'link-5');">choices</a></tt><tt class="py-op">:</tt> </tt>
 
122
<a name="L49"></a><tt class="py-lineno">49</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-13" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-13', 'widget', 'link-11');">widget</a></tt><tt class="py-op">.</tt><tt class="py-name">append_text</tt><tt class="py-op">(</tt><tt class="py-name">s</tt><tt class="py-op">)</tt> </tt>
 
123
<a name="L50"></a><tt class="py-lineno">50</tt>  <tt class="py-line">                <tt class="py-keyword">if</tt> <tt class="py-name">s</tt><tt class="py-op">==</tt><tt class="py-name">value</tt><tt class="py-op">:</tt> </tt>
 
124
<a name="L51"></a><tt class="py-lineno">51</tt>  <tt class="py-line">                    <tt class="py-name">p</tt> <tt class="py-op">=</tt> <tt class="py-name">i</tt> </tt>
 
125
<a name="L52"></a><tt class="py-lineno">52</tt>  <tt class="py-line">                <tt class="py-name">i</tt><tt class="py-op">+=</tt><tt class="py-number">1</tt> </tt>
 
126
<a name="L53"></a><tt class="py-lineno">53</tt>  <tt class="py-line">            <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-14" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-14', 'widget', 'link-11');">widget</a></tt><tt class="py-op">.</tt><tt class="py-name">set_active</tt><tt class="py-op">(</tt><tt class="py-name">p</tt><tt class="py-op">)</tt> </tt>
 
127
<a name="L54"></a><tt class="py-lineno">54</tt>  <tt class="py-line">        <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
 
128
<a name="L55"></a><tt class="py-lineno">55</tt>  <tt class="py-line">            <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-15" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-15', 'widget', 'link-11');">widget</a></tt> <tt class="py-op">=</tt> <tt class="py-name">gtk</tt><tt class="py-op">.</tt><tt class="py-name">Entry</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
 
129
<a name="L56"></a><tt class="py-lineno">56</tt>  <tt class="py-line">            <tt class="py-comment"># if it is a password, set text to be invisible</tt> </tt>
 
130
<a name="L57"></a><tt class="py-lineno">57</tt>  <tt class="py-line">            <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-16" class="py-name"><a title="screenlets.options.string_option.StringOption.password
 
131
screenlets.plugins.keyring.KeyRing.Key.password" class="py-name" href="#" onclick="return doclink('link-16', 'password', 'link-6');">password</a></tt><tt class="py-op">:</tt> </tt>
 
132
<a name="L58"></a><tt class="py-lineno">58</tt>  <tt class="py-line">                <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-17" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-17', 'widget', 'link-11');">widget</a></tt><tt class="py-op">.</tt><tt class="py-name">set_visibility</tt><tt class="py-op">(</tt><tt class="py-name">False</tt><tt class="py-op">)</tt> </tt>
 
133
<a name="L59"></a><tt class="py-lineno">59</tt>  <tt class="py-line"> </tt>
 
134
<a name="L60"></a><tt class="py-lineno">60</tt>  <tt class="py-line">        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-18" class="py-name" targets="Method screenlets.options.account_option.AccountOption.set_value()=screenlets.options.account_option.AccountOption-class.html#set_value,Method screenlets.options.base.Option.set_value()=screenlets.options.base.Option-class.html#set_value,Method screenlets.options.boolean_option.BoolOption.set_value()=screenlets.options.boolean_option.BoolOption-class.html#set_value,Method screenlets.options.colour_option.ColorOption.set_value()=screenlets.options.colour_option.ColorOption-class.html#set_value,Method screenlets.options.file_option.FileOption.set_value()=screenlets.options.file_option.FileOption-class.html#set_value,Method screenlets.options.font_option.FontOption.set_value()=screenlets.options.font_option.FontOption-class.html#set_value,Method screenlets.options.list_option.ListOption.set_value()=screenlets.options.list_option.ListOption-class.html#set_value,Method screenlets.options.number_option.IntOption.set_value()=screenlets.options.number_option.IntOption-class.html#set_value,Method screenlets.options.string_option.StringOption.set_value()=screenlets.options.string_option.StringOption-class.html#set_value,Method screenlets.options.time_option.TimeOption.set_value()=screenlets.options.time_option.TimeOption-class.html#set_value"><a title="screenlets.options.account_option.AccountOption.set_value
 
135
screenlets.options.base.Option.set_value
 
136
screenlets.options.boolean_option.BoolOption.set_value
 
137
screenlets.options.colour_option.ColorOption.set_value
 
138
screenlets.options.file_option.FileOption.set_value
 
139
screenlets.options.font_option.FontOption.set_value
 
140
screenlets.options.list_option.ListOption.set_value
 
141
screenlets.options.number_option.IntOption.set_value
 
142
screenlets.options.string_option.StringOption.set_value
 
143
screenlets.options.time_option.TimeOption.set_value" class="py-name" href="#" onclick="return doclink('link-18', 'set_value', 'link-18');">set_value</a></tt><tt class="py-op">(</tt><tt class="py-name">value</tt><tt class="py-op">)</tt> </tt>
 
144
<a name="L61"></a><tt class="py-lineno">61</tt>  <tt class="py-line">        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-19" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-19', 'widget', 'link-11');">widget</a></tt><tt class="py-op">.</tt><tt id="link-20" class="py-name" targets="Method screenlets.plugins.Amarok.AmarokAPI.connect()=screenlets.plugins.Amarok.AmarokAPI-class.html#connect,Method screenlets.plugins.Audacious.AudaciousAPI.connect()=screenlets.plugins.Audacious.AudaciousAPI-class.html#connect,Method screenlets.plugins.Banshee.BansheeAPI.connect()=screenlets.plugins.Banshee.BansheeAPI-class.html#connect,Method screenlets.plugins.Exaile.ExaileAPI.connect()=screenlets.plugins.Exaile.ExaileAPI-class.html#connect,Method screenlets.plugins.GenericPlayer.GenericAPI.connect()=screenlets.plugins.GenericPlayer.GenericAPI-class.html#connect,Method screenlets.plugins.Juk.JukAPI.connect()=screenlets.plugins.Juk.JukAPI-class.html#connect,Method screenlets.plugins.Kaffeine.KaffeineAPI.connect()=screenlets.plugins.Kaffeine.KaffeineAPI-class.html#connect,Method screenlets.plugins.LastFMProxy.LastFMProxyAPI.connect()=screenlets.plugins.LastFMProxy.LastFMProxyAPI-class.html#connect,Method screenlets.plugins.Listen.ListenAPI.connect()=screenlets.plugins.Listen.ListenAPI-class.html#connect,Method screenlets.plugins.Quodlibet.QuodlibetAPI.connect()=screenlets.plugins.Quodlibet.QuodlibetAPI-class.html#connect,Method screenlets.plugins.Rhythmbox.RhythmboxAPI.connect()=screenlets.plugins.Rhythmbox.RhythmboxAPI-class.html#connect,Method screenlets.plugins.Sonata.SonataAPI.connect()=screenlets.plugins.Sonata.SonataAPI-class.html#connect,Method screenlets.plugins.Songbird.SongbirdAPI.connect()=screenlets.plugins.Songbird.SongbirdAPI-class.html#connect,Function screenlets.plugins.mpdclient2.connect()=screenlets.plugins.mpdclient2-module.html#connect"><a title="screenlets.plugins.Amarok.AmarokAPI.connect
 
145
screenlets.plugins.Audacious.AudaciousAPI.connect
 
146
screenlets.plugins.Banshee.BansheeAPI.connect
 
147
screenlets.plugins.Exaile.ExaileAPI.connect
 
148
screenlets.plugins.GenericPlayer.GenericAPI.connect
 
149
screenlets.plugins.Juk.JukAPI.connect
 
150
screenlets.plugins.Kaffeine.KaffeineAPI.connect
 
151
screenlets.plugins.LastFMProxy.LastFMProxyAPI.connect
 
152
screenlets.plugins.Listen.ListenAPI.connect
 
153
screenlets.plugins.Quodlibet.QuodlibetAPI.connect
 
154
screenlets.plugins.Rhythmbox.RhythmboxAPI.connect
 
155
screenlets.plugins.Sonata.SonataAPI.connect
 
156
screenlets.plugins.Songbird.SongbirdAPI.connect
 
157
screenlets.plugins.mpdclient2.connect" class="py-name" href="#" onclick="return doclink('link-20', 'connect', 'link-20');">connect</a></tt><tt class="py-op">(</tt><tt class="py-string">"changed"</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-21" class="py-name" targets="Method screenlets.options.account_option.AccountOption.has_changed()=screenlets.options.account_option.AccountOption-class.html#has_changed,Method screenlets.options.base.Option.has_changed()=screenlets.options.base.Option-class.html#has_changed,Method screenlets.options.boolean_option.BoolOption.has_changed()=screenlets.options.boolean_option.BoolOption-class.html#has_changed,Method screenlets.options.colour_option.ColorOption.has_changed()=screenlets.options.colour_option.ColorOption-class.html#has_changed,Method screenlets.options.colour_option.ColorsOption.has_changed()=screenlets.options.colour_option.ColorsOption-class.html#has_changed,Method screenlets.options.file_option.FileOption.has_changed()=screenlets.options.file_option.FileOption-class.html#has_changed,Method screenlets.options.file_option.ImageOption.has_changed()=screenlets.options.file_option.ImageOption-class.html#has_changed,Method screenlets.options.font_option.FontOption.has_changed()=screenlets.options.font_option.FontOption-class.html#has_changed,Method screenlets.options.list_option.ListOption.has_changed()=screenlets.options.list_option.ListOption-class.html#has_changed,Method screenlets.options.number_option.FloatOption.has_changed()=screenlets.options.number_option.FloatOption-class.html#has_changed,Method screenlets.options.number_option.IntOption.has_changed()=screenlets.options.number_option.IntOption-class.html#has_changed,Method screenlets.options.string_option.StringOption.has_changed()=screenlets.options.string_option.StringOption-class.html#has_changed,Method screenlets.options.time_option.TimeOption.has_changed()=screenlets.options.time_option.TimeOption-class.html#has_changed"><a title="screenlets.options.account_option.AccountOption.has_changed
 
158
screenlets.options.base.Option.has_changed
 
159
screenlets.options.boolean_option.BoolOption.has_changed
 
160
screenlets.options.colour_option.ColorOption.has_changed
 
161
screenlets.options.colour_option.ColorsOption.has_changed
 
162
screenlets.options.file_option.FileOption.has_changed
 
163
screenlets.options.file_option.ImageOption.has_changed
 
164
screenlets.options.font_option.FontOption.has_changed
 
165
screenlets.options.list_option.ListOption.has_changed
 
166
screenlets.options.number_option.FloatOption.has_changed
 
167
screenlets.options.number_option.IntOption.has_changed
 
168
screenlets.options.string_option.StringOption.has_changed
 
169
screenlets.options.time_option.TimeOption.has_changed" class="py-name" href="#" onclick="return doclink('link-21', 'has_changed', 'link-21');">has_changed</a></tt><tt class="py-op">)</tt> </tt>
 
170
<a name="L62"></a><tt class="py-lineno">62</tt>  <tt class="py-line">        <tt class="py-comment">#self.widget.set_size_request(180, 28)</tt> </tt>
 
171
<a name="L63"></a><tt class="py-lineno">63</tt>  <tt class="py-line">        <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-22" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-22', 'widget', 'link-11');">widget</a></tt> </tt>
 
172
</div><a name="L64"></a><tt class="py-lineno">64</tt>  <tt class="py-line"> </tt>
 
173
<a name="StringOption.set_value"></a><div id="StringOption.set_value-def"><a name="L65"></a><tt class="py-lineno">65</tt> <a class="py-toggle" href="#" id="StringOption.set_value-toggle" onclick="return toggle('StringOption.set_value');">-</a><tt class="py-line">    <tt class="py-keyword">def</tt> <a class="py-def-name" href="screenlets.options.string_option.StringOption-class.html#set_value">set_value</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
 
174
</div><div id="StringOption.set_value-collapsed" style="display:none;" pad="++" indent="++++++++"></div><div id="StringOption.set_value-expanded"><a name="L66"></a><tt class="py-lineno">66</tt>  <tt class="py-line">        <tt class="py-docstring">"""Set the string value as required."""</tt> </tt>
 
175
<a name="L67"></a><tt class="py-lineno">67</tt>  <tt class="py-line">        <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">value</tt> <tt class="py-op">=</tt> <tt class="py-name">value</tt> </tt>
 
176
<a name="L68"></a><tt class="py-lineno">68</tt>  <tt class="py-line">        <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-23" class="py-name"><a title="screenlets.options.string_option.StringOption.choices" class="py-name" href="#" onclick="return doclink('link-23', 'choices', 'link-5');">choices</a></tt><tt class="py-op">:</tt> </tt>
 
177
<a name="L69"></a><tt class="py-lineno">69</tt>  <tt class="py-line">            <tt class="py-comment"># TODO self.widget.set_active(p)</tt> </tt>
 
178
<a name="L70"></a><tt class="py-lineno">70</tt>  <tt class="py-line">            <tt class="py-keyword">pass</tt> </tt>
 
179
<a name="L71"></a><tt class="py-lineno">71</tt>  <tt class="py-line">        <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
 
180
<a name="L72"></a><tt class="py-lineno">72</tt>  <tt class="py-line">            <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-24" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-24', 'widget', 'link-11');">widget</a></tt><tt class="py-op">.</tt><tt id="link-25" class="py-name" targets="Method screenlets.WrapLabel.set_text()=screenlets.WrapLabel-class.html#set_text"><a title="screenlets.WrapLabel.set_text" class="py-name" href="#" onclick="return doclink('link-25', 'set_text', 'link-25');">set_text</a></tt><tt class="py-op">(</tt><tt class="py-name">value</tt><tt class="py-op">)</tt> </tt>
 
181
</div><a name="L73"></a><tt class="py-lineno">73</tt>  <tt class="py-line"> </tt>
 
182
<a name="StringOption.has_changed"></a><div id="StringOption.has_changed-def"><a name="L74"></a><tt class="py-lineno">74</tt> <a class="py-toggle" href="#" id="StringOption.has_changed-toggle" onclick="return toggle('StringOption.has_changed');">-</a><tt class="py-line">    <tt class="py-keyword">def</tt> <a class="py-def-name" href="screenlets.options.string_option.StringOption-class.html#has_changed">has_changed</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">widget</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
 
183
</div><div id="StringOption.has_changed-collapsed" style="display:none;" pad="++" indent="++++++++"></div><div id="StringOption.has_changed-expanded"><a name="L75"></a><tt class="py-lineno">75</tt>  <tt class="py-line">        <tt class="py-docstring">"""Executed when the widget event kicks off."""</tt> </tt>
 
184
<a name="L76"></a><tt class="py-lineno">76</tt>  <tt class="py-line">        <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-26" class="py-name"><a title="screenlets.options.string_option.StringOption.choices" class="py-name" href="#" onclick="return doclink('link-26', 'choices', 'link-5');">choices</a></tt><tt class="py-op">:</tt> </tt>
 
185
<a name="L77"></a><tt class="py-lineno">77</tt>  <tt class="py-line">            <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-27" class="py-name"><a title="screenlets.options.account_option.AccountOption.set_value
 
186
screenlets.options.base.Option.set_value
 
187
screenlets.options.boolean_option.BoolOption.set_value
 
188
screenlets.options.colour_option.ColorOption.set_value
 
189
screenlets.options.file_option.FileOption.set_value
 
190
screenlets.options.font_option.FontOption.set_value
 
191
screenlets.options.list_option.ListOption.set_value
 
192
screenlets.options.number_option.IntOption.set_value
 
193
screenlets.options.string_option.StringOption.set_value
 
194
screenlets.options.time_option.TimeOption.set_value" class="py-name" href="#" onclick="return doclink('link-27', 'set_value', 'link-18');">set_value</a></tt><tt class="py-op">(</tt> <tt id="link-28" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-28', 'widget', 'link-11');">widget</a></tt><tt class="py-op">.</tt><tt class="py-name">get_active_text</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
 
195
<a name="L78"></a><tt class="py-lineno">78</tt>  <tt class="py-line">        <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
 
196
<a name="L79"></a><tt class="py-lineno">79</tt>  <tt class="py-line">            <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-29" class="py-name"><a title="screenlets.options.account_option.AccountOption.set_value
 
197
screenlets.options.base.Option.set_value
 
198
screenlets.options.boolean_option.BoolOption.set_value
 
199
screenlets.options.colour_option.ColorOption.set_value
 
200
screenlets.options.file_option.FileOption.set_value
 
201
screenlets.options.font_option.FontOption.set_value
 
202
screenlets.options.list_option.ListOption.set_value
 
203
screenlets.options.number_option.IntOption.set_value
 
204
screenlets.options.string_option.StringOption.set_value
 
205
screenlets.options.time_option.TimeOption.set_value" class="py-name" href="#" onclick="return doclink('link-29', 'set_value', 'link-18');">set_value</a></tt><tt class="py-op">(</tt> <tt id="link-30" class="py-name"><a title="screenlets.options.base.Option.widget" class="py-name" href="#" onclick="return doclink('link-30', 'widget', 'link-11');">widget</a></tt><tt class="py-op">.</tt><tt class="py-name">get_text</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">)</tt> </tt>
 
206
<a name="L80"></a><tt class="py-lineno">80</tt>  <tt class="py-line">        <tt class="py-name">super</tt><tt class="py-op">(</tt><tt id="link-31" class="py-name" targets="Class screenlets.options.string_option.StringOption=screenlets.options.string_option.StringOption-class.html"><a title="screenlets.options.string_option.StringOption" class="py-name" href="#" onclick="return doclink('link-31', 'StringOption', 'link-31');">StringOption</a></tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-32" class="py-name"><a title="screenlets.options.account_option.AccountOption.has_changed
 
207
screenlets.options.base.Option.has_changed
 
208
screenlets.options.boolean_option.BoolOption.has_changed
 
209
screenlets.options.colour_option.ColorOption.has_changed
 
210
screenlets.options.colour_option.ColorsOption.has_changed
 
211
screenlets.options.file_option.FileOption.has_changed
 
212
screenlets.options.file_option.ImageOption.has_changed
 
213
screenlets.options.font_option.FontOption.has_changed
 
214
screenlets.options.list_option.ListOption.has_changed
 
215
screenlets.options.number_option.FloatOption.has_changed
 
216
screenlets.options.number_option.IntOption.has_changed
 
217
screenlets.options.string_option.StringOption.has_changed
 
218
screenlets.options.time_option.TimeOption.has_changed" class="py-name" href="#" onclick="return doclink('link-32', 'has_changed', 'link-21');">has_changed</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
 
219
</div></div><a name="L81"></a><tt class="py-lineno">81</tt>  <tt class="py-line"> </tt><script type="text/javascript">
 
220
<!--
 
221
expandto(location.href);
 
222
// -->
 
223
</script>
 
224
</pre>
 
225
<br />
 
226
<!-- ==================== NAVIGATION BAR ==================== -->
 
227
<table class="navbar" border="0" width="100%" cellpadding="0"
 
228
       bgcolor="#a0c0ff" cellspacing="0">
 
229
  <tr valign="middle">
 
230
  <!-- Home link -->
 
231
      <th>&nbsp;&nbsp;&nbsp;<a
 
232
        href="screenlets-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>
 
233
 
 
234
  <!-- Tree link -->
 
235
      <th>&nbsp;&nbsp;&nbsp;<a
 
236
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
 
237
 
 
238
  <!-- Index link -->
 
239
      <th>&nbsp;&nbsp;&nbsp;<a
 
240
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
 
241
 
 
242
  <!-- Help link -->
 
243
      <th>&nbsp;&nbsp;&nbsp;<a
 
244
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
 
245
 
 
246
  <!-- Project homepage -->
 
247
      <th class="navbar" align="right" width="100%">
 
248
        <table border="0" cellpadding="0" cellspacing="0">
 
249
          <tr><th class="navbar" align="center"
 
250
            >Screenlets 0.1.4</th>
 
251
          </tr></table></th>
 
252
  </tr>
 
253
</table>
 
254
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
 
255
  <tr>
 
256
    <td align="left" class="footer">
 
257
    Generated by Epydoc 3.0.1 on Mon Jun  6 10:56:39 2011
 
258
    </td>
 
259
    <td align="right" class="footer">
 
260
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
 
261
        >http://epydoc.sourceforge.net</a>
 
262
    </td>
 
263
  </tr>
 
264
</table>
 
265
 
 
266
<script type="text/javascript">
 
267
  <!--
 
268
  // Private objects are initially displayed (because if
 
269
  // javascript is turned off then we want them to be
 
270
  // visible); but by default, we want to hide them.  So hide
 
271
  // them unless we have a cookie that says to show them.
 
272
  checkCookie();
 
273
  // -->
 
274
</script>
 
275
</body>
 
276
</html>