<div dir="ltr"><font face="courier new, monospace">Hi,<br><br>I use xfce on a multi-monitor system as part of an apparatus for displaying visual stimuli to experimental subjects (one monitor is for the subject; the other for the experimenter). Since the window cycling "alt tab" window occludes the display on all monitors, it can interfere with a running experiment. I've implemented a simple patch (below) for configuring which monitor receives the modal window via an Xfconf property: "cycle_desktop_number". A value of -1 enables the current behavior (all monitors). </font><span style="font-family:'courier new',monospace">Hopefully someone else will find this useful too.</span><div>
<font face="courier new, monospace"><br>Thanks for making a great desktop environment,<br>/joeyo<br><br>diff --git a/xfwm4-4.10.0_orig/src/settings.c b/xfwm4-4.10.0/src/settings.c<br>index 607bb7b..729897c 100644<br>--- a/xfwm4-4.10.0_orig/src/settings.c<br>
+++ b/xfwm4-4.10.0/src/settings.c<br>@@ -679,6 +679,7 @@ loadSettings (ScreenInfo *screen_info)<br> {"cycle_hidden", NULL, G_TYPE_BOOLEAN, TRUE},<br> {"cycle_minimum", NULL, G_TYPE_BOOLEAN, TRUE},<br>
{"cycle_workspaces", NULL, G_TYPE_BOOLEAN, TRUE},<br>+ {"cycle_desktop_number", NULL, G_TYPE_INT, TRUE},<br> {"double_click_time", NULL, G_TYPE_INT, TRUE},<br> {"double_click_distance", NULL, G_TYPE_INT, TRUE},<br>
{"double_click_action", NULL, G_TYPE_STRING, TRUE},<br>@@ -769,6 +770,8 @@ loadSettings (ScreenInfo *screen_info)<br> getBoolValue ("cycle_hidden", rc);<br> screen_info->params->cycle_workspaces =<br>
getBoolValue ("cycle_workspaces", rc);<br>+ screen_info->params->cycle_desktop_number =<br>+ getIntValue ("cycle_desktop_number", rc);<br> screen_info->params->focus_hint =<br>
getBoolValue ("focus_hint", rc);<br> screen_info->params->focus_new =<br>@@ -1183,6 +1186,11 @@ cb_xfwm4_channel_property_changed(XfconfChannel *channel, const gchar *property_<br> {<br>
screen_info->params->placement_ratio = CLAMP (g_value_get_int(value), 0, 100);<br> }<br>+ else if (!strcmp (name, "cycle_desktop_number"))<br>+ {<br>
+ screen_info->params->cycle_desktop_number = CLAMP (g_value_get_int(value), -1, 10);<br>+ }<br>+<br> else if ((!strcmp (name, "button_offset"))<br> || (!strcmp (name, "button_spacing"))<br>
|| (!strcmp (name, "double_click_time"))<br>diff --git a/xfwm4-4.10.0_orig/src/settings.h b/xfwm4-4.10.0/src/settings.h<br>index be01b6b..e51f585 100644<br>--- a/xfwm4-4.10.0_orig/src/settings.h<br>
+++ b/xfwm4-4.10.0/src/settings.h<br>@@ -205,6 +205,7 @@ struct _XfwmParams<br> gboolean cycle_hidden;<br> gboolean cycle_minimum;<br> gboolean cycle_workspaces;<br>+ int cycle_desktop_number;<br> gboolean focus_hint;<br>
gboolean focus_new;<br> gboolean full_width_title;<br>diff --git a/xfwm4-4.10.0_orig/src/tabwin.c b/xfwm4-4.10.0/src/tabwin.c<br>index c130418..db6f3a3 100644<br>--- a/xfwm4-4.10.0_orig/src/tabwin.c<br>+++ b/xfwm4-4.10.0/src/tabwin.c<br>
@@ -479,6 +479,7 @@ tabwinCreate (GList **client_list, GList *selected, gboolean display_workspace)<br> Client *c;<br> Tabwin *tabwin;<br> int num_monitors, i;<br>+ int cycle_desktop_number;<br> <br> g_return_val_if_fail (selected, NULL);<br>
g_return_val_if_fail (client_list, NULL);<br>@@ -493,12 +494,16 @@ tabwinCreate (GList **client_list, GList *selected, gboolean display_workspace)<br> tabwin->selected = selected;<br> tabwin->tabwin_list = NULL;<br>
num_monitors = myScreenGetNumMonitors (screen_info);<br>+ cycle_desktop_number = screen_info->params->cycle_desktop_number;<br> for (i = 0; i < num_monitors; i++)<br> {<br>- gint monitor_index;<br>
+ if (cycle_desktop_number == -1 || cycle_desktop_number == i)<br>+ {<br>+ gint monitor_index;<br> <br>- monitor_index = myScreenGetMonitorIndex(screen_info, i);<br>- tabwin->tabwin_list = g_list_append (tabwin->tabwin_list, tabwinCreateWidget (tabwin, screen_info, monitor_index));<br>
+ monitor_index = myScreenGetMonitorIndex(screen_info, i);<br>+ tabwin->tabwin_list = g_list_append (tabwin->tabwin_list, tabwinCreateWidget (tabwin, screen_info, monitor_index));<br>+ }<br>
}<br> <br> return tabwin;</font></div></div>