You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tdeutils/superkaramba/examples/openCloseTheme/1.py

23 lines
496 B

import dcop
import dcopext
import karamba
from qt import QString, QCString
def closeTheme(theme):
dc = dcop.DCOPClient()
dc.attach()
dc.registerAs('sk_script')
apps = dc.registeredApplications()
for app in apps:
s = str(app)
if s[:12] == 'superkaramba':
d = dcopext.DCOPApp(s, dc)
d.KarambaIface.closeTheme(theme)
def initWidget(widget):
karamba.openTheme('2.theme')
def widgetClicked(widget, x, y, button):
closeTheme('1')