Update of /cvsroot/freevo/freevo/Docs/html/SourceDoc
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13634/SourceDoc

Modified Files:
        Mbus.html MenuSystem.html Mevas.html Notifier.html PyEPG.html 
Added Files:
        GUI.html 
Log Message:
update

Index: MenuSystem.html
===================================================================
RCS file: /cvsroot/freevo/freevo/Docs/html/SourceDoc/MenuSystem.html,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** MenuSystem.html     12 Dec 2004 17:03:58 -0000      1.1
--- MenuSystem.html     18 Dec 2004 20:08:14 -0000      1.2
***************
*** 9,16 ****
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="../modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="../modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="../modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="../modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
--- 9,16 ----
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="/moin-1.3.1/modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="/moin-1.3.1/modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="/moin-1.3.1/modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="/moin-1.3.1/modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
***************
*** 189,193 ****
  </div>
  <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-12 
10:54:16 by <span title="134.102.71.53">Dischi</span>
! <br>Current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/MenuSystem";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/MenuSystem</a></p>
  </div> <!-- end page -->
  </body>
--- 189,193 ----
  </div>
  <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-12 
10:54:16 by <span title="134.102.71.53">Dischi</span>
! <br>current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/MenuSystem";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/MenuSystem</a></p>
  </div> <!-- end page -->
  </body>

Index: Notifier.html
===================================================================
RCS file: /cvsroot/freevo/freevo/Docs/html/SourceDoc/Notifier.html,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** Notifier.html       12 Dec 2004 17:03:58 -0000      1.1
--- Notifier.html       18 Dec 2004 20:08:14 -0000      1.2
***************
*** 9,16 ****
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="../modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="../modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="../modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="../modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
--- 9,16 ----
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="/moin-1.3.1/modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="/moin-1.3.1/modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="/moin-1.3.1/modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="/moin-1.3.1/modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
***************
*** 44,54 ****
  <div lang="en" id="content" dir="ltr">
  <a id="top"></a>
  <p> </p>
! <p>PleaseUpdate: add usage description </p>
  <a id="bottom"></a>
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-11 
12:34:01 by <span title="134.102.71.53">Dischi</span>
! <br>Current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Notifier";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Notifier</a></p>
  </div> <!-- end page -->
  </body>
--- 44,175 ----
  <div lang="en" id="content" dir="ltr">
  <a id="top"></a>
+ <ol>
+ 
+ <li>
+ <a href="#head-f7fc3a39f051d124dad94023af1a29418972f196">Introduction</a>
+ </li>
+ 
+ <li>
+ <a href="#head-b9348352cb263ec32411709b6cd135aadb78a460">API</a>
+ <ol>
+ 
+ <li>
+ <a href="#head-741b7fd449c35d19d1286188f52b8dcc3dedacb1">Sockets</a>
+ </li>
+ 
+ <li>
+ <a href="#head-976fc205b9396cea3569802ce852c2f16a3210e8">Timer</a>
+ </li>
+ 
+ <li>
+ <a href="#head-6122f9f5373c59355645dfd8d5e4e1d559b8c000">External 
Dispatcher</a>
+ </li>
+ 
+ <li>
+ <a href="#head-a7254c4fc42c1ed2503cd639201e6fb2d210e796">Callbacks</a>
+ </li>
+ 
+ </ol>
+ 
+ </li>
+ 
+ </ol>
  <p> </p>
