e39958306149219c429c817bcee1a35bd378966a
1 # -*- coding: utf-8 -*-
3 formatage des événements
9 from events
import eventNames
11 self
= sys
.modules
[__name__
]
14 return '%3d %3d %3d' % (e
.chan
, e
.key
, e
.vel
)
17 return '%3d %3d' % (e
.chan
, e
.key
)
22 def log_COLSTATECHANGE(e
):
25 return u
'%2d %5s %3s %3s %s' % \
26 (col
.index
, col
.state
, tone
.midi
, tone
.name
, e
.syllabus
)
29 """ formate les événements de colonne COLDOWN, COLUP, COLOVER
33 - nom de la note /A-G[#b]?/
38 return u
'%2d %5s %3s %3s %r' % \
39 (col
.index
, col
.state
, tone
.midi
, tone
.name
, pos
)
41 log_COLDOWN
= log_COLUP
= log_COLOVER
= _log_col
47 for type, name
in eventNames
.items() :
48 f
= getattr(self
, 'log_%s' % name
, log_default
)
51 __all__
= ('pprinters')