+
+ _actions = new OBActions();
+
+ setMasterHandler(_actions); // set as the master event handler
+
+ // create the mouse cursors we'll use
+ _cursors.session = XCreateFontCursor(otk::OBDisplay::display, XC_left_ptr);
+ _cursors.move = XCreateFontCursor(otk::OBDisplay::display, XC_fleur);
+ _cursors.ll_angle = XCreateFontCursor(otk::OBDisplay::display, XC_ll_angle);
+ _cursors.lr_angle = XCreateFontCursor(otk::OBDisplay::display, XC_lr_angle);
+ _cursors.ul_angle = XCreateFontCursor(otk::OBDisplay::display, XC_ul_angle);
+ _cursors.ur_angle = XCreateFontCursor(otk::OBDisplay::display, XC_ur_angle);
+
+ // initialize all the screens
+ OBScreen *screen;
+ screen = new OBScreen(0, _config);
+ if (screen->managed()) {
+ _screens.push_back(screen);
+ _screens[0]->manageExisting();
+ // XXX: "change to" the first workspace on the screen to initialize stuff
+ } else
+ delete screen;
+
+ if (_screens.empty()) {
+ printf(_("No screens were found without a window manager. Exiting.\n"));
+ ::exit(1);
+ }
+
+ // initialize the python interface
+ Py_SetProgramName(argv[0]);
+ Py_Initialize();
+ initopenbox(); // initialize the static 'openbox' module
+ FILE *rcpyfd = fopen("/home/natas/.openbox/user.py", "r");
+ if (!rcpyfd) {
+ printf("failed to load python file /home/natas/.openbox/user.py\n");
+ } else {
+ PyRun_SimpleFile(rcpyfd, "/home/natas/.openbox/user.py");
+ fclose(rcpyfd);
+ }
+