! 
! <h2 id="head-f7fc3a39f051d124dad94023af1a29418972f196">Introduction</h2>
! 
! <p>To be notified or to be threaded that is the question! </p>
! <p>As the package name may suggest, pyNotifier is a notifier/event scheduler 
abstraction written in python. It implements notification mechanisms for socket 
events (read or write) and timers. Additionally external event dispatchers may 
be called during an idle period. </p>
! <p>Applications using such an notifier mechanism implemented by pyNotifier 
have a specific software architecture. These applications are interactive, 
meaning that almost all action is only done because an event occured that was 
watched by the application. For example a server appliciation has to react if 
there is data waiting on a socket or the socket is again ready to write data to 
the network. Some applications may need to act in a recurrently interval of 
time. Another type of interaction can be found in applications having a 
graphical user interface. </p>
! <p>Most applications of the described type do not need threads. Threading is 
a mechanism that may help to solve some problems, but in most cases it causes 
more problems than it solves. Threads are very often used to process two or 
more tasks in parallel. The belief that threads are the solution to this 
problem is a fallacy. The only solution to this prolbem is the existence of 
several CPUs. A quasi parallel order of events may be solved by using threads, 
but can also be solved by using a notifier. When using threads the critical 
sections of the programs must be locked by using adequate algorithm as the 
thread scheduler may interrupt a function at any point. By using a notifier 
this problems are irrelevant as a notifier just schedules the next event, when 
the handler of the previous event is finished. i.e. there are no critcal 
sections that have to be protected. Being able to forego on any kind of 
protection for critical sections reduces the length and increases the clarity 
 of the source code. </p>
