Page 8 of 9 FirstFirst ... 6789 LastLast
Results 71 to 80 of 83

Thread: HOWTO: Automating Gnome with Devil's Pie

  1. #71
    Join Date
    Sep 2005
    Location
    USA
    Beans
    777
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: HOWTO: Automating Gnome with Devil's Pie

    Quote Originally Posted by krhek View Post
    I have problems with the "set_workspace" function, which is the main reason why I got interested in this app in the first place, and I really want to get it running. When I execute Devil's Pie in the debug mode I get:

    ** (devilspie:8060): WARNING **: Workspace number 2 does not exist

    (devilspie:8060): Wnck-CRITICAL **: wnck_window_move_to_workspace: assertion `WNCK_IS_WORKSPACE (space)' failed

    Am I doing something wrong? Can it be because I have XGL+Compiz installed?
    Yes, it is probably because you are using Compiz

  2. #72
    Join Date
    Jun 2006
    Location
    Somewhere too cold!
    Beans
    Hidden!

    Re: HOWTO: Automating Gnome with Devil's Pie

    Hi,

    I just installed devilspie (from the repos and I'm using dapper) and I'm already stuck

    From the howto I gather that I need to create one or more files with rules that devilspie read (i.e. .ds files). This output
    Code:
    $ devilspie
    No s-expressions loaded, quiting
    I take it shows that I have no .ds files. However, I have no .devilspie in my home directory nor do I have a /etc/devilspie directory. Still, it is installed, as the response from 'devilspie' show and I get:
    Code:
    $ whereis devilspie
    devilspie: /usr/bin/devilspie /usr/bin/X11/devilspie /usr/share/man/man1/devilspie.1.gz
    So, what I'm I missing here? I basically just need devilspie to do one thing for me (at least for now) and that is to make sure that all windows are opened in the right screen on my TwinView setup. But where is the damn program?!

    Any and all help very much appreciated.
    /Mojoman

  3. #73
    Join Date
    Sep 2005
    Location
    USA
    Beans
    777
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: HOWTO: Automating Gnome with Devil's Pie

    Quote Originally Posted by mojoman View Post
    Hi,

    ...I have no .devilspie in my home directory nor do I have a /etc/devilspie directory...
    /Mojoman
    Just create it:
    Code:
    mkdir ~/.devilspie

  4. #74
    Join Date
    Jun 2006
    Location
    Somewhere too cold!
    Beans
    Hidden!

    Re: HOWTO: Automating Gnome with Devil's Pie

    Hehe,

    I just ran
    Code:
    $ devilspie -d
    Devil's Pie 0.16 starting...
    Loading /etc/devilspie
    /etc/devilspie doesn't exist
    Loading /home/mojoman/.devilspie
    /home/mojoman/.devilspie doesn't exist
    No s-expressions loaded, quiting
    and thought "naw, it can't be that simple.". Well, what do you know...

    Anyway, thanks for the help. You wouldn't know the expression needed to make windows open on the right screen in a twinview setup, would you?

    /Mojoman
    Last edited by mojoman; January 26th, 2007 at 06:02 PM. Reason: hate typos...

  5. #75
    Join Date
    Dec 2006
    Location
    Liechtenstein
    Beans
    24
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: HOWTO: Automating Gnome with Devil's Pie

    Okay, new task for the devilspie-pros out there:
    I want THE Gimp to be a bit more automated, therefore I wrote some expressions, of which some work, and some don't

    Code:
    (if
      (is (application_name) "The GIMP")
      (begin
        (set_workspace 4)
      )
    )
    (if
      (and
        (is (application_name) "The GIMP")
        (is (window_name) "The GIMP")
      )
      (begin
        (above)
        (geometry "272x640+5+24")
      )
    )
    (if 
      (and 
        (is (application_name) "The GIMP")
        (contains (window_name) "Layers, Paths, ")
      )
      (begin
        (above)
        (geometry "273x323+5+693")
      )
    )
    (if
      (and
        (is (application_name) "The GIMP")
        (is (window_name) "Navigation")
      )
      (begin
        (above)
        (geometry "273x323+5+693")
      )
    )
    (if
      (and
        (is (application_name) "The GIMP")
        (contains (window_name) "Untitled")
      )
      (geometry "1085x950+287+24")
    )
    and here the corresponding debug output:

    Code:
    Window Title: 'Navigation'; Application Name: 'The GIMP'; Class: 'Gimp'; Geometry: 250x300+129+416
    Window Title: 'Untitled-1.0 (RGB, 1 layer) 420x300'; Application Name: 'The GIMP'; Class: 'Gimp'; Geometry: 580x406+512+83
    Window Title: 'Layers, Paths, Channels, Undo | Brushes, Patterns, Gradients'; Application Name: 'The GIMP'; Class: 'Gimp'; Geometry: 293x943+1321+24
    Window Title: 'The GIMP'; Application Name: 'The GIMP'; Class: 'Gimp'; Geometry: 272x640+124+81
    What works is, that all gimp windows except the main window (window_name the GIMP) are moved to my fourth workspace. The main window gets moved, only, when gimp is open and i execute devilspie, not vice versa. geometry and above doesnt work. It worked though, when I only had
    Code:
    (above)
    instead of
    Code:
    (begin
        (above)
        (geometry "273x323+5+693")
      )

  6. #76
    Join Date
    Sep 2005
    Location
    USA
    Beans
    777
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: HOWTO: Automating Gnome with Devil's Pie

    Quote Originally Posted by Mozork View Post
    Okay, new task for the devilspie-pros out there:
    I want THE Gimp to be a bit more automated, therefore I wrote some expressions, of which some work, and some don't

    ...
    That is kind of strange, and I'd like to do this too...

    A couple of things I noticed:

    • if you change the action to (maximize) instead of (set_workspace), it does perform the action on the tool window. So devilspie does manage to match the window.
    • Gimp's preferences seems to include window manager settings, so that may be interfering. I've tried disabling whatever settings are listed there, but devilspie still is not able to move the tool window to another workspace

  7. #77
    Join Date
    Dec 2006
    Location
    Liechtenstein
    Beans
    24
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: HOWTO: Automating Gnome with Devil's Pie

    Quote Originally Posted by _jason View Post
    • if you change the action to (maximize) instead of (set_workspace), it does perform the action on the tool window. So devilspie does manage to match the window.
    • Gimp's preferences seems to include window manager settings, so that may be interfering. I've tried disabling whatever settings are listed there, but devilspie still is not able to move the tool window to another workspace
    That would fit to my discovery, that once gimp is open, and you start devilspie, the gimp main window gets moved.
    Well, ich tried some other tweaks and found out, that when i just have the expression:
    Code:
    (begin
      (if
        (is (application_name) "The GIMP")
        (begin
          (set_workspace 4)
        )
      )
      (if
        (and
          (is (application_name) "The GIMP")
          (is (window_name) "The GIMP")
        )
        (above)
      )
    )
    all my Gimp windows are on Top, which means, that the second condition is true for all gimp windows. I've also found out, that my other expressions (except for the first and second one) from my previous post are not working at all... ^^
    So, why can't I select them by window_name, reps. why have they all exactly the same window_name? - window_roles could be something to work with, but unfortunately I have absolutely no idea, how to get these window_roles...

  8. #78
    Join Date
    Sep 2005
    Location
    USA
    Beans
    777
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: HOWTO: Automating Gnome with Devil's Pie

    Quote Originally Posted by Mozork View Post
    ... window_roles could be something to work with, but unfortunately I have absolutely no idea, how to get these window_roles...
    Code:
    (jrib@castelo:~)% xprop  | grep -i role                                    (9:15/1399)
    WM_WINDOW_ROLE(STRING) = "gimp-toolbox"

  9. #79
    Join Date
    Nov 2006
    Location
    Saudi Arabia
    Beans
    91
    Distro
    Ubuntu 6.10 Edgy

    Re: HOWTO: Automating Gnome with Devil's Pie

    Yeah, I couldn't get the GIMP to work properly either, I think it had the same problems that you guys are describing above. Anyways, somebody at the Devil's Pie wiki suggested this:
    I’ve managed to customize GIMP to move to another workspace this way:

    (or

    (matches (window_role) "^gimp.*$")
    (is (window_name) "The GIMP")

    )

    This matches the splash-screen, the toolbox, the main window and the opened image window. So you could first modify each window individually and then move them all to wherever you want.
    I havn't tried it, since I kind of lost interest. You guys might what to try it though.

  10. #80
    Join Date
    Dec 2006
    Location
    Liechtenstein
    Beans
    24
    Distro
    Ubuntu 7.04 Feisty Fawn

    Re: HOWTO: Automating Gnome with Devil's Pie

    Now we're getting somewhere...
    Code:
    (begin
      (if
        (is (application_name) "The GIMP")
        (begin
          (set_workspace 4)
        )
      )
      (if
        (is (window_role) "gimp-toolbox")
        (begin
          (above)
        )
      )
      (if 
        (is (window_role) "gimp-dock")
        (begin
          (above)
        )
      )
      (if
        (is (window_role) "gimp-image-window")
        (begin
          (geometry "1048x950+321+24")
        )
      )
      (if
        (is (window_role) "gimp-tip-of-the-day")
        (begin
          (above)
        )
      ) 
    )
    Works everything.
    But now, there is still the problem with addressing the different gimp-docks. And the one with the gimp-toolbox, well I'll keep on trying.

    €dit:
    Ok, I've altered my expressions upon kobewan's post. It looks somewhat nicer, but It hasn't really changed the main points:
    Code:
    (begin
      (if
        (or
          (matches (window_role) "^gimp.*$")
          (is (window_name) "The GIMP")
        )
        (begin
          (above)
        )
      )
      (if
        (is (window_role) "gimp-toolbox")
        (begin
          (geometry "311x664+0+0")
        )
      )
      (if
        (matches (window_name) "^*Navigation*$")
        (begin
          (geometry "306x323+5+693")
        )
      )
      (if
        (matches (window_name) "^*Layers, Paths*$")
        (begin
          (geometry "296x950+1379+24")
        )
      )
      (if
        (is (window_role) "gimp-image-window")
        (begin
          (geometry "1053x950+316+24")
          (below)
        )
      )
      (if
        (or
          (matches (window_role) "^gimp.*$")
          (is (window_name) "The GIMP")
        )
        (begin
          (set_workspace 4)
        )
      )
    )
    What works is:
    • All gimp windows are set to be on top.
    • The gimp-toolbar is resized upon my demanding.
    • The gimp-image-window is resized.
    • All gimp windows except for the gimp-toolbar are moved to workspace 4.
    What doesn't work is:
    • The gimp-toolbar remains in the workspace the gimp was opened.
    • The gimp-image-window is not set to be not on top anymore. (Dont know why...)
    • The both expressions with the window_names intended to address different gimp-docks don't work.
    Last edited by Mozork; February 25th, 2007 at 04:09 PM.

Page 8 of 9 FirstFirst ... 6789 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •