annotate bin/kcclient @ 343:fe9dff7dbffd

added C-l to launch subcomposer- in progress keyboardcomposer will probably launch subcomposer correctly, but i don't even know if KC blocks or not (untested), and the SC is certainly a child process of the KC, which is undesirable. We think that some sort of setpgrp call in the child may fix that.
author Drew Perttula <drewp@bigasterisk.com>
date Mon, 19 Jun 2006 02:20:41 +0000
parents 54774cba50c9
children 179281f28d65
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
205
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
1 #!/usr/bin/env python
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
2
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
3 """send KeyboardComposer a fade request, for use from the shell"""
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
4
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
5 import sys,xmlrpclib
270
54774cba50c9 revive kcclient and fix subcomposer so kcclient works through refreshes
Drew Perttula <drewp@bigasterisk.com>
parents: 205
diff changeset
6 import run_local
54774cba50c9 revive kcclient and fix subcomposer so kcclient works through refreshes
Drew Perttula <drewp@bigasterisk.com>
parents: 205
diff changeset
7 from light9 import networking
205
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
8
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
9 subname = sys.argv[1]
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
10 level = float(sys.argv[2])
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
11 fadesecs = 0
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
12 if len(sys.argv)>3:
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
13 fadesecs = float(sys.argv[3])
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
14
270
54774cba50c9 revive kcclient and fix subcomposer so kcclient works through refreshes
Drew Perttula <drewp@bigasterisk.com>
parents: 205
diff changeset
15 levelserver = xmlrpclib.ServerProxy("http://%s:%s" %
54774cba50c9 revive kcclient and fix subcomposer so kcclient works through refreshes
Drew Perttula <drewp@bigasterisk.com>
parents: 205
diff changeset
16 (networking.kcServer(),
54774cba50c9 revive kcclient and fix subcomposer so kcclient works through refreshes
Drew Perttula <drewp@bigasterisk.com>
parents: 205
diff changeset
17 networking.kcPort()))
205
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
18
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
19 levelserver.fadesub(subname,level,fadesecs)
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
20
3905d3c92aaa twisted mainloop, more row-change keys, xmlrpc fadesub command on port 8050
drewp
parents:
diff changeset
21