! <p>Application programmers who want to use a notifier/event scheduler based 
architecture for their software may run into one problem when trying to 
implement a graphical user interface for the X11 Window System. As the X11 
window system itself uses a event based architecture all known widget set 
implementations are also based on such mechanisms. Examples for such widget 
sets are GTK+, Qt or wxWindows. The problem is that these software packages 
implement their own notifier/event schedulers. To solve this problem pyNotifier 
provides the possibility to wrap the notifier of a selected widget set, so that 
applications using the pyNotifier API may still be able to use a widget set 
without the need to convert their code to the notifier API of the widget set. 
Currently wrappers for the previously listed widget sets are available. </p>
! 
! <h2 id="head-b9348352cb263ec32411709b6cd135aadb78a460">API</h2>
! 
! <p>An application using pyNotifier has to initialise the notifier, i.e. it 
has to choose which notifier implementation should be used. This is done by 
calling the 'init' function </p>
! 
! <pre>
! def init( type = GENERIC ):
! </pre>
! <p>If no argument is given to the 'init' function the internal implementation 
of pyNotifier is used. Other possible choices for the 'type' argument are GTK, 
QT and WX (current support for wxWindows is not up-to-date). </p>
! 
! <h3 id="head-741b7fd449c35d19d1286188f52b8dcc3dedacb1">Sockets</h3>
! 
! <p>To get notified when a specific event occurs the application has to 
register its interest for this event. For sockets and files this is done with 
the 'addSocket' function'. </p>
! 
! <pre>
! def addSocket( id, method, condition = IO_IN )
! </pre>
! <p>The 'id' argument may be a socket or file object or a file descriptor that 
can be retrieved by calling the 'fileno()' member function of these objects. 
The second argument 'method' has to be a callable python object that is invoked 
by the notifier if the registered event has occured. The function is invoked 
with the 'id' as an argument. Instead of a normal function the [EMAIL 
PROTECTED] 'Callback'] object provided by pyNotifier may be usful at this 
point. </p>
! <p>To remove a registered socket or file from the notifier the 'removeSocket' 
function has to be invoked. The 'id' is the socket or file object or the file 
descriptor given to 'addSocket' and the optional argument 'condition' may be 
set to IO_IN or IO_OUT depending on the prevuoisly registered event. </p>
! 
! <pre>
! def removeSocket( id, condition = IO_IN )
! </pre>
! <p>Another way to achieve the removal of a socket or file object from the 
notifier is to return False in the callback function. If a callback function 
returns False or nothing it is removed at the application is never again 
triggered if this specific event occurs. </p>
! 
! <h3 id="head-976fc205b9396cea3569802ce852c2f16a3210e8">Timer</h3>
! 
! <p>pyNotifier supports just one type of timer. If a timer is registered for a 
given interval of time the application is recurrently triggered when the timer 
expires. To register a timer the 'addTimer' function has to be invoked. The 
first argument 'interval' must be specified in milliseconds. 'method' is the 
callback function that is invoked by the notifier without any argument when the 
timer expires. </p>
! 
! <pre>
! def addTimer( interval, method ) -&gt; unique timer identifier
! </pre>
! <p>To implement a one-shot timer that is just triggered once and never again 
the application can use the return value of its callback function for this 
timer and return False or None. In this case the notifier automatically removes 
the timer. Another way to remove a timer is to call the method 'removeTimer'. 
</p>
! 
! <pre>
! def removeTimer( id )
! </pre>
! <p>The 'id' argument is the unique timer identifier returned by 'addTimer'. 
</p>
! 
! <h3 id="head-6122f9f5373c59355645dfd8d5e4e1d559b8c000">External 
Dispatcher</h3>
! 
! <p>All already described tasks of an applications are scheduled by events 
that have occured on sockets or files or by pre-defined recurrently time 
intervals. But some applications may also have some tasks that may not need to 
be scheduled by any events or an exact timing. These tasks should be repeated 
quite often, if there is some time to do it. </p>
! <p>pyNotifier provides the feature to add so called external dispatchers. 
These dispatchers are functions that will be invoked in each notifier step 
after all timers and sockets were checked. To add a dispatcher function to the 
notifier main loop the function 'addDispatcher' is provided. The only argument 
to this function is the callback methodthat will be called. </p>
! 
! <pre>
! def addDispatcher( method )
! </pre>
! <p>To remove such a dispatcher function from the notifier main loop 
'removeDispatcher' is used with the call back method as the only argument. </p>
! 
! <pre>
! def removeDispatcher( method )
! </pre>
! <a id="callbacks"></a>
! <p> </p>
! 
! <h3 id="head-a7254c4fc42c1ed2503cd639201e6fb2d210e796">Callbacks</h3>
! 
! <p>pyNotifier provides a class 'Callback' that can be used as a callback 
function that is passed to the 'addSocket' and 'addTimer' function. This class 
provides the possibility to pass more than the specified arguments to the 
callback functions. For example the socket callback function is called with one 
single argument. To pass some state information to the callback function the 
'Callback' object may be used. A default callback function for a socket event 
would look like 'socket1'. </p>
! 
! <pre>
! import notifier
! ...
! notifier.addSocket( fd, socket1 )
! ...
! 
! def socket1( fd ):
!     print 'data received on socket', fd
! </pre>
! <p>'fd' is the 'id' given to 'addSocket'. To pass some state information to 
the callback function it can be done as shown in the following example. </p>
! 
! <pre>
! import notifier
! ...
! notifier.addSocket( fd, notifier.Callback( arg1, arg2 ) )
! ...
! 
! def socket1( fd, arg1, arg2 ):
!     print 'data received on socket', fd
!     print 'additional state information', arg1, arg2
! </pre>
! <p>The arguments given to the Callback object are appended to the original 
list of arguments for the callback function. The argument list to the Callback 
object can be of any length. </p>
! <p>Any comments or questions can be send to </p>
! <p><a href="mailto:[EMAIL PROTECTED]"><img 
src="/moin-1.3.1/modern/img/moin-email.png" alt="[MAILTO]" height="10" 
width="14"> [EMAIL PROTECTED]</a> </p>
  <a id="bottom"></a>
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-18 
16:40:37 by <span title="adsl-9-69.nordcom.uni-bremen.de">crunchy</span>
! <br>current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Notifier";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Notifier</a></p>
  </div> <!-- end page -->
  </body>

