When resizing a window whose WM_NORMAL_HINTS specify an explicit size increment, xfwm4 tries to provide a visual feedback on the window's size in rows and columns, computed based on the window's base size, the indicated horizontal and vertical increments, and the current pixel size.
For example, when a window's size is 200x100 pixels, and the window specifies a horizontal increment of 10 and a vertical increment of 10, and a base size of 0x0, xfwm4 computes the window's size as 20 columns by 10 rows and shows a small "20x10" label in the middle of the window. This label gets updated, each time the window's size gets dragged (in increments of 10 pixels in each direction).
However, a window can be resizable only in one dimension. For example, a window may specify both a minimum and a maximum height of 100 pixels, but some horizontal range, ranging from a minimum to a maximum value. This sets a fixed height that cannot be adjusted, but an adjustable width.
In this case, xfwm4 shows a rather confusing label, claiming that this window's size is "20x0", "21x0", "22x0", etc...
Here's a small test program that creates a window of a fixed height, but which can be resized horizontally, across a modest range. Using the window's right border the window's width is adjustable, but with xfwm4 showing this confusing label.
Compile and link with -lxcb -lxcb-icccm:
int main ()
xcb_connection_t *connection = xcb_connect (NULL, NULL);
const xcb_setup_t *setup = xcb_get_setup (connection);
xcb_screen_iterator_t iter = xcb_setup_roots_iterator (setup);
xcb_screen_t *screen = iter.data;
xcb_window_t window = xcb_generate_id (connection);
0, NULL );
static const char wm_normal_hints="WM_NORMAL_HINTS";
xcb_map_window (connection, window);
memset(&hints, 0, sizeof(hints));
** Minimum size 20x150, maximum size 250x150.
** The window's height is fixed at 150 pixels.
xcb_icccm_size_hints_set_min_size(&hints, 20, 150);
xcb_icccm_size_hints_set_max_size(&hints, 250, 150);
/* Base size is same as minimum size */
xcb_icccm_size_hints_set_base_size(&hints, 20, 150);
** We can scroll by 10 pixels horizontally
** Tried setting vertical scrolling increment to either 0 or 1,
** makes no difference.
xcb_icccm_size_hints_set_resize_inc(&hints, 10, 1);
-- GitLab Migration Automatic Message --
This bug has been migrated to xfce.org's GitLab instance and has been closed from further activity.
You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.xfce.org/xfce/xfwm4/-/issues/308.
Please create an account or use an existing account on one of our supported OAuth providers.
If you want to fork to submit patches and merge requests please continue reading here: https://docs.xfce.org/contribute/dev/git/start#gitlab_forks_and_merge_requests
Also feel free to reach out to us on the mailing list https://mail.xfce.org/mailman/listinfo/xfce4-dev