SUMMARY Suggestion, split the setting to define margins in 4 options (like css, top right bottom left). Even with monospaced fonts, "Align to center" on or off, I still get uneven margins, visually, between the 4 sides. That's expected behavior since the width and height of window can't always coincide with the remaining space, margin and line spacing. If I'm able to set them individually I would be able to have correct margins at least in the maximized view. STEPS TO REPRODUCE 1. Open Konsole 2. Set Margin and Line Spacing to 6px 3. Run a command that fills the screen with text 4. Try to keep all margins equal OBSERVED RESULT Margins are uneven. If that doesn't happen, change the window size or try a monospaced font. I could be wrong but I think the top margin is always bigger than the bottom no matter the margin settings. EXPECTED RESULT Equal margins in all 4 sides SOFTWARE/OS VERSIONS Linux/KDE Plasma: KDE Plasma Version: 5.18.5 KDE Frameworks Version: 5.71.0 Qt Version: 5.12.7
A screenshot would help us understand what you're seeing. Can you attach one?
Created attachment 130768 [details] 2
Created attachment 130769 [details] 3
Created attachment 130770 [details] 4
Created attachment 130771 [details] 5
Created attachment 130772 [details] 6
Created attachment 130773 [details] 7
I just took these screenshots in a live Kubuntu 20.04 virtual machine with default settings. The margins are not equal if you compare top/bottom with left/right. To better visualize them you can imagine that each monospaced character has a box around it, that's their real size. And maybe the margins are what's outside the sum of all of them? It's probably not like that in the code at all but I don't know how else to describe it.
for ((i=1; i<=9000; i++)); do echo -n "01"; done;
Thanks, that's helpful!
To me this is a WONTFIX. If you always center the "image", then it will jitter when resizing the window. You can change the margins (i.e. the left/top one), and make it half as wide as your available margin for a specific window size.
It's ok if it doesn't bother others but for me it looks really bad when both margins are not equal or you have dead space because there isn't room for an extra line. I can notice that even if it's just a single pixel. I don't know how other terminals solve this problem. I suggested splitting margin settings but there's probably a better way. E.g could you hide overflow top when scrolling down, and vice versa, so the text get cut but the margins look consistent? I'll understand if you need to WONTFIX, it's probably a hard problem to solve.
> I don't know how other terminals solve this problem Do those terminals resize the window smoothly or in steps? Do they have a configurable margin, or do they just distribute the remaining free space?
It looks like the "Align to center" option could resolve this issue, but enabling it doesn't make a difference here. Some more observations: The scrollbar is no longer visually separated from the terminal view, which adds to the uneven appearance. For vertical margins, the fonts themselves include margins at the top and at the bottom for ascenders/descenders or diacritics, and it depends on the selected font if they appear even or uneven. See e.g. The Kpfx image at http://www.myfirstfont.com/glossary.html; the K doesn't have even margins between the two bearing lines. > To better visualize them you can imagine that each monospaced character has a box around it, that's their real size. I suggest to select all characters with the mouse to see their actual cell boxes used for layout.
>Do those terminals resize the window smoothly or in steps? Do they have a configurable margin, or do they just distribute the remaining free space? I'm not qualified to answer these questions but I'll try. I installed and configured alacritty and when I resize the window can see the text adapting very quickly but there's still some lag. If I resize fast I can see the background. So in steps? While the margins still aren't perfect for 100% of window sizes and ratios, it feels more consistent. There are some extra settings https://github.com/alacritty/alacritty/blob/master/alacritty.yml#L32 Kitty has a lot of options but for some reason it's crashing when I press a key. https://sw.kovidgoyal.net/kitty/conf.html#window-layout window_resize_step_cells, window_resize_step_lines window_margin_width single_window_margin_width window_padding_width placement_strategy
(In reply to Christoph Feck from comment #14) > It looks like the "Align to center" option could resolve this issue, but > enabling it doesn't make a difference here. In the screenshots attached I tried with both on and off. > Some more observations: The scrollbar is no longer visually separated from > the terminal view, which adds to the uneven appearance. Alacritty doesn't show the scrollbar for me. That's a good observation. I see a border with my theme but in the screenshots I attached with the default theme it does look worse because of that. It could help if the scrollbar background was configurable but that's out of the subject maybe. > For vertical margins, the fonts themselves include margins at the top and at > the bottom for ascenders/descenders or diacritics, and it depends on the > selected font if they appear even or uneven. See e.g. The Kpfx image at > http://www.myfirstfont.com/glossary.html; the K doesn't have even margins > between the two bearing lines. > I suggest to select all characters with the mouse to see their actual cell > boxes used for layout. Oh so that's why the top margin looks bigger for me. Paying the price of the highest possible character I would guess.