Index: Mevas.html
===================================================================
RCS file: /cvsroot/freevo/freevo/Docs/html/SourceDoc/Mevas.html,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** Mevas.html  12 Dec 2004 17:03:58 -0000      1.1
--- Mevas.html  18 Dec 2004 20:08:14 -0000      1.2
***************
*** 9,16 ****
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="../modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="../modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="../modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="../modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
--- 9,16 ----
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="/moin-1.3.1/modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="/moin-1.3.1/modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="/moin-1.3.1/modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="/moin-1.3.1/modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
***************
*** 44,54 ****
  <div lang="en" id="content" dir="ltr">
  <a id="top"></a>
  <p> </p>
! <p>PleaseUpdate: add usage description </p>
  <a id="bottom"></a>
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-11 
12:36:05 by <span title="134.102.71.53">Dischi</span>
! <br>Current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mevas";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mevas</a></p>
  </div> <!-- end page -->
  </body>
--- 44,122 ----
  <div lang="en" id="content" dir="ltr">
  <a id="top"></a>
+ <ol>
+ 
+ <li>
+ <a href="#head-48b88fc86915ffcafaeee3f4fa905bf2563bf7ed">Overview</a>
+ </li>
+ 
+ <li>
+ <a href="#head-f663915e84a5fb33485d5a11dca8553ef1fb1de0">Canvas Objects</a>
+ <ol>
+ 
+ <li>
+ <a href="#head-f8f8b172a9ef50b3359181077cdb69f5bcffbefc">Mevas basic types</a>
+ </li>
+ 
+ <li>
+ <a href="#head-825f40150b051eee4a577bd701290de71ab54a5a">Freevo widgets based 
on mevas</a>
+ </li>
+ 
+ </ol>
+ 
+ <li>
+ <a href="#head-5efb41dd9a060b812c424569b1757ea4f2f6e4c2">Render Engine</a>
+ </li>
+ 
+ <li>
+ <a href="#head-9792664dc7f1a9853377ef89dd27212b8e3ae2b0">Display Engine</a>
+ </li>
+ 
+ </ol>
  <p> </p>
! 
! <h2 id="head-48b88fc86915ffcafaeee3f4fa905bf2563bf7ed">Overview</h2>
! 
! <p>Mevas is a canvas system from designed for <a class="external" 
href="http://projects.sault.org/mebox";><img 
src="/moin-1.3.1/modern/img/moin-www.png" alt="[WWW]" height="11" width="11"> 
MeBox</a>. The source code is in Freevo CVS at lib/mevas, MeBox has no CVS of 
it's own. It's based on pyImlib2 has render engine. </p>
! <p>PleaseUpdate: add more description </p>
! 
! <h2 id="head-f663915e84a5fb33485d5a11dca8553ef1fb1de0">Canvas Objects</h2>
! 
! 
! <h3 id="head-f8f8b172a9ef50b3359181077cdb69f5bcffbefc">Mevas basic types</h3>
! 
! <p>PleaseUpdate: add description </p>
! 
! <h3 id="head-825f40150b051eee4a577bd701290de71ab54a5a">Freevo widgets based 
on mevas</h3>
! 
! <p>PleaseUpdate: add description </p>
! 
! <h2 id="head-5efb41dd9a060b812c424569b1757ea4f2f6e4c2">Render Engine</h2>
! 
! <p>PleaseUpdate: add description </p>
! 
! <h2 id="head-9792664dc7f1a9853377ef89dd27212b8e3ae2b0">Display Engine</h2>
! 
! <p>Mevas uses a special display canvas to show the content. There are several 
display engines in the 'mevas/displays' subdirectory: </p>
! <ul>
! <li><p> bitmapcanvas: This is no real output canvas, it is only a base for 
others. It renders the whole display into one image that can be displayed. Most 
display engines use this way because they always have one big image in memory. 
</p>
! </li>
! <li><p> pygamecanvas: Based on bitmapcanvas this engine uses pygame to show 
the screen. It works on all output modules of SDL, like framebuffer and X11. 
</p>
! </li>
! <li><p> imlib2canvas: This display engine opens an Imlib2 window and uses the 
bitmapcanvas to draw the window content. </p>
! </li>
! <li><p> bmovlcanvas: Use the bmovl fifo to a running mplayer to show the 
screen. Also based on bitmapcanvas. </p>
! </li>
! <li><p> mplayercanvas: Use bmovl2 without the bitmapcanvas to show the 
content on a running mplayer (needs bmovl2 patch for mplayer). </p>
! </li>
! <li><p> ivtvcanvas: Use the ivtv framebuffer to output on ivtv tv cards 
(PleaseUpdate: add more doc) </p>
! </li>
! </ul>
! <p>To use the display engines in Freevo, there must be a file with inheriting 
from a display canvas in src/gui/displays. The output canvas will be chosen by 
the OSD_DISPLAY variable in Freevo (e.g. OSD_DISPLAY='imlib2' will use 
src/gui/display/imlib2.py). </p>
! <p>Right now someone is working on a DirectFB canvas. But it would be nice to 
have more display engines for the best possible tv out. They all will need a 
python lib between C code and mevas. For a list of possible future display 
canvas see <a href="../HelpNeeded.html">HelpNeeded</a>. If you want to help, 
please send a mail to the Freevo devel mailing list or <a class="external" 
href="mailto:[EMAIL PROTECTED]"><img src="/moin-1.3.1/modern/img/moin-www.png" 
alt="[WWW]" height="11" width="11"> contact me</a> directly. </p>
  <a id="bottom"></a>
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-14 
14:29:00 by <span title="riemen.informatik.uni-bremen.de">Dischi</span>
! <br>current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mevas";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mevas</a></p>
  </div> <!-- end page -->
  </body>

