- // start up python and run the user's startup script
- Py_SetProgramName(argv[0]);
- Py_Initialize();
- init_otk();
- init_openbox();
- PyRun_SimpleString("from _otk import *; from _openbox import *;");
- PyRun_SimpleString("openbox = Openbox_instance()");
-
- runPython(SCRIPTDIR"/clientmotion.py"); // moving and resizing clients
- runPython(SCRIPTDIR"/clicks.py"); // titlebar/root clicks and dblclicks
- runPython(_scriptfilepath.c_str());
-
+ // initialize scripting
+ python_init(argv[0]);
+
+ // load config values
+ python_exec(SCRIPTDIR"/config.py"); // load openbox config values
+ // run all of the python scripts
+// python_exec(SCRIPTDIR"/clientmotion.py"); // moving and resizing clients
+// python_exec(SCRIPTDIR"/clicks.py"); // titlebar/root clicks and dblclicks
+ // run the user's script
+ python_exec(_scriptfilepath.c_str());
+