Define a custom shortcut for Compiz Window Manager
Ralf Mardorf
silver.bullet at zoho.com
Fri Apr 22 09:30:27 UTC 2016
On Fri, 22 Apr 2016 11:02:24 +0200, Ralf Mardorf wrote:
>On Fri, 22 Apr 2016 10:34:09 +0200, Ralf Mardorf wrote:
>>either
>>
>>window="0x$(printf '%x\n' $(xdotool getactivewindow))"
>>
>>or, since there's no need to use hex
>>
>>window="$(xdotool getactivewindow)"
>
>Wrong, the OP needs hex to get the original size for the math:
>
>$ window="0x0$(printf '%x' $(xdotool getactivewindow))"
> ^
> ^ The hex lenght is tricky for grep
>
>$ window="$(printf '%x' $(xdotool getactivewindow))"
>
>works without "0x", but for the other command "0x" is needed, but
>not necessarily "0x0".
IOW use printf or something else, a loop, to fill the hex value with
that much 0, until 8 numbers are reached, or don't use the same $window
variable for grep and the wmctrl commands.
More information about the ubuntu-users
mailing list