Index: Mbus.html
===================================================================
RCS file: /cvsroot/freevo/freevo/Docs/html/SourceDoc/Mbus.html,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** Mbus.html   12 Dec 2004 17:03:58 -0000      1.1
--- Mbus.html   18 Dec 2004 20:08:14 -0000      1.2
***************
*** 9,16 ****
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="../modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="../modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="../modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="../modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
--- 9,16 ----
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="/moin-1.3.1/modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="/moin-1.3.1/modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="/moin-1.3.1/modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="/moin-1.3.1/modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
***************
*** 70,79 ****
  
  <p>mcomm.py is a small layer between Freevo and PyMbus to make usage of the 
mbus simpler. Warning: the interface itself may change in the future, but only 
on some minor details. </p>
! <p>Freevo has a wrapper for the important mbus functions for easier access 
inside helpers and plugins. By using the wrapper, the application will join the 
mbus with the following naming scheme: "app=freevo, type=home-theatre, 
module=name" with name being the name of the helper or 'core' for the main 
freevo application. </p>
! <p>First let's make an example how to use client server communication over 
mbus. That's the only thing working right now in the wrapper, events will come 
later. PyMbus supports much more than the mcomm layer, so maybe it is necessary 
to import mbus in a plugin for special stuff. </p>
  
  <h3 id="head-da2c960c3e618a0716c401064b2b6b207e26509a">Creating a server</h3>
  
! <p>To create a server you must inherit from mcomm.RPCServer. It is possible 
to have more than one server on one bus, the class is only a wrapper for easy 
access. Each function starting with __rpc_ and ending with __ will be 
registered as rpc to the mbus entity. So let's say you have a plugin listening 
to the rpc home.theatre.play, you would create the following plugin: 
  </p>
  <pre>
--- 70,79 ----
  
  <p>mcomm.py is a small layer between Freevo and PyMbus to make usage of the 
mbus simpler. Warning: the interface itself may change in the future, but only 
on some minor details. </p>
! <p>Freevo implements a wrapper for the important mbus functions for easier 
access inside helpers and plugins. By using the wrapper, the application will 
join the mbus with the following naming scheme: "app=freevo, type=home-theatre, 
module=<em>name</em>" with <em>name</em> being the name of the helper or 'core' 
for the main freevo application. </p>
! <p>Let's start with an example how to communicate via Mbus using a 
client/server module. That's the only thing working right now in the wrapper, 
events will come later. PyMbus supports much more than the mcomm layer, so 
maybe it is necessary to import mbus in a plugin for special stuff. </p>
  
  <h3 id="head-da2c960c3e618a0716c401064b2b6b207e26509a">Creating a server</h3>
  
! <p>To create a server you must inherit from mcomm.RPCServer. It is possible 
to have more than one server in an Mbus session. The <em>RPCServer</em> class 
is only a wrapper for easy access. Each function starting with __rpc_ and 
ending with __ will be registered as rpc to the mbus entity. So let's say you 
have a plugin listening to the RPC command home.theatre.play, you would create 
the following plugin: 
  </p>
  <pre>
***************
*** 118,124 ****
      print e
  </pre>
! <p>That's all. mcomm.find will wait on the bus until the freevo core comes up 
(timeout 10 sec). Calling freevo.play will result in a mbus call 
home-theatre.play with the given argument. There are three possible returns: 
</p>
  <p>1. (True, return values): The server sent mcomm.RPCReturn(return values). 
Everything worked as expected. </p>
! <p>2. (False, reason): The server send mcomm.RPCError(reason). The parameter 
are ok, but it was not possible to do what expected. </p>
  <p>3. mcomm.MException is raised. Something went wrong. Possible reasons are 
a crash on server side, a server not answering and so on. </p>
  <p>freevo.play will block until the result is there. If you don't want to 
wait, you can specify a callback to the function: 
--- 118,124 ----
      print e
  </pre>
! <p>That's all. mcomm.find will wait on the Mbus until the freevo core entity 
comes up (timeout 10 sec). The method freevo.play will invoke the Mbus command 
home-theatre.play with the given argument. There are three possible returns: 
</p>
  <p>1. (True, return values): The server sent mcomm.RPCReturn(return values). 
Everything worked as expected. </p>
! <p>2. (False, reason): The server send mcomm.RPCError(reason). The parameters 
are ok, but it was not possible to do what expected. </p>
  <p>3. mcomm.MException is raised. Something went wrong. Possible reasons are 
a crash on server side, a server not answering and so on. </p>
  <p>freevo.play will block until the result is there. If you don't want to 
wait, you can specify a callback to the function: 
***************
*** 135,140 ****
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-12 
11:08:31 by <span title="134.102.71.53">Dischi</span>
! <br>Current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mbus";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mbus</a></p>
  </div> <!-- end page -->
  </body>
--- 135,140 ----
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-15 
08:13:29 by <span title="dataman.informatik.uni-bremen.de">crunchy</span>
! <br>current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mbus";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/Mbus</a></p>
  </div> <!-- end page -->
  </body>

Index: PyEPG.html
===================================================================
RCS file: /cvsroot/freevo/freevo/Docs/html/SourceDoc/PyEPG.html,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** PyEPG.html  12 Dec 2004 17:03:58 -0000      1.1
--- PyEPG.html  18 Dec 2004 20:08:14 -0000      1.2
***************
*** 9,16 ****
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="../modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="../modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="../modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="../modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
--- 9,16 ----
  
  
! <link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="/moin-1.3.1/modern/css/common.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="/moin-1.3.1/modern/css/screen.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="/moin-1.3.1/modern/css/print.css">
! <link rel="stylesheet" type="text/css" charset="utf-8" 
href="/moin-1.3.1/modern/css/freevo.css">
  
  <link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
***************
*** 92,96 ****
  </ol>
  <p> </p>
