devilspie, 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.
To install devilspie you can use Ubuntu Software Center or run the following command in terminal:
sudo apt-get install devilspie
You can start in terminal devilspie with:
devilspie
Now we are going to configure devilspie to lock gnome-terminal size:
Create a new directory to store your new devilspie-related configuration file:
mkdir ~/.devilspie
Create a new custom configuration file; for example:
gedit ~/.devilspie/gnome-terminal.ds
Paste in the following configuration code to your new file:
(if (is (application_name) "Terminal")
(begin
(undecorate)
(geometry "730x450")
(center)
)
)
(begin
(undecorate)
(geometry "730x450")
(center)
)
)
There are some more examples:
Example 1
(if
(is (application_name) "firefox-bin")
(begin
(set_workspace 2)
(maximize)
)
)
(is (application_name) "firefox-bin")
(begin
(set_workspace 2)
(maximize)
)
)
Example 2
(if
(and
(is (application_name) "gaim")
(is (window_name) "Buddy List")
)
(begin
(pin)
(geometry "340x630+4+150")
)
)
(and
(is (application_name) "gaim")
(is (window_name) "Buddy List")
)
(begin
(pin)
(geometry "340x630+4+150")
)
)
Example 3
(if
(matches (application_name) "^Skype")
(begin
(geometry "300x600")
(center)
(above)
(skip_pager)
(skip_tasklist)
)
)
(matches (application_name) "^Skype")
(begin
(geometry "300x600")
(center)
(above)
(skip_pager)
(skip_tasklist)
)
)
Example 4
(if
(and
(is (application_name) "gaim")
(not (is (window_name) "Buddy List"))
(not (contains (window_name) "#"))
)
(geometry "+0+313")
)
(and
(is (application_name) "gaim")
(not (is (window_name) "Buddy List"))
(not (contains (window_name) "#"))
)
(geometry "+0+313")
)
Example 5
(undecorate)
Combine two rules into one file:
(begin
(if
(is (application_name) "firefox-bin")
(begin
(set_workspace 2)
(maximize)
)
)
(if
(and
(is (application_name) "gaim")
(not (is (window_name) "Buddy List"))
(not (contains (window_name) "#"))
)
(geometry "+0+313")
)
)
Combine two rules into one file:
(begin
(if
(is (application_name) "firefox-bin")
(begin
(set_workspace 2)
(maximize)
)
)
(if
(and
(is (application_name) "gaim")
(not (is (window_name) "Buddy List"))
(not (contains (window_name) "#"))
)
(geometry "+0+313")
)
)