Skip to content
This repository has been archived by the owner on Apr 24, 2020. It is now read-only.

Wrong cut off in Konsole #971

Closed
mr-ubik opened this issue Aug 27, 2018 · 26 comments
Closed

Wrong cut off in Konsole #971

mr-ubik opened this issue Aug 27, 2018 · 26 comments

Comments

@mr-ubik
Copy link

mr-ubik commented Aug 27, 2018

Nope
Terminal Emulator: Konsole
Framework: Oh-My-Zsh
Powelevel9k: cloned from master (571a859)
POWERLEVEL9K_MODE='nerdfont-complete'
Font: Hack Nerd Font (installed via the AUR packages)

It appears that #854 is not working for me.

@mr-ubik
Copy link
Author

mr-ubik commented Aug 27, 2018

UPDATE: after setting LANG=n_US.UTF-8 in locale.conf to fix #639 this is the prompt that I am getting

meh2

If I use the Nerd Font Monoglyph variant, the output is correct, but the icons are smaller and harder to read.

I am beginning to suspect that it's all due to the and not powerlevel9k, but I will wait for someone more knowledgeable to drop by.

meh3

@NielsonJ
Copy link

NielsonJ commented Aug 28, 2018

I have this same issue but only since Konsole 18.08.0 dropped on me.

Before that, this fix used to work: #231-comment-349022409

@harsh8398
Copy link

Yes I am having the same issue currently. It was working fine when I installed it. Probably its because of the new konsole update.

@abdomh
Copy link

abdomh commented Oct 8, 2018

I can confirm that by downgrading konsole to version 18.04.3 i was able to get it to work, but for version 18.07.80-1 and up the icons get cut off

@bhilburn
Copy link
Member

bhilburn commented Oct 9, 2018

Okay, it sounds like this is indeed a bug in konsole. It would be good if someone (ideally a konsole user) filed a bug on Konsole's bug tracker so they are aware and hopefully push a fix in a future update.

@mr-ubik @NielsonJ @harsh8398 @abdelrahmangit - Thanks so much for commenting and participating, here, and thanks @mr-ubik for opening this issue to begin with! I'm going to close this out for now since it's an external bug, but if there are any updates please share them here, or if you believe there is an issue in P9k we can resolve please re-open!

@bhilburn bhilburn closed this as completed Oct 9, 2018
@beojan
Copy link

beojan commented Oct 24, 2018

I think the problem is adding whitespace was a workaround, not a fix.
The bug is here: https://bugs.kde.org/show_bug.cgi?id=390650
As you can see, it's a NOTABUG because the double-width characters in question are in the PUA.

@braydie
Copy link

braydie commented Oct 24, 2018

So presumably that means that the work around we had before relied on a bug in konsole..? Where should the fix to make this work sit?

@beojan
Copy link

beojan commented Oct 24, 2018

Either we can figure out why xfce terminal (for instance) displays things correctly, and persuade Konsole to do the same (though it might turn out that there's a bug in XFCE terminal), or awesome-terminal-fonts can move the glyphs into the Han section of Unicode (which would break things for anyone who actually wanted to use CJK characters).

@beojan
Copy link

beojan commented Oct 24, 2018

Or Option 3, the double width characters can be implemented using two codepoints and a ligature (since ligatures do work in Konsole).

@VladimirMikulic
Copy link

SOLUTION: I installed Tilix terminal and icons are displayed properly. Personally I am glad that I discovered Tilix, it is even better than Konsole! Maybe some of you already knew for Tilix, but I wanted to share my solution. Hopefully it will help someone. Anyways, thanks @dritter for your response :)

@beojan
Copy link

beojan commented Apr 23, 2019

The Konsole bug is fixed, but powerlevel9k needs to be changed to ensure there are no ANSI escape codes between the character and the space (so the escape codes need to go after the space).

@VladimirMikulic
Copy link

Yeah, I noticed that change a few days ago. Konsole works fine now, good job.

@beojan
Copy link

beojan commented Apr 23, 2019

Actually, I'm still seeing an issue with the swap use segment.

@VladimirMikulic
Copy link

Provide a screenshot.

@beojan
Copy link

beojan commented Apr 23, 2019

image

@VladimirMikulic
Copy link

VladimirMikulic commented Apr 23, 2019

Now, I have the same issue as you. I've just upgraded from Kubuntu 18.10 to 19.04 and now Konsole doesn't work anymore. Just switch to Tilix, you won't regret it. No more headaches with Konsole.

@beojan
Copy link

beojan commented Apr 23, 2019

That's because Kubuntu 19.04 comes with Konsole 18.12. Konsole 19.04 largely fixed the problems, except with the swap segment.

@VladimirMikulic
Copy link

Then, I guess you'll have to wait for the next update to fix the problem with the swap segment 😂

@dritter
Copy link
Member

dritter commented Apr 23, 2019

@beojan Good to hear that the bug is fixed in Konsole. Not sure though, if we should add a whitespace after every icon by default. That would fix this out of the box for Konsole users, but display a big gap for other Terminal Emulators.
But it is possible right now to add a whitespace to every icon via configuration. E.g. for the Swap segments icon, just set P9K_SWAP_ICON=$'\uF464 ' in your ~/.zshrc, if you use P9Ks next branch, and NerdFonts.

@beojan
Copy link

beojan commented Apr 23, 2019 via email

@beojan
Copy link

beojan commented Apr 27, 2019

@dritter I "fixed" this by adding a space after each variable in line 123 of function/icons.zsh.

This would need to be in a conditional if the fix is to be distributed (maybe a P9K_SPACE_AFTER_ICONS option?)

@beojan
Copy link

beojan commented Apr 27, 2019

@dritter In fact, it turns out that with commit ad93217, the swap segment works fine. At some point since then, a change was introduced which allows escape code between the icon and the space.

@beojan
Copy link

beojan commented Apr 27, 2019

And solved. It's 4300902 that causes the problem.

@Afzal7
Copy link

Afzal7 commented May 15, 2019

Did a clean install of kubuntu 19.04 and installed oh-my-zsh and powerlevel9k with nerd fonts. But its not working right :(

terminal

@RaitaroH
Copy link

@Afzal7 I use the MONO variant of the awesome fonts. Go to EDIT > Appeaance > Choose font > Enable Show all fonts > Choose the mono variant of what you want. Now it will work.

image

BUT I also have this weird thing where, IF konsole is started from zsh with oh-my-zsh and powerlevel9k installed the font is not rendered properly. IF started from bash inside zsh then is fine. Seems like #1258

@Afzal7
Copy link

Afzal7 commented May 19, 2019

@RaitaroH Thanks for the reply. Did what you said. It worked but i have to say it does not look perfect. But it will work. Thanks.
Screenshot_20190519_170839

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests