Issue 86: FlowChart Example wrong behaviour
Status:  Fixed
Owner: ----
Closed:  Aug 2009
Reported by Knoch...@gmail.com, Aug 9, 2009
What steps will reproduce the problem?
1. clicking on the symbols in the corners of the box

What is the expected output? What do you see instead?
dunno what should happen. in the simulator left mouseclick produced red dot
staying alive in the lower laft corner of the screen, no matter where the
box is located

What version of the product are you using? On what operating system?
python 2.6; pymt 0.3rc1

Please provide any additional information below.
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\Python26\pymt-0.3rc1\examples\flowchart>python flowchart.py
[DEBUG             ] Fbo will use hardware Framebuffer
[DEBUG             ] Multisampling is available (4)
[DEBUG             ] loading ../flowchart/box.svg
[DEBUG             ] loading transport-shuffle.svg
[ERROR             ] unable to load transport-shuffle.svg
Traceback (most recent call last):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\svg.py", line 43, in
_set_
filename
    self.svg = squirtle.SVG(filename)
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 426, in
__init
__
    self.generate_disp_list()
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 469, in
genera
te_disp_list
    if open(self.filename, 'rb').read(3) == '\x1f\x8b\x08': #gzip magic numbers
IOError: [Errno 2] No such file or directory: 'transport-shuffle.svg'
[WARNING           ] trying
C:\Python26\lib\site-packages\pymt\data/icons/svgtra
nsport-shuffle.svg
[DEBUG             ] loading minus.svg
[ERROR             ] unable to load minus.svg
Traceback (most recent call last):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\svg.py", line 43, in
_set_
filename
    self.svg = squirtle.SVG(filename)
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 426, in
__init
__
    self.generate_disp_list()
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 469, in
genera
te_disp_list
    if open(self.filename, 'rb').read(3) == '\x1f\x8b\x08': #gzip magic numbers
IOError: [Errno 2] No such file or directory: 'minus.svg'
[WARNING           ] trying
C:\Python26\lib\site-packages\pymt\data/icons/svgmin
us.svg
[DEBUG             ] loading plus.svg
[ERROR             ] unable to load plus.svg
Traceback (most recent call last):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\svg.py", line 43, in
_set_
filename
    self.svg = squirtle.SVG(filename)
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 426, in
__init
__
    self.generate_disp_list()
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 469, in
genera
te_disp_list
    if open(self.filename, 'rb').read(3) == '\x1f\x8b\x08': #gzip magic numbers
IOError: [Errno 2] No such file or directory: 'plus.svg'
[WARNING           ] trying
C:\Python26\lib\site-packages\pymt\data/icons/svgplu
s.svg
[DEBUG             ] loading power.svg
[ERROR             ] unable to load power.svg
Traceback (most recent call last):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\svg.py", line 43, in
_set_
filename
    self.svg = squirtle.SVG(filename)
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 426, in
__init
__
    self.generate_disp_list()
  File "C:\Python26\Lib\site-packages\pymt\lib\squirtle.py", line 469, in
genera
te_disp_list
    if open(self.filename, 'rb').read(3) == '\x1f\x8b\x08': #gzip magic numbers
IOError: [Errno 2] No such file or directory: 'power.svg'
[WARNING           ] trying
C:\Python26\lib\site-packages\pymt\data/icons/svgpow
er.svg
[DEBUG             ] Create provider from tuio,0.0.0.0:3333
[INFO              ] listening for Tuio on 0.0.0.0:3333
Traceback (most recent call last):
  File "_ctypes/callbacks.c", line 295, in 'calling callback function'
  File "C:\Python26\lib\site-packages\pyglet\window\win32\__init__.py",
line 849
, in _wnd_proc
    result = event_handler(msg, wParam, lParam)
  File "C:\Python26\lib\site-packages\pyglet\window\win32\__init__.py",
line 102
7, in _event_lbuttondown
    'on_mouse_press', mouse.LEFT, lParam)
  File "C:\Python26\lib\site-packages\pyglet\window\win32\__init__.py",
line 102
1, in _event_mousebutton
    self.dispatch_event(ev, x, y, button, self._get_modifiers())
  File "C:\Python26\lib\site-packages\pyglet\window\__init__.py", line 1217, in
dispatch_event
    EventDispatcher.dispatch_event(self, *args)
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 352, in
dispatch_ev
ent
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 349, in
dispatch_ev
ent
    getattr(self, event_type)(*args)
  File "C:\Python26\Lib\site-packages\pymt\ui\window.py", line 341, in
on_mouse_
press
    return self.sim.dispatch_event('on_mouse_press', x, y, button, modifiers)
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\simulator.py", line 49, in
on_mous
e_press
    getEventLoop().post_dispatch_input('down', cur)
  File "C:\Python26\Lib\site-packages\pymt\mtpyglet.py", line 85, in
