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

Stretch issue with a taller geometry ratio on niri wm #190

Open
BRS5672023 opened this issue Aug 15, 2024 · 8 comments
Open

Stretch issue with a taller geometry ratio on niri wm #190

BRS5672023 opened this issue Aug 15, 2024 · 8 comments

Comments

@BRS5672023
Copy link

BRS5672023 commented Aug 15, 2024

The font and border (and presumably all the elements else) stretches weirdly when I set the geometry with a taller ratio (shown by the following screenshot), and this issue happens only on niri wm but not on hyprland..

Maybe this issue is related to #165 (while seemingly I'm not having the scaling issue here).

For example, run tofi with tofi-drun --width=600 --height=800
Screenshot from 2024-08-15 22-39-43

The remaining contents within the tofi config file are

fuzzy-match=true
drun-launch=true

font-size=18
font="monospace bold"

background-color=#181818
outline-width=0
outline-color=#1a1a1a
border-width=4
border-color=#7cafc2
text-color=#b8b8b8
result-spacing=5
corner-radius=10
width=0

prompt-text="❯   "
prompt-color=#5291e2

selection-color=#ffffff
selection-background=#383c4a
selection-match-color=#ff0000
selection-background-padding=0,10
selection-background-corner-radius=5
@itshog
Copy link

itshog commented Aug 16, 2024

Can you try the patch in #189?

@BRS5672023
Copy link
Author

BRS5672023 commented Aug 16, 2024

Can you try the patch in #189?

Thx, your patch indeed fixes my problem, I missed the part setting anchor=center in my tofi config explicitly, which seems to be necessary?

@itshog
Copy link

itshog commented Aug 16, 2024

Thx, your patch indeed fixes my problem, I missed the part setting anchor=center in my tofi config explicitly, which seems to be necessary?

anchor=center is necessary only if you want tofi to appear in the center of the screen (but i believe center is the default value, so even if you don't specify it explicitly it should appear in the center). Other possible anchors are top-left, top, top-right, right, bottom-right, bottom, bottom-left, left, but the issue should be solved by the patch regardless of the chosen anchor

@itshog
Copy link

itshog commented Aug 16, 2024

@BRS5672023 Could you please try the patch with other anchor values? I'm almost sure that this issue is a duplicate of #165

@BRS5672023
Copy link
Author

@BRS5672023 Could you please try the patch with other anchor values? I'm almost sure that this issue is a duplicate of #165

All values work as intended, but if I comment out the anchor line in tofi config, then its position is at top-left and stretched abnormally.

@itshog
Copy link

itshog commented Aug 16, 2024

All values work as intended, but if I comment out the anchor line in tofi config, then its position is at top-left and stretched abnormally.

Probably there is something wrong in the patch or in some other part of the code responsible for setting the anchor, thank you! I'll try to update the patch and see what I can do

@itshog
Copy link

itshog commented Aug 16, 2024

@BRS5672023 I updated the patch, does it work as expected now?

@BRS5672023
Copy link
Author

@BRS5672023 I updated the patch, does it work as expected now?

Yes, it is fixed now, thanks for your patch.

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

2 participants