Skip to content

Conversation

@Esscraye
Copy link

Description

This pull request adds the ability to configure the Sidepad position (Left or Right), improves multi-monitor support, and enhances focus management for a smoother workflow.

Changes

  • Improved
  • Bug Fixes
  • Feature
  • Documentation
  • Other

Context

  • Positioning: Users may prefer the sidepad on the right side of the screen. Previously, it was hardcoded to the left.
  • Multi-monitor: Using the sidepad on secondary monitors with different resolutions caused positioning issues because calculations were not relative to the specific monitor's coordinates.
  • Focus: Focus management was manual, requiring users to click or switch focus after opening/closing the sidepad.
  • Keybindings: The directional keybindings needed to adapt to the position (e.g. moving "out" of the screen should hide it, regardless of the side).

How Has This Been Tested?

  • Tested on Arch Linux/Based Distro (with my main screen in 1080p and the second in 1440p).
  • Tested on Fedora Linux/Based Distro.
  • Tested on openSuse.

(Cochez la case correspondant à votre distribution)

Checklist

Please ensure your pull request meets the following requirements:

  • My code follows the style guidelines of this project.
  • I have performed a self-review of my code.
  • I have commented on my code, particularly in hard-to-understand areas.
  • My changes do not introduce new warnings.
  • I have added tests that prove my fix is effective or that my feature works.
  • I have made corresponding changes to the documentation
  • New and existing unit tests pass locally with my changes.

Screenshots

image image

Related Issues

Fixes #1261

Additional Notes

Key Features:

  1. Configurable Position: Added sidepad-position (default: left).
  2. Smart Keybindings: The sidepad.sh script now intelligently handles --move-left and --move-right arguments. If the sidepad is on the right, the logic is inverted so that moving towards the edge always hides it, and moving towards the center opens it.
  3. Focus Restoration: The script now saves the previously focused window address to /tmp/sidepad-prev-focus when opening, and restores focus to that window when closing.
  4. Multi-monitor Fix: Position calculations now use the specific x, y, width, and height of the monitor where the sidepad is located, fixing issues on mixed-resolution setups.

…tem and fix when it's on a second screen that has different width
Copilot AI review requested due to automatic review settings December 28, 2025 11:26
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request adds configurable positioning for the sidepad feature, allowing users to choose between left or right side placement. It also improves multi-monitor support by using monitor-relative coordinates and implements automatic focus management.

Key changes:

  • Added --position parameter to configure sidepad placement (left/right)
  • Implemented focus saving/restoration when hiding/showing the sidepad
  • Fixed multi-monitor positioning by using monitor-specific X/Y coordinates

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 7 comments.

File Description
dotfiles/.config/sidepad/sidepad Core script updated with position-aware calculations, monitor-relative coordinates, and focus management
dotfiles/.config/ml4w/settings/sidepad-position New configuration file storing default position ("left")
dotfiles/.config/ml4w/scripts/sidepad.sh Wrapper script updated to load and pass position configuration to the core script

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Esscraye Esscraye changed the title feat: add possibility to have sidepad on the right, improve focus sys… feat: update Sidepad (focus, right position...) Jan 1, 2026
@mylinuxforwork
Copy link
Owner

Thanks for this PR. The launch of 2.9.9.5 is planned already for this weekend. I will test it for 2.9.9.6

@mylinuxforwork mylinuxforwork self-assigned this Jan 2, 2026
@Esscraye
Copy link
Author

Esscraye commented Jan 3, 2026

Yes sure, you tell me if you want me to modify something :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Sidepad opening from the right ?

2 participants