|
| 1 | +/* |
| 2 | + Autoproperties. The default template and simple course of autopropping |
| 3 | + to help you add your own autoproperties. See the documentation for |
| 4 | + more keywords and the rest of what is possible through this file. |
| 5 | + |
| 6 | + First, it's good to note that you can't just make up the property |
| 7 | + string, you need to use a program called 'xprop' to show it. Please |
| 8 | + conduct the documentation. |
| 9 | + |
| 10 | + Another good tip is to make sure you have an ApplyOn entry. The |
| 11 | + autoproperties you define won't do any good if you don't tell pekwm |
| 12 | + when to apply them! |
| 13 | + |
| 14 | + Third tip. You can't match a window with more than one property. The |
| 15 | + first one that matches will be used, the rest ignored (see the gimp |
| 16 | + example). |
| 17 | + |
| 18 | + Note that the default entries are commented out, don't comment out your |
| 19 | + own autoproperties. :) |
| 20 | +*/ |
| 21 | + |
| 22 | +Require { |
| 23 | + Templates = "True" |
| 24 | +} |
| 25 | + |
| 26 | +/* |
| 27 | + Group terminal applications |
| 28 | + */ |
| 29 | +# Property = "(term|rxvt),(erm|xvt)" { |
| 30 | +# ApplyOn = "New" |
| 31 | +# Group = "term" { |
| 32 | +# Size = "5" |
| 33 | +# FocusedFirst = "True" |
| 34 | +# Raise = "True" |
| 35 | +# } |
| 36 | +# } |
| 37 | + |
| 38 | +/* |
| 39 | + Remove decor of customize toolbar window of mozilla firefox. |
| 40 | + */ |
| 41 | +Property = "^(gecko|Gecko|firefox-bin),^Firefox-bin,,^Customize Toolbar\$" { |
| 42 | + ApplyOn = "Start New TransientOnly" |
| 43 | + Border = "False" |
| 44 | + Titlebar = "False" |
| 45 | +} |
| 46 | + |
| 47 | +/* |
| 48 | + Auto-group up to 10 mozilla download windows to group you call "moz-dl", |
| 49 | + using a WM_CLASS and specifying the the download window using the |
| 50 | + begining of its title. Make the windows go to the top-left corner of |
| 51 | + your workspace and place them under other windows. Do this when new |
| 52 | + windows show up, also to so called transient windows. |
| 53 | +*/ |
| 54 | +# Property = "^mozilla-bin,^Mozilla-bin,,^Saving" { |
| 55 | +# ApplyOn = "New Transient" |
| 56 | +# Group = "moz-dl" { Size = "10" } |
| 57 | +# FrameGeometry = "+0+0" |
| 58 | +# Layer = "Below" |
| 59 | +# } |
| 60 | + |
| 61 | + |
| 62 | +/* |
| 63 | + Group together up to two windows that have a WM_CLASS that matches the |
| 64 | + property. Start these windows on workspace two. |
| 65 | +*/ |
| 66 | +# Property = "^Mozilla,^navigator:browser" { |
| 67 | +# ApplyOn = "Start New Workspace" |
| 68 | +# Workspace = "2" |
| 69 | +# } |
| 70 | + |
| 71 | + |
| 72 | +/* |
| 73 | + Group together an infinite number of windows that match the property. |
| 74 | + When new windows are opened to this group, never make them the active |
| 75 | + window of the group, but open them in the background. Make these |
| 76 | + autoproperties apply on every pekwm start or when a new window is opened. |
| 77 | +*/ |
| 78 | +# Property = "^dillo,^Dillo" { |
| 79 | +# ApplyOn = "Start New" |
| 80 | +# Group = "dillo" { Size = "0"; Behind = "True" } |
| 81 | +# } |
| 82 | + |
| 83 | + |
| 84 | +/* |
| 85 | + Put property matching windows under other windows and make the window |
| 86 | + appear on every workspace. Do not show matching windows on the pekwm |
| 87 | + goto menus, do not include them in frame switching (mod1+tab) and do |
| 88 | + not let other windows snap to them. Do this on pekwm start or when new |
| 89 | + window is opened, also include transient windows (in the example, |
| 90 | + xmms playlist and equalizer are transients). |
| 91 | +*/ |
| 92 | +# Property = ".*,^xmms" { |
| 93 | +# ApplyOn = "Start New Transient" |
| 94 | +# Layer = "Desktop" |
| 95 | +# Sticky = "True" |
| 96 | +# Skip = "Menus FocusToggle Snap" |
| 97 | +# } |
| 98 | + |
| 99 | + |
| 100 | +/* |
| 101 | + Remove Gimp windows from the menus, only show the main toolbox window. |
| 102 | + Use the WM_WINDOW_ROLE to tell the difference between gimp windows. |
| 103 | + |
| 104 | + First make sure the toolbox window doesn't get confused with the rest |
| 105 | + of the windows. This just tells pekwm to ignore any matches for the |
| 106 | + toolbox later on. Without this, the toolbox would match with "the rest |
| 107 | + of the windows" and get ignored from the pekwm menus! We don't want that. |
| 108 | +*/ |
| 109 | +# Property = "^gimp,^Gimp,gimp-toolbox" { |
| 110 | +# ApplyOn = "Start New" |
| 111 | +# } |
| 112 | +/* |
| 113 | + The Crop dialog always gets in the way, put it in the corner but place |
| 114 | + it above other windows anyways. Don't show the window in pekwm menus. |
| 115 | +*/ |
| 116 | +# Property = "^gimp,^Gimp,gimp-crop-tool" { |
| 117 | +# ApplyOn = "Start New" |
| 118 | +# Layer = "OnTop" |
| 119 | +# FrameGeometry = "+0+0" |
| 120 | +# Skip = "Menus" |
| 121 | +# } |
| 122 | +/* |
| 123 | + The rest of the gimp windows should not show in pekwm menus eather. |
| 124 | +*/ |
| 125 | +# Property = ".gimp,^Gimp" { |
| 126 | +# ApplyOn = "Start New" |
| 127 | +# Skip = "Menus"; |
| 128 | +# } |
| 129 | + |
| 130 | + |
| 131 | +/* |
| 132 | + This should start making sense to you by now. |
| 133 | +*/ |
| 134 | +# Property = "^gkrellm,^Gkrellm" { |
| 135 | +# ApplyOn = "Start New" |
| 136 | +# Sticky = "True" |
| 137 | +# Skip = "Menus FocusToggle" |
| 138 | +# Layer = "Desktop" |
| 139 | +# } |
| 140 | + |
| 141 | + |
| 142 | +/* |
| 143 | + Some useful standard application xclock xload and xbiff. This should |
| 144 | + be fairly clear to you. In addition to what you've allready learned, |
| 145 | + we make the windows appear without titlebars and borders. We are also |
| 146 | + using the geometry in all its glory, defining the windows size in |
| 147 | + addition to its position. |
| 148 | +*/ |
| 149 | +# Property = "^xclock,^XClock" { |
| 150 | +# ApplyOn = "Start New" |
| 151 | +# ClientGeometry = "120x137+0-137" |
| 152 | +# Border = "False"; Titlebar = "False" |
| 153 | +# Sticky = "True" |
| 154 | +# Layer = "Desktop" |
| 155 | +# Skip = "Menus FocusToggle Snap" |
| 156 | +# } |
| 157 | +# |
| 158 | +# Property = "^xload,^XLoad" { |
| 159 | +# ApplyOn = "Start New" |
| 160 | +# ClientGeometry = "560x137+120-137" |
| 161 | +# Border = "False"; Titlebar = "False" |
| 162 | +# Sticky = "True" |
| 163 | +# Layer = "Desktop" |
| 164 | +# Skip = "Menus FocusToggle Snap" |
| 165 | +# } |
| 166 | +# |
| 167 | +# Property = "^xbiff,^XBiff" { |
| 168 | +# ApplyOn = "Start New" |
| 169 | +# ClientGeometry = "120x137-120-137" |
| 170 | +# Border = "False"; Titlebar = "False" |
| 171 | +# Sticky = "True" |
| 172 | +# Layer = "Desktop" |
| 173 | +# Skip = "Menus FocusToggle Snap" |
| 174 | +# } |
| 175 | + |
| 176 | + |
| 177 | +// End of autoproperties. ------------------------- |
| 178 | + |
| 179 | +TypeRules { |
| 180 | + INCLUDE = "$_PEKWM_ETC_PATH/autoproperties_typerules" |
| 181 | +} |
| 182 | + |
| 183 | +/* |
| 184 | + Next, we do some siple window title rewriting. |
| 185 | + To make it simple, you can automatically make some windows get their |
| 186 | + title edited. Cut out an annoying piece, add text, replace text. |
| 187 | + This all happens in it's own section "TitleRules {}". |
| 188 | + |
| 189 | + I don't like the way dillo uses its titlebar, it says "Dillo: webpage". |
| 190 | + I want that "Dillo:" part to not show in the beginning, instead I want |
| 191 | + to make it show as "webpage - dillo". |
| 192 | + |
| 193 | + Then again, the "webpage - Mozilla Firefox" is too long for my taste. |
| 194 | + I shorten it in the second titlerule. And I'll place the shortened text |
| 195 | + in the beginning of the title just as a show how. |
| 196 | +*/ |
| 197 | +# TitleRules { |
| 198 | +# Property = "^dillo,^Dillo" { |
| 199 | +# Rule = "/Dillo: (.*)/\\1 - dillo/" |
| 200 | +# } |
| 201 | +# Property = "^firefox-bin,^Firefox-bin" { |
| 202 | +# Rule = "/(.*) - Mozilla Firefox/MF: \\1/" |
| 203 | +# } |
| 204 | +# } |
| 205 | + |
| 206 | + |
| 207 | +// End of titlerules. ----------------------------- |
| 208 | + |
| 209 | + |
| 210 | +/* |
| 211 | + Then for some harbour ordering done in it's own "Harbour {}" section. |
| 212 | + This is simple really, but you might want to check the documentation on |
| 213 | + how the positions work. |
| 214 | + |
| 215 | + Obpager is allways the last dockapp, the cpuload application is the |
| 216 | + first, and wmnd will get placed in the centre. |
| 217 | +*/ |
| 218 | +# Harbour { |
| 219 | +# Property = "^obpager,^obpager" { |
| 220 | +# Position = "-1" |
| 221 | +# } |
| 222 | +# Property = ".*,.*cpuload" { |
| 223 | +# Position = "1" |
| 224 | +# } |
| 225 | +# Property = ".*,^wmnd" { |
| 226 | +# Position = "0" |
| 227 | +# } |
| 228 | +# } |
| 229 | + |
| 230 | + |
| 231 | +// End of harbour order rules. -------------------- |
| 232 | + |
| 233 | + |
| 234 | +/* |
| 235 | + Last, if you have a theme that supports it, or you have hacked one up |
| 236 | + yourself, you can use the "DecorRules {}" section to make windows show |
| 237 | + up with independent decorations. |
| 238 | + |
| 239 | + Here we tell our terminal windows to use the special TERM decoration |
| 240 | + section found from your theme. Note that this _needs_ a theme that |
| 241 | + supports it. |
| 242 | +*/ |
| 243 | +# DecorRules { |
| 244 | +# Property = "^term,^xterm" { |
| 245 | +# Decor = "TERM" |
| 246 | +# } |
| 247 | +# } |
| 248 | + |
0 commit comments