Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Scale pinned column by factor relative to monitor scale #104

Closed
okt opened this issue Jan 3, 2025 · 4 comments
Closed

Comments

@okt
Copy link

okt commented Jan 3, 2025

Firstly, great plugin! I very much enjoy the productivity boost it provides.

I’ve been using hyprscroller for a while, and I often find myself pinning a column of windows like Firefox (for docs), manpages, or a few terminal processes to one side of my ultrawide monitor. However, I often need just a bit more space on the primary workspace, and resizing the pinned column sometimes triggers undesirable behaviors like web pages jumping into mobile mode or terminal output reflowing.

Proposal:
Provide a configuration or command to set a scale factor for the pinned column that is applied relative to the monitor’s default scale. For example, setting a scale value of 0.75 would cause all windows in that column to render at a smaller size, freeing extra space on the main portion of the screen.

Would this align with your usage of hyprscroller?

Are there any known technical limitations or side effects you can think of?

I’d love to hear thoughts on feasibility before diving into the C++ code. Let me know if this feature seems useful or if there are particular design considerations I should keep in mind. Thanks!

@dawsers
Copy link
Owner

dawsers commented Jan 3, 2025

If I understand correctly what you mean, you would basically need a per window scale of its content. Each window could have its content scaled on demand, and the compositor would compose them together. It is not possible to do this through a plugin without rewriting the compositor.

The way overview and jump work is by scaling all the content. I hook into some Hyprland internal functions and trick the compositor to show me all the workspace by applying a global scale. As long as the scale is global, the hack works (for now). I only need to hook into a few functions and use the monitor scale to create the effect. But if I wanted to do it per window (or for certain columns, like you propose), I would need to do it in Hyprland's code. There is only so much you can do with hooks; you cannot change private functions, for example.

Your idea is cool, but it would need to be implemented in Hyprland itself. The most I can do is have variable zoom levels (I have a prototype that does that), but each level applies to the whole workspace; it is not possible to selectively apply it to only a few windows.

@chaorace
Copy link

Potentially related: hyprwm/Hyprland#3861
I don't think we should count on this happening anytime soon. Even though my original issue remains open, the maintainer seems to deliberately choose the "not planned" label whenever closing duplicates of it.

@dawsers
Copy link
Owner

dawsers commented Jan 20, 2025

Yes, that is the right place to ask for this. As I explained, it is not something that can be provided in a plugin, it needs to be in the core. I only left the issue open to remind me of it in case I decided to hack a bit into Hyprland.

@dawsers dawsers closed this as completed Jan 22, 2025
@dawsers
Copy link
Owner

dawsers commented Feb 28, 2025

I added a PR in Hyprland for this feature:

hyprwm/Hyprland#9428

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

No branches or pull requests

3 participants