4

In XFCE, for resizing windows, I have to put my mouse exactly on the window border, and it is sometimes hard.

I would like it to be easier, which means that the area for which the mouse is considered on the border should be be bigger.

How to do this? How to augment the sensitivity of window borders for resizing windows?

  • 1
    Easy alternative: When you right-click on the top bar of the window, there is a contect menu, showing the menu item to change the size of the window (it is greyed out when the window is maximzed). This way you can resize the window even if the right/bottom border are not visible. If for any reason the top bar of the window is not visible, you can right-click the Window button in the panel, which gives you the same context menu (you can even do that when the window is not visible, e.g. hidden behind another one) – ridgy Apr 27 '17 at 10:57

3 Answers3

0

I have found that certain window manager styles are difficult to land on the resize area with the mouse. My solution has been to use a different window manager style, located at Window Manager > Style (first tab). I recommend installing xfwm4-themes with the command sudo apt-get install xfwm4-themes to add more window manager styles. I personally like the styles Tyrex, Defcon-IV, and the Default-4.x ones.

I also use this script to make windows larger with just the keyboard. It uses xdotool. Use the arguments, -u, -r, -d, -l for up, right, down, left.

#!/bin/bash

window_id=$(xdotool getactivewindow)
width=$(xdotool getwindowgeometry "$window_id" | awk -F" |x" '/Geometry:/ { print $4 }')
height=$(xdotool getwindowgeometry "$window_id" | awk -F" |x" '/Geometry:/ { print $5 }')

w_move () {
# Window position
x=$(xwininfo -id "$window_id" | awk '/Absolute upper-left X:/ { print $4 }')
y=$(xwininfo -id "$window_id" | awk '/Absolute upper-left Y:/ { print $4 }')

# Subtract window decoration and panel offsets
x_offset=$(xwininfo -id "$window_id" | awk '/Relative upper-left X:/ { print $4 }')
x=$((x - x_offset))
y_offset=$(xwininfo -id "$window_id" | awk '/Relative upper-left Y:/ { print $4 }')
y=$((y - y_offset))
}

case "$1" in
    -u )
        w_move
        window_app=$(xdotool getwindowfocus getwindowname)
        if [[ "$window_app" = Terminal* ]]; then
            y=$((y - 19))
        else
            y=$((y - 30))
        fi              
        xdotool windowmove "$window_id" "$x" "$y"
        height=$((height + 30))
        ;;      
    -r )
        width=$((width + 30))
        ;;  
    -d )
        height=$((height + 30))
        ;;
    -l )
        w_move
        x=$((x - 30))
        xdotool windowmove "$window_id" "$x" "$y"
        width=$((width + 30))
        ;;
    * )
        echo "Use the arguments, -u, -r, -d, -l for up, right, down, left."
        ;;
esac

xdotool windowsize "$window_id" "$width" "$height"
jbrock
  • 1,141
0

The question was asked 6 years ago and it's still relevant and to me it has always been a decisive feature for keeping a theme. The easy solution is trying different themes until you get the one that suits your needs, keeping in mind that sometimes to improve one feature you might loose another... Here are the themes that I've been around in the last years just because they solve the problem of borders sensitiveness. From their own theme packages: Breeze, Numix and Greybird From the Xfwm4 themes: Daloa, Default, Kokodi and Moheli Themes. If someone knows of another theme, please comment so I can maybe add one more to my elected ones.

Ade_Oliv
  • 1
  • 1
-3

This works for me in Xubuntu 20.04 preserving your current theme, and without any coding.

I use a Numix theme modified by using Themix-project OOmox to change theme colors and certain other elements. After saving my oomox theme, I applied "borders" theme as per instructions. It preserved all theme elements but made the borders easy to grab.

Kusalananda
  • 333,661