特殊:Badtitle/NS100:Devilspie
文章出处: |
{{#if: | {{{2}}} | https://help.ubuntu.com/community/Devilspie }} |
点击翻译: |
English {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/af | • {{#if: UbuntuHelp:Devilspie|Afrikaans| [[::Devilspie/af|Afrikaans]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ar | • {{#if: UbuntuHelp:Devilspie|العربية| [[::Devilspie/ar|العربية]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/az | • {{#if: UbuntuHelp:Devilspie|azərbaycanca| [[::Devilspie/az|azərbaycanca]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/bcc | • {{#if: UbuntuHelp:Devilspie|جهلسری بلوچی| [[::Devilspie/bcc|جهلسری بلوچی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/bg | • {{#if: UbuntuHelp:Devilspie|български| [[::Devilspie/bg|български]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/br | • {{#if: UbuntuHelp:Devilspie|brezhoneg| [[::Devilspie/br|brezhoneg]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ca | • {{#if: UbuntuHelp:Devilspie|català| [[::Devilspie/ca|català]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/cs | • {{#if: UbuntuHelp:Devilspie|čeština| [[::Devilspie/cs|čeština]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/de | • {{#if: UbuntuHelp:Devilspie|Deutsch| [[::Devilspie/de|Deutsch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/el | • {{#if: UbuntuHelp:Devilspie|Ελληνικά| [[::Devilspie/el|Ελληνικά]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/es | • {{#if: UbuntuHelp:Devilspie|español| [[::Devilspie/es|español]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/fa | • {{#if: UbuntuHelp:Devilspie|فارسی| [[::Devilspie/fa|فارسی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/fi | • {{#if: UbuntuHelp:Devilspie|suomi| [[::Devilspie/fi|suomi]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/fr | • {{#if: UbuntuHelp:Devilspie|français| [[::Devilspie/fr|français]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/gu | • {{#if: UbuntuHelp:Devilspie|ગુજરાતી| [[::Devilspie/gu|ગુજરાતી]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/he | • {{#if: UbuntuHelp:Devilspie|עברית| [[::Devilspie/he|עברית]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/hu | • {{#if: UbuntuHelp:Devilspie|magyar| [[::Devilspie/hu|magyar]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/id | • {{#if: UbuntuHelp:Devilspie|Bahasa Indonesia| [[::Devilspie/id|Bahasa Indonesia]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/it | • {{#if: UbuntuHelp:Devilspie|italiano| [[::Devilspie/it|italiano]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ja | • {{#if: UbuntuHelp:Devilspie|日本語| [[::Devilspie/ja|日本語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ko | • {{#if: UbuntuHelp:Devilspie|한국어| [[::Devilspie/ko|한국어]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ksh | • {{#if: UbuntuHelp:Devilspie|Ripoarisch| [[::Devilspie/ksh|Ripoarisch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/mr | • {{#if: UbuntuHelp:Devilspie|मराठी| [[::Devilspie/mr|मराठी]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ms | • {{#if: UbuntuHelp:Devilspie|Bahasa Melayu| [[::Devilspie/ms|Bahasa Melayu]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/nl | • {{#if: UbuntuHelp:Devilspie|Nederlands| [[::Devilspie/nl|Nederlands]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/no | • {{#if: UbuntuHelp:Devilspie|norsk| [[::Devilspie/no|norsk]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/oc | • {{#if: UbuntuHelp:Devilspie|occitan| [[::Devilspie/oc|occitan]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/pl | • {{#if: UbuntuHelp:Devilspie|polski| [[::Devilspie/pl|polski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/pt | • {{#if: UbuntuHelp:Devilspie|português| [[::Devilspie/pt|português]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ro | • {{#if: UbuntuHelp:Devilspie|română| [[::Devilspie/ro|română]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/ru | • {{#if: UbuntuHelp:Devilspie|русский| [[::Devilspie/ru|русский]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/si | • {{#if: UbuntuHelp:Devilspie|සිංහල| [[::Devilspie/si|සිංහල]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/sq | • {{#if: UbuntuHelp:Devilspie|shqip| [[::Devilspie/sq|shqip]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/sr | • {{#if: UbuntuHelp:Devilspie|српски / srpski| [[::Devilspie/sr|српски / srpski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/sv | • {{#if: UbuntuHelp:Devilspie|svenska| [[::Devilspie/sv|svenska]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/th | • {{#if: UbuntuHelp:Devilspie|ไทย| [[::Devilspie/th|ไทย]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/tr | • {{#if: UbuntuHelp:Devilspie|Türkçe| [[::Devilspie/tr|Türkçe]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/vi | • {{#if: UbuntuHelp:Devilspie|Tiếng Việt| [[::Devilspie/vi|Tiếng Việt]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/yue | • {{#if: UbuntuHelp:Devilspie|粵語| [[::Devilspie/yue|粵語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/zh | • {{#if: UbuntuHelp:Devilspie|中文| [[::Devilspie/zh|中文]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/zh-hans | • {{#if: UbuntuHelp:Devilspie|中文(简体)| [[::Devilspie/zh-hans|中文(简体)]]}}|}} {{#ifexist: {{#if: UbuntuHelp:Devilspie | UbuntuHelp:Devilspie | {{#if: | :}}Devilspie}}/zh-hant | • {{#if: UbuntuHelp:Devilspie|中文(繁體)| [[::Devilspie/zh-hant|中文(繁體)]]}}|}} |
{{#ifeq:UbuntuHelp:Devilspie|:Devilspie|请不要直接编辑翻译本页,本页将定期与来源同步。}} |
{{#ifexist: :Devilspie/zh | | {{#ifexist: Devilspie/zh | | {{#ifeq: {{#titleparts:Devilspie|1|-1|}} | zh | | }} }} }} {{#ifeq: {{#titleparts:Devilspie|1|-1|}} | zh | | }}
What is devilspie?
devilspie is a non-gui utility that lets you make applications start in specified workplaces, in specified sizes and placements, minimized or maximized and much more based on simple config files. The homepage can be found here
How can I get it?
Install the devilspie package from the Universe repository.
How do I set it up?
- devilspie is configured with s-expressions stored in files ending with ".ds".
- Syntax is not difficult and is much more effective than it was in versions previous to 0.13, which used .xml files.
- For details, see:
- README, which should be placed in the directory where you unpacked the source (see above)
How do I use it?
- You can start Devil's pie with
devilspie
in gnome-terminal.
- It will read all the s-expressions stored in these two directories:
- $HOME/.devilspie/ which should be /home/<YourUserName>/.devilspie on Ubuntu
- $SYSCONFDIR/devilspie which should be /etc/devilspie on Ubuntu
- $HOME/.devilspie/ which should be /home/<YourUserName>/.devilspie on Ubuntu
The former will apply just when you start devilspie, the latter will apply to all users.
- You can use several options:
-d
or--debug
for debuging purposes, when run in terminal, it will print some useful information.
Note: this is the same as running Devil's Pie with an s-expression like this: (debug)
-a
or--apply-to-existing
should apply devilspie also to existing windows. However, it seems that it applies regardless this option.devilspie <file.ds>
ordevilspie <file1.ds> <file2.ds>
etc will explicitly specify which config files should be used.- After setting it up, you will probably want to run it on start up, so that every window you open will open the way you want it to. For further info as to how to do that, read AddingProgramToSessionStartup
- If you were to experience freezes down after adding devilspie to your startup programs with a low number (such as 30 or 50), try to higher it up so that devilspie starts as the last application. You may want to start it with
-a
option that applies the rules to already existing windows then. However, it may not be necessary.
Examples
Background for this setup: A dual-screen workspace where the smaller (laptop) screen is used solely for "communications" (IRC and IM windows). The goal is to get three windows (xchat, Pidgin buddy list and Pidgin chat window) into pre-set locations wasting as little screen estate as possible.
+--------+------------------------+ | Pidgin | | | Buddy | Pidgin | | List | Conversation | | | | | +------------------------+ | | | | | Xchat | | | | | | | +--------+------------------------+
pidgin.ds
Buddy list and conversation window are undecorated (no titles or borders), moved and resized. Buddy list is also removed from task list (so it won't show up in Window list). Note: Even with 'undecorate' the conversation window seems to have a some border, this is the reason for some additional pixels there...
(if (is (application_name) "Pidgin") (begin (if (is (window_role) "buddy_list") (begin (undecorate) (skip_tasklist) (geometry "199x767+0+0") ) ) (if (is (window_role) "conversation") (begin (undecorate) (geometry "822x400+201+0") ) ) ) )
xchat.ds
Xchat is undecorated (no titles or borders), moved and resized. Xchat main window does not have a window_role defined, but fortunately the other windows (like Preferences or Network List) do, so the empty match seems to work.
(and (is (application_name) "xchat") (is (window_role) "") (begin (undecorate) (geometry "823x363+200+404") ) )
How can I improve this wiki page?
Simply add any useful stuff! Especially the section about setting up should be improved so that it more then just linking somewhere else, also some examples would be greatly appreciated. Also feel free to correct anything wrong.
- I am not sure if devilspie reads files stored in /etc/devilspie/. It seems so, because other people say so, but when I checked, it did not work for me. Could someone please check it, correct it and then delete this note?