-/* $OpenBSD: mouse.c,v 1.21 2023/07/02 21:44:04 bru Exp $ */
+/* $OpenBSD: mouse.c,v 1.22 2024/10/05 13:27:16 chrisz Exp $ */
/* $NetBSD: mouse.c,v 1.3 1999/11/15 13:47:30 ad Exp $ */
/*-
/* touchpad-specific options: */
{ "tp.tapping", &cfg_tapping, FMT_CFG, FLG_NORDBACK },
{ "tp.mtbuttons", &cfg_mtbuttons, FMT_CFG, FLG_NORDBACK },
- { "tp.scaling", &cfg_scaling, FMT_CFG, FLG_NORDBACK },
+ { "tp.scaling", &cfg_scaling, FMT_CFG, FLG_NORDBACK | FLG_WRONLY },
{ "tp.swapsides", &cfg_swapsides, FMT_CFG, FLG_NORDBACK },
{ "tp.disable", &cfg_disable, FMT_CFG, FLG_NORDBACK },
{ "tp.edges", &cfg_edges, FMT_CFG, FLG_NORDBACK },
{ "tp.param", &cfg_param, FMT_CFG, FLG_WRONLY },
- /* Add an alias. This field is valid for all wsmouse devices. */
+ /* Add aliases. These fields are valid for all wsmouse devices. */
{ "param", &cfg_param, FMT_CFG, FLG_WRONLY },
+ { "scaling", &cfg_scaling, FMT_CFG, FLG_NORDBACK },
{ NULL }
};
for (f = mouse_field_tab; f->name != NULL; f++)
if (f->format == FMT_CFG) {
if (f->valp != &cfg_param
+ && f->valp != &cfg_scaling
&& f->valp != &cfg_revscroll)
f->flags |= FLG_DEAD;
else
-/* $OpenBSD: mousecfg.c,v 1.11 2024/09/25 19:56:33 bru Exp $ */
+/* $OpenBSD: mousecfg.c,v 1.12 2024/10/05 13:27:16 chrisz Exp $ */
/*
* Copyright (c) 2017 Ulf Brosziewski
if (field == &cfg_scaling) {
value = get_value(field, WSMOUSECFG_DX_SCALE);
+ value = value == 0 ? 4096 : value;
f = (float) value / 4096;
printf("%.3f", f);
return;
-.\" $OpenBSD: wsmouse.4,v 1.23 2023/07/02 21:44:04 bru Exp $
+.\" $OpenBSD: wsmouse.4,v 1.24 2024/10/05 13:27:16 chrisz Exp $
.\" $NetBSD: wsmouse.4,v 1.3 1999/12/06 14:52:08 augustss Exp $
.\"
.\" Copyright (c) 2018 Ulf Brosziewski <bru@openbsd.org>
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.Dd $Mdocdate: July 2 2023 $
+.Dd $Mdocdate: October 5 2024 $
.Dt WSMOUSE 4
.Os
.Sh NAME
is omitted, commands apply to
.Pa /dev/wsmouse0 .
.Bl -tag -width Ds
+.It Cm mouse.reverse_scrolling
+Reverse direction of scrolling.
+.It Cm mouse.scaling
+The value is a scale coefficient that is applied to the relative
+coordinates.
+It determines the base speed of the pointer.
.It Cm mouse.tp.tapping
Contacts on the touchpad that are immediately released again can
be mapped to mouse button clicks.
This feature is supported for some clickpads.
If enabled, two-finger clicks - with the fingers side by side - generate
left-button events, and three-finger clicks generate middle-button events.
-.It Cm mouse.tp.scaling
-The value is a scale coefficient that is applied to the relative
-coordinates.
-It determines the base speed of the pointer.
.It Cm mouse.tp.swapsides
If this parameter has a non-zero value, the order of software
button areas is inverted.