/[gzz]/gzz/doc/pegboard/gfxdemos_framework--tjl/peg.rst
ViewVC logotype

Diff of /gzz/doc/pegboard/gfxdemos_framework--tjl/peg.rst

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by tjl, Fri Dec 6 12:02:17 2002 UTC revision 1.3 by jvk, Fri Dec 13 12:33:26 2002 UTC
# Line 2  Line 2 
2  PEG gfxdemos_framework--tjl:  PEG gfxdemos_framework--tjl:
3  =============================================================  =============================================================
4    
5  :Author:   Tuomas J. Lukka  :Author:   Tuomas J. Lukka, Janne V. Kujala
6  :Last-Modified: $Date$  :Last-Modified: $Date$
7  :Revision: $Revision$  :Revision: $Revision$
8  :Status:   Incomplete  :Status:   Incomplete
# Line 55  Files, directories Line 55  Files, directories
55  Change the file/directory structure of the demos so that  Change the file/directory structure of the demos so that
56  one file shall contain at most **one** scene object,  one file shall contain at most **one** scene object,
57  and the name of that object will be ``Scene``.  and the name of that object will be ``Scene``.
58    The scene files should be importable as modules,
59    independent of the ``gldemo.py`` wrapper.
60  If several scenes move around a common theme,  If several scenes move around a common theme,
61  they should be placed in their own directory (python  they should be placed in their own directory (python
62  module).  module).
# Line 65  module). Line 67  module).
67    
68  The ``gldemo.py`` wrapper should then be changed to  The ``gldemo.py`` wrapper should then be changed to
69  accept one or more file or directory names.  accept one or more file or directory names.
70    The global window variable ``w`` should be moved
71    to its own module.
72    
73  Scene objects  Scene objects
74  -------------  -------------
# Line 83  OTOH, :: Line 87  OTOH, ::
87  misses the point entirely. The reader, unfamiliar with  misses the point entirely. The reader, unfamiliar with
88  the idea, does **not** understand why this is something  the idea, does **not** understand why this is something
89  she'd like to see. Demos not fulfilling this requirement  she'd like to see. Demos not fulfilling this requirement
90  shall be relegated to the directory ``gfx/demo/pointless''.  shall be relegated to the directory ``gfx/demo/pointless``.
91    
92  Instead of the current ``key(self, k)'' mechanism where  Instead of the current ``key(self, k)`` mechanism where
93  key presses are decoded in a sequence of if statements,  key presses are decoded in a sequence of if statements,
94  each Scene class shall contain a table ``keys''::  each Scene class shall contain a table ``keys``::
95            
96      keys = [      keys = [
97          Toggle("fillets", 0, "Filleting", "f"),          Toggle("fillets", 0, "Filleting", "f"),
# Line 96  each Scene class shall contain a table ` Line 100  each Scene class shall contain a table `
100          ...          ...
101      ]      ]
102    
103  where the ``Toggle'' and others come from XXX.  where the ``Toggle`` and others come from XXX.
104    
105  The scene mechanism ::  The scene mechanism ::
106            

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26