LnL7 / nix-darwin

nix modules for darwin
MIT License
2.82k stars 431 forks source link

feat(trackpad): add additional trackpad and gesture support #1053

Open dustypomerleau opened 4 weeks ago

dustypomerleau commented 4 weeks ago

This PR adds additional trackpad and gesture support.

To system.defaults.trackpad it adds:

ActuateDetents
DragLock
ForceSuppressed
TrackpadCornerSecondaryClick
TrackpadFourFingerHorizSwipeGesture
TrackpadFourFingerPinchGesture
TrackpadFourFingerVertSwipeGesture
TrackpadMomentumScroll
TrackpadPinch
TrackpadRotate
TrackpadThreeFingerHorizSwipeGesture
TrackpadThreeFingerTapGesture
TrackpadThreeFingerVertSwipeGesture
TrackpadTwoFingerDoubleTapGesture
TrackpadTwoFingerFromRightEdgeSwipeGesture

and to system.defaults.dock it adds:

showAppExposeGestureEnabled
showDesktopGestureEnabled
showLaunchpadGestureEnabled
showMissionControlGestureEnabled

A few questions:

  1. I have tested locally - am I meant to also add these settings to tests/system-defaults-write.nix?
  2. There is an inconsistency in the way that we represent defaults write commands with only 2 options. defaults read outputs these as -int (0 or 1), even if the user sets them via -bool. In this repo, there is a mix of representing them as types.bool and types.enum [ 0 1 ]. Does the project have a preference? Should we make them all the same?
  3. I have a question about formatting, but thought it best to separate that into its own issue (#1054 ).