mirror of
				https://github.com/labwc/labwc.git
				synced 2025-11-03 09:01:51 -05:00 
			
		
		
		
	config: add configuration for tablet tool motion sensitivity
This commit is contained in:
		
							parent
							
								
									96701f1e27
								
							
						
					
					
						commit
						bcd5746a32
					
				
					 2 changed files with 5 additions and 0 deletions
				
			
		| 
						 | 
					@ -105,6 +105,7 @@ struct rcxml {
 | 
				
			||||||
	} tablet;
 | 
						} tablet;
 | 
				
			||||||
	struct tablet_tool_config {
 | 
						struct tablet_tool_config {
 | 
				
			||||||
		enum motion motion;
 | 
							enum motion motion;
 | 
				
			||||||
 | 
							double relative_motion_sensitivity;
 | 
				
			||||||
	} tablet_tool;
 | 
						} tablet_tool;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* libinput */
 | 
						/* libinput */
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1063,6 +1063,9 @@ entry(xmlNode *node, char *nodename, char *content)
 | 
				
			||||||
		}
 | 
							}
 | 
				
			||||||
	} else if (!strcasecmp(nodename, "motion.tabletTool")) {
 | 
						} else if (!strcasecmp(nodename, "motion.tabletTool")) {
 | 
				
			||||||
		rc.tablet_tool.motion = tablet_parse_motion(content);
 | 
							rc.tablet_tool.motion = tablet_parse_motion(content);
 | 
				
			||||||
 | 
						} else if (!strcasecmp(nodename, "relativeMotionSensitivity.tabletTool")) {
 | 
				
			||||||
 | 
							rc.tablet_tool.relative_motion_sensitivity =
 | 
				
			||||||
 | 
								tablet_get_dbl_if_positive(content, "relativeMotionSensitivity");
 | 
				
			||||||
	} else if (!strcasecmp(nodename, "ignoreButtonReleasePeriod.menu")) {
 | 
						} else if (!strcasecmp(nodename, "ignoreButtonReleasePeriod.menu")) {
 | 
				
			||||||
		rc.menu_ignore_button_release_period = atoi(content);
 | 
							rc.menu_ignore_button_release_period = atoi(content);
 | 
				
			||||||
	} else if (!strcasecmp(nodename, "width.magnifier")) {
 | 
						} else if (!strcasecmp(nodename, "width.magnifier")) {
 | 
				
			||||||
| 
						 | 
					@ -1261,6 +1264,7 @@ rcxml_init(void)
 | 
				
			||||||
	rc.tablet.box = (struct wlr_fbox){0};
 | 
						rc.tablet.box = (struct wlr_fbox){0};
 | 
				
			||||||
	tablet_load_default_button_mappings();
 | 
						tablet_load_default_button_mappings();
 | 
				
			||||||
	rc.tablet_tool.motion = LAB_TABLET_MOTION_ABSOLUTE;
 | 
						rc.tablet_tool.motion = LAB_TABLET_MOTION_ABSOLUTE;
 | 
				
			||||||
 | 
						rc.tablet_tool.relative_motion_sensitivity = 1.0;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	rc.repeat_rate = 25;
 | 
						rc.repeat_rate = 25;
 | 
				
			||||||
	rc.repeat_delay = 600;
 | 
						rc.repeat_delay = 600;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue