Changeset - 6284a812da50
[Not reviewed]
default
0 3 0
dmcc - 22 years ago 2002-07-07 06:53:32

makefile - add link to ../Widgets/FlyingFader.py
makefile - add link to ../Widgets/FlyingFader.py
panels.py - use above link, incorporate FlyingFaders. some layout issues,
nothing too borked
rsn.py - focus follows mouse so that FFaders get keystrokes
3 files changed with 16 insertions and 14 deletions:
0 comments (0 inline, 0 general)
light8/Makefile
Show inline comments
 
LIB=/usr/local/lib
 

	
 
go: parportmodule.so
 
	ln -s ../Widgets/FlyingFader.py
 
	sudo python pypar
 

	
 
parportmodule.so: parport_wrap.c
 
	gcc -shared -I/usr/local/include/python2.2 parport_wrap.c parport.c -o parportmodule.so 
 

	
 
parport_wrap.c: parport.c parport.i
 
	swig -python parport.i
 

	
 
clean:
 
	rm -f parport_wrap.c *.o *.so
 
\ No newline at end of file
 
	rm -f parport_wrap.c *.o *.so
light8/panels.py
Show inline comments
 
"""some of the panels"""
 

	
 
from Tkinter import *
 
from uihelpers import *
 
import Patch
 
from FlyingFader import FlyingFader
 

	
 
stdfont = ('Arial', 8)
 
monofont = ('Courier', 8)
 

	
 

	
 

	
 
@@ -59,13 +60,14 @@ class Leveldisplay:
 
            colorlabel(l)
 
            channel_levels.append(l)
 
            f.pack(side='top')
 
        # channel_levels is an output - changelevel will use it to access these labels
 

	
 
class Subpanels:
 
    def __init__(self,scenesparent,effectsparent,scalelevels,Subs,xfader,changelevel):
 
    def __init__(self, scenesparent, effectsparent, scalelevels, Subs, xfader,
 
        changelevel):
 
        
 
        sublist = Subs.subs.items()
 
        sublist.sort()
 

	
 
        for name, sub in sublist:
 
            if sub.is_effect:
 
@@ -81,31 +83,29 @@ class Subpanels:
 

	
 
            sub.set_slider_var(scalelevels[name])
 

	
 
            scaleopts = {}
 
            if sub.color:
 
                scaleopts['troughcolor'] = sub.color
 
            s=Scale(f,command=lambda l,name=name: changelevel(name,l),showvalue=0,
 
                    length=300-17,variable=scalelevels[name],width=20,
 
                    to=0,res=.001,from_=1,bd=1, **scaleopts)
 
            l=Label(f,text=str(name), font=stdfont, padx=0, pady=0)
 
            v=Label(f,textvariable=scalelevels[name], font=stdfont, padx=0, pady=0)
 
            l.pack(side='bottom')
 
            v.pack(side='bottom')
 

	
 
            s = FlyingFader(f, label=str(name), variable=scalelevels[name],
 
                    showvalue=0, length=300-17,
 
                    width=20, to=0,res=.001,from_=1,bd=1, font=stdfont,
 
                    **scaleopts)
 

	
 
            for axis in ('y','x'):
 
                cvar=IntVar()
 
                cb=Checkbutton(f,text=axis,variable=cvar,font=stdfont, padx=0, pady=0, bd=1)
 
                cb=Checkbutton(f,text=axis,variable=cvar,font=stdfont, padx=0, 
 
                               pady=0, bd=1)
 
                button = ('Alt','Control')[axis=='y'] # unused?
 
    #            s.bind('<Key-%s>'%axis, lambda ev,cb=cb: cb.invoke)
 
                # s.bind('<Key-%s>'%axis, lambda ev,cb=cb: cb.invoke)
 
                cb.pack(side='bottom',fill='both', padx=0, pady=0)
 
                xfader.registerbutton(name,axis,cvar)
 

	
 
            s.pack(side='left')
 
            s.bind('<3>', lambda evt, v=scalelevels[name]: toggle_slider(v))\
 
            s.bind('<3>', 
 
                lambda evt, v=scalelevels[name]: toggle_slider(v))
 

	
 
            # effects frame?
 
            sframe = Frame(f,bd=2,relief='groove')
 
            sub.draw_tk(sframe)
 
            sframe.pack(side='left',fill='y')
 

	
 
    
light8/rsn.py
Show inline comments
 
@@ -21,12 +21,13 @@ else:
 
    print "Dummy mode"
 
    window_title = "Light 8.8 (Bogus)"
 

	
 
root = Tk()
 
root.wm_title(window_title)
 
root.wm_geometry('+447+373')
 
root.tk_focusFollowsMouse()
 

	
 
import Subs, Patch
 

	
 
def get_data(*args):
 
    Subs.reload_data(DUMMY)
 
    Patch.reload_data(DUMMY)
0 comments (0 inline, 0 general)