post_dispat
ch_input
    listener.dispatch_event('on_touch_down', touch)
  File "C:\Python26\lib\site-packages\pyglet\window\__init__.py", line 1217, in
dispatch_event
    EventDispatcher.dispatch_event(self, *args)
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 352, in
dispatch_ev
ent
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 349, in
dispatch_ev
ent
    getattr(self, event_type)(*args)
  File "C:\Python26\Lib\site-packages\pymt\ui\window.py", line 325, in
on_touch_
down
    if w.dispatch_event('on_touch_down', touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\scatter.py", line 326, in
on_touch_down
    if super(MTScatterWidget, self).on_touch_down(touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 529,
in o
n_touch_down
    if w.dispatch_event('on_touch_down', touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\scatter.py", line 326, in
on_touch_down
    if super(MTScatterWidget, self).on_touch_down(touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 529,
in o
n_touch_down
    if w.dispatch_event('on_touch_down', touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\button.py", line 160,
in o
n_touch_down
    self.dispatch_event('on_press', touch)
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 297,
in d
ispatch_event
    self._raise_dispatch_exception(event_type, args, handler)
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 397, in
_raise_disp
atch_exception
    (event_type, len(args), descr))
TypeError: on_press event was dispatched with 1 arguments, but handler
toggle_ch
ildren at flowchart.py:68 has an incompatible function signature
Traceback (most recent call last):
  File "_ctypes/callbacks.c", line 295, in 'calling callback function'
  File "C:\Python26\lib\site-packages\pyglet\window\win32\__init__.py",
line 849
, in _wnd_proc
    result = event_handler(msg, wParam, lParam)
  File "C:\Python26\lib\site-packages\pyglet\window\win32\__init__.py",
line 102
7, in _event_lbuttondown
    'on_mouse_press', mouse.LEFT, lParam)
  File "C:\Python26\lib\site-packages\pyglet\window\win32\__init__.py",
line 102
1, in _event_mousebutton
    self.dispatch_event(ev, x, y, button, self._get_modifiers())
  File "C:\Python26\lib\site-packages\pyglet\window\__init__.py", line 1217, in
dispatch_event
    EventDispatcher.dispatch_event(self, *args)
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 352, in
dispatch_ev
ent
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 349, in
dispatch_ev
ent
    getattr(self, event_type)(*args)
  File "C:\Python26\Lib\site-packages\pymt\ui\window.py", line 341, in
on_mouse_
press
    return self.sim.dispatch_event('on_mouse_press', x, y, button, modifiers)
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\simulator.py", line 49, in
on_mous
e_press
    getEventLoop().post_dispatch_input('down', cur)
  File "C:\Python26\Lib\site-packages\pymt\mtpyglet.py", line 85, in
post_dispat
ch_input
    listener.dispatch_event('on_touch_down', touch)
  File "C:\Python26\lib\site-packages\pyglet\window\__init__.py", line 1217, in
dispatch_event
    EventDispatcher.dispatch_event(self, *args)
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 352, in
dispatch_ev
ent
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 349, in
dispatch_ev
ent
    getattr(self, event_type)(*args)
  File "C:\Python26\Lib\site-packages\pymt\ui\window.py", line 325, in
on_touch_
down
    if w.dispatch_event('on_touch_down', touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\scatter.py", line 326, in
on_touch_down
    if super(MTScatterWidget, self).on_touch_down(touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 529,
in o
n_touch_down
    if w.dispatch_event('on_touch_down', touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\scatter.py", line 326, in
on_touch_down
    if super(MTScatterWidget, self).on_touch_down(touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 529,
in o
n_touch_down
    if w.dispatch_event('on_touch_down', touch):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 320,
in d
ispatch_event
    event_type, args, getattr(self, event_type))
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 314,
in d
ispatch_event
    if func(*args):
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\button.py", line 160,
in o
n_touch_down
    self.dispatch_event('on_press', touch)
  File "C:\Python26\Lib\site-packages\pymt\ui\widgets\widget.py", line 297,
in d
ispatch_event
    self._raise_dispatch_exception(event_type, args, handler)
  File "C:\Python26\Lib\site-packages\pyglet\event.py", line 397, in
_raise_disp
atch_exception
    (event_type, len(args), descr))
TypeError: on_press event was dispatched with 1 arguments, but handler
remove at
 flowchart.py:84 has an incompatible function signature
[INFO              ] Leaving application in progress...

C:\Python26\pymt-0.3rc1\examples\flowchart>
Aug 16, 2009
Project Member #1 txprog
Flowchart have been rewriten from scratch !
Status: Fixed
Labels: Milestone-0.3 Component-Examples