4

I tend to use an external monitor with my laptop on a stand, taking the laptop with me to classes and such. Because of this, it'd be really cool to have the touchpad and keyboard on the laptop only control that one screen and do it separately from my normal inputs with an external mouse and keyboard. Obviously, this would require some configuration and would need to be opt-in, but I think it'd be useful for use with your "discord monitor", or one filling a similar role. What do y'all think about this idea and how would you like it to be/think it would have to be implemented?

top 1 comments
sorted by: hot top controversial new old
[-] ptz@dubvee.org 2 points 1 month ago

You can use xinput to restrict input devices to certain displays. I've got a touchscreen that, by default, think the touch area is the combined desktop span instead of just the external one. So I just lock the touch input devices to that.

Use xinput list and find the device IDs (id=XXX) for the mouse/keyboard you want to map to your secondary display.

Then use xrandr --query to list the monitor names (eDP-1, DP-1, HDMI-1, etc)

Finally, map the devices to that output as such: xinput map-to-output {ID} {DISPLAY}

e.g. if my keyboard input id is 9, and my mouse id is 10, and I want them to go to my external display witch is DP-1:

xinput map-to-output 9 DP-1 and xinput map-to-output 10 DP-1

The devices IDs are dynamic, and these are not persistent, so you'd probably want to script it to find them and automatically do the mapping.

this post was submitted on 30 Oct 2024
4 points (100.0% liked)

Ask Lemmy

27154 readers
3030 users here now

A Fediverse community for open-ended, thought provoking questions

Please don't post about current US Politics. If you need to do this, try !politicaldiscussion@lemmy.world


Rules: (interactive)


1) Be nice and; have funDoxxing, trolling, sealioning, racism, and toxicity are not welcomed in AskLemmy. Remember what your mother said: if you can't say something nice, don't say anything at all. In addition, the site-wide Lemmy.world terms of service also apply here. Please familiarize yourself with them


2) All posts must end with a '?'This is sort of like Jeopardy. Please phrase all post titles in the form of a proper question ending with ?


3) No spamPlease do not flood the community with nonsense. Actual suspected spammers will be banned on site. No astroturfing.


4) NSFW is okay, within reasonJust remember to tag posts with either a content warning or a [NSFW] tag. Overtly sexual posts are not allowed, please direct them to either !asklemmyafterdark@lemmy.world or !asklemmynsfw@lemmynsfw.com. NSFW comments should be restricted to posts tagged [NSFW].


5) This is not a support community.
It is not a place for 'how do I?', type questions. If you have any questions regarding the site itself or would like to report a community, please direct them to Lemmy.world Support or email info@lemmy.world. For other questions check our partnered communities list, or use the search function.


Reminder: The terms of service apply here too.

Partnered Communities:

Tech Support

No Stupid Questions

You Should Know

Reddit

Jokes

Ask Ouija


Logo design credit goes to: tubbadu


founded 2 years ago
MODERATORS