! <p>PyEPG is an electronic program guide with a database frontent. It is 
located in the Freevo source tree at lib/pyepg but it does not depend on 
Freevo. It only depends on a working sql database interface, right now only <a 
class="external" href="http://sqlite.sf.net";><img 
src="../modern/img/moin-www.png" alt="[WWW]" height="11" width="11"> 
pysqlite</a> is supported. </p>
  
  <h2 id="head-a2107bc32b8b821c9c1e2edfa936eaecc507741e">Setup the database</h2>
--- 92,96 ----
  </ol>
  <p> </p>
! <p>PyEPG is an electronic program guide with a database frontent. It is 
located in the Freevo source tree at lib/pyepg but it does not depend on 
Freevo. It only depends on a working sql database interface, right now only <a 
class="external" href="http://sqlite.sf.net";><img 
src="/moin-1.3.1/modern/img/moin-www.png" alt="[WWW]" height="11" width="11"> 
pysqlite</a> is supported. </p>
  
  <h2 id="head-a2107bc32b8b821c9c1e2edfa936eaecc507741e">Setup the database</h2>
***************
*** 99,103 ****
  </p>
  <pre>
! pysql.connect('sqlite', '/path/to/db')
  </pre>
  <p>After that the database must be loaded. This will load all channel 
informatiosn from the database and create an internal structure of channels. 
You can add channels to the internal list even if they are not in the database 
itself, rename channels or exclude channels from the guide. The load function 
has two optional parameters, the first one the list of (channel id, name) to be 
added and the second one a list of channel ids to be excluded. If the channel 
id of the first parameter is already in the database, the internal channel name 
will be replaced with the given one. All channels given here will also be added 
on top of the internal list. 
--- 99,103 ----
  </p>
  <pre>
! pyepg.connect('sqlite', '/path/to/db')
  </pre>
  <p>After that the database must be loaded. This will load all channel 
informatiosn from the database and create an internal structure of channels. 
You can add channels to the internal list even if they are not in the database 
itself, rename channels or exclude channels from the guide. The load function 
has two optional parameters, the first one the list of (channel id, name) to be 
added and the second one a list of channel ids to be excluded. If the channel 
id of the first parameter is already in the database, the internal channel name 
will be replaced with the given one. All channels given here will also be added 
on top of the internal list. 
***************
*** 123,127 ****
  <h3 id="head-20e8543fa3acf8ff1ab8d665b8fc4779be541499">Using the VDR 
backend</h3>
  
! <p>PleaseUpdate: add description </p>
  
  <h2 id="head-02edeab41680c7a34aca2e1a3175eb310803c2ec">Access the 
database</h2>
--- 123,147 ----
  <h3 id="head-20e8543fa3acf8ff1ab8d665b8fc4779be541499">Using the VDR 
backend</h3>
  
! <p>The VDR backend requires vdrpylib to be installed (from CVS), which can be 
found at <a href="http://sourceforge.net/projects/vdrpylib/";><img 
src="/moin-1.3.1/modern/img/moin-www.png" alt="[WWW]" height="11" width="11"> 
http://sourceforge.net/projects/vdrpylib/</a>.  Updating from VDR does not 
require any more parameters but you may pass some to override the defaults set 
by PyEPG and vdrpylib.  The simplest update call would be: 
! </p>
! <pre>
! pyepg.update('vdr')
! </pre>
! <p>However, other parameters (defaults shown) available are: 
! </p>
! <pre>
! vdr_dir='/video'
! channels_file='channels.conf'
! epg_file='epg.dat'
! host='localhost'
! port=2001
! access_by='sid'
! </pre>
! <p>So, Freevo's tv_grab helper does the following: 
! </p>
! <pre>
! pyepg.update('vdr', config.VDR_DIR, config.VDR_CHANNELS, config.VDR_EPG,
!              config.VDR_HOST, config.VDR_PORT, config.VDR_ACCESS_ID)
! </pre>
  
  <h2 id="head-02edeab41680c7a34aca2e1a3175eb310803c2ec">Access the 
database</h2>
***************
*** 213,218 ****
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-12 
15:04:41 by <span title="blk-215-73-155.eastlink.ca">rshortt</span>
! <br>Current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/PyEPG";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/PyEPG</a></p>
  </div> <!-- end page -->
  </body>
--- 233,238 ----
  
  </div>
! <p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-15 
15:44:27 by <span title="halifax-cr-gw.infointeractive.com">rshortt</span>
! <br>current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/PyEPG";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/PyEPG</a></p>
  </div> <!-- end page -->
  </body>

--- NEW FILE: GUI.html ---
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" 
"http://www.w3.org/TR/html4/strict.dtd";>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<meta name="robots" content="index,nofollow">


<title>SourceDoc/GUI - Freevo 2.0 Wiki</title>


<link rel="stylesheet" type="text/css" charset="utf-8" media="all" 
href="/moin-1.3.1/modern/css/common.css">
<link rel="stylesheet" type="text/css" charset="utf-8" media="screen" 
href="/moin-1.3.1/modern/css/screen.css">
<link rel="stylesheet" type="text/css" charset="utf-8" media="print" 
href="/moin-1.3.1/modern/css/print.css">
<link rel="stylesheet" type="text/css" charset="utf-8" 
href="/moin-1.3.1/modern/css/freevo.css">

<link rel="alternate" title="Freevo 2.0 Wiki Recent Changes" 
href="/cgi-bin/freevo-2.0/RecentChanges?action=rss_rc&amp;ddiffs=1&amp;unique=1"
 type="application/rss+xml">
<link rel="Start" href="/cgi-bin/freevo-2.0/Index">
<link rel="Alternate" title="Wiki Markup" 
href="/cgi-bin/freevo-2.0/SourceDoc/GUI?action=raw">
<link rel="Alternate" media="print" title="Print View" 
href="/cgi-bin/freevo-2.0/SourceDoc/GUI?action=print">
<link rel="Up" href="/cgi-bin/freevo-2.0/SourceDoc">
<link rel="Search" href="/cgi-bin/freevo-2.0/FindPage">
<link rel="Index" href="/cgi-bin/freevo-2.0/TitleIndex">
<link rel="Glossary" href="/cgi-bin/freevo-2.0/WordIndex">
<link rel="Help" href="/cgi-bin/freevo-2.0/HelpOnFormatting">
</head>

<body  lang="en" dir="ltr">

            <!-- Header Logo and Status Line -->
<div id="titlebar"><span class="name"><a href="http://freevo.sourceforge.net/"; 
target="_blank">Freevo</a></span></div>
<div id="header">
<ul>

        <li><a href="../Index.html">User Documentation</a></li>
        <li id="current"><a href="../SourceDoc.html">Source 
Documenation</a></li>
        
</ul>
</div>
<p>&nbsp;</p>
<div id="page" lang="en" dir="ltr"><!-- start page -->


<h1 id="title">SourceDoc/GUI</h1>
<div lang="en" id="content" dir="ltr">
<a id="top"></a>
<p>Subpages: </p>
<ul>
<li><p> <a href="../SourceDoc/GUI/Display.html">Display Engines</a> </p>
</li>
<li><p> Widgets </p>
</li>
<li><p> Areas </p>
</li>
<li><p> Windows and Popup Boxes </p>
</li>
<li><p> Animation </p>
</li>
</ul>

<h2 id="head-f88744881a341ddc42526632485ba81a06124b8c">Overview</h2>

<p>PleaseUpdate: add documentation </p>
<a id="bottom"></a>

</div>
<p id="pageinfo" class="info" lang="en" dir="ltr">last edited 2004-12-14 
13:46:35 by <span title="riemen.informatik.uni-bremen.de">Dischi</span>
<br>current version: <a 
href="http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/GUI";>http://freevo.sourceforge.net/cgi-bin/freevo-2.0/SourceDoc/GUI</a></p>
</div> <!-- end page -->
</body>
</html>



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to