platformio / platformio-atom-ide-terminal

A terminal package for Atom, complete with themes, API and more for PlatformIO IDE
https://atom.io/packages/platformio-ide-terminal
MIT License
612 stars 162 forks source link

macOS: terminal font descenders cut off #640

Closed wagnerone closed 4 years ago

wagnerone commented 5 years ago

Steps to reproduce

  1. Click + to create a new terminal window
  2. ls -l /etc/ to fill the terminal screen
  3. resize terminal area by dragging divider bar or clicking "Fullscreen" button

Expected behavior: No descenders cut off

Actual behavior: Descenders cut off

Reproduces how often: I can always reproduce by resizing (either via dragging the separation bar or clicking the "Fullscreen" button. When I do either, the descenders are immediately cut off on the final line of existing screen content and on subsequent lines.

Versions

> atom --version
Atom    : 1.34.0
Electron: 2.0.16
Chrome  : 61.0.3163.100
Node    : 8.9.3
> apm --version
apm  2.1.3
npm  6.2.0
node 8.9.3 x64
atom 1.34.0
python 2.7.15
git 2.17.2

OS name and version: macOS Mojave 10.14.3 Platformio-ide-terminal version: 2.9.1 Font family: Menlo, 12 Theme: standard

Additional Information

Often times I see the font descenders cut off on the very bottom line of the terminal window. This has been happening for several revisions of both Atom and/or platformio-ide-terminal, but the below are my current versions.

mw-screen2019-01-22_08-57-48_am mw-screen2019-01-23_10-19-49_am

the-j0k3r commented 5 years ago

Solved by xterm instead, but no PR no fix ;)

the-j0k3r commented 5 years ago

platformio-atom-ide-terminal 2.9.0 uses node-pty-prebuilt instead unmaintained and outdated pty.js, so aside from platformio-atom-ide-terminal switching to xterm.js you can no longer compare previous platformio-atom-ide-terminal version to anything post 2.9.0.

It could be this is OS specific,I dont have macOS to test out scenarios though.

the-j0k3r commented 5 years ago

Thank you for reaching out with this bug report.

You are getting this reply because the issue template was not filled in its entirety, overwritten, or some portions were partially left out.

This issue template contains important information to be able to provide any kind of support, and will help us triage or reproduce the issue. Without reproduction no workaround or fix can normally be derived...

Copy and paste the template located at https://raw.githubusercontent.com/platformio/platformio-atom-ide-terminal/master/.github/ISSUE_TEMPLATE.md and fill in all fields. Logs / Errors / other information should be added at the bottom in the Notes portion of the issue template.

Tickets without this information may be closed and labeled invalid at our discretion.

Thank you for your understanding.

skibitsky commented 5 years ago

Same here

Description

It appears every time I am using platformio-ide-terminal in Atom when it has enough lines to reach the Atom's bottom line while updating/installing npm packages, so I have to restart the terminal.

screenshot 2019-02-16 at 15 32 56

Steps to reproduce

  1. Open Atom on macOS
  2. Open platformio-ide-terminal
  3. Run npm i big-package-name (I've just tested with npm i zos)
  4. See shit happenns

Expected behavior: No descenders cut off

Actual behavior: Descenders cut off

Reproduces how often: Hard to say. Every time installing/updating npm packages in my case.

Versions

macOS: 10.14.2 Atom : 1.34.0 Electron: 2.0.16 Chrome : 61.0.3163.100 Node : 8.9.3 platformio-ide-terminal version: 2.9.0 terminal theme: dracula

the-j0k3r commented 5 years ago

@skibitsky thank you for your me too report.

Could you also please fill in the remainder of the issue template pls?

skibitsky commented 5 years ago

@the-j0k3r done

wagnerone commented 5 years ago

I’ll fill out the template soon. My computer is in the shop for a few days being repaired.

wagnerone commented 5 years ago

Steps to reproduce

  1. Click + to create a new terminal window
  2. ls -l /etc/ to fill the terminal screen
  3. resize terminal area by dragging divider bar or clicking "Fullscreen" button

Expected behavior: No descenders cut off

Actual behavior: Descenders cut off

Reproduces how often: I can always reproduce by resizing (either via dragging the separation bar or clicking the "Fullscreen" button. When I do either, the descenders are immediately cut off on the final line of existing screen content and on subsequent lines.

Versions

> atom --version
Atom    : 1.34.0
Electron: 2.0.16
Chrome  : 61.0.3163.100
Node    : 8.9.3
> apm --version
apm  2.1.3
npm  6.2.0
node 8.9.3 x64
atom 1.34.0
python 2.7.15
git 2.17.2

OS name and version: macOS Mojave 10.14.3 Platformio-ide-terminal version: 2.9.1

Additional Information

the-j0k3r commented 5 years ago

I cant duplicate this in macOS Mojave 10.14.2

If anyone is using 3rd party Powerline like prompt modifiers turn them off and retest. In vanilla macOS all is well.

the-j0k3r commented 5 years ago

WIth the clear lack of response to my previous question, Ill be giving another week for persons above to reply with concise information regarding 3rd party powerline like prompts being in usage. After that time, this ticket will be closed until such time new relevant information is provided that will enable me to properly triage issue.

stklik commented 5 years ago

For what it's worth, I observe the same issue on macOS Mojave (10.14.4) :

image

I have not done a full investigation yet, but I'm happy to help if I can. Here's some info about my

$ atom --version
Atom    : 1.36.1
Electron: 2.0.18
Chrome  : 61.0.3163.100
Node    : 8.9.3

$ apm --version
apm  2.1.3
npm  6.2.0
node 8.9.3 x64
atom 1.36.1
python 2.7.10
git 2.20.1

$ apm list
...
Community Packages (28) <path/to/user>/.atom/packages
├── TabNine@0.1.5
├── atom-beautify@0.33.4
├── atom-ide-ui@0.13.0
├── autocomplete-python@1.14.0
├── autocomplete-swift@1.0.3
├── busy-signal@2.0.1
├── emmet@2.4.3
├── file-icons@2.1.32
├── graphviz-preview-plus@1.5.9
├── ide-python@1.4.1 (disabled)
├── intentions@1.1.5
├── language-docker@1.1.8
├── language-dot@1.7.0
├── language-latex@1.2.0
├── language-swift@0.5.0
├── latex@0.50.2
├── linter@2.3.0 (disabled)
├── linter-flake8@2.4.0
├── linter-tslint@1.10.22
├── linter-ui-default@1.7.1
├── markdown-mindmap@0.6.1
├── mypddl@1.0.0
├── pandoc@0.2.2
├── platformio-ide-terminal@2.9.1
├── split-diff@1.6.0
├── symbols-tree-view@0.14.0
├── todo-show@2.3.2
└── vim-mode-plus@1.36.0

Additional info: I have also iTerm2 installed on my system (Build 3.2.9).

Let me know if there's any more useful info I could provide.

the-j0k3r commented 5 years ago

@stklik Thank you for comming forth with that information.

Please test with default macOS terminal without any 3rd party Powerline like prompt modifiers. All vanilla please, Then if the issue remains we can be sure the issue is not caused by any external terminal addons.

Also be worth testing Atom without any addons except platformio-ide-terminal set to use the default terminal.

I dont see this issue and here is the proof.

generic

Vanilla Atom, no 3rd pty terminals or terminal addons

Works, descenders in full view, always.

Edit: also it occurs to me non default fonts may also interfere, though again I test with default vanilla everything.

wagnerone commented 5 years ago

@the-j0k3r Did you try how I can always reproduce it described in my response?

"Reproduces how often: I can always reproduce by resizing (either via dragging the separation bar or clicking the "Fullscreen" button. When I do either, the descenders are immediately cut off on the final line of existing screen content and on subsequent lines."

As far as a PowerLine prompt, I don't know what that is, so I presume I do not use anything. I have just a basic bashrc/profile I've built myself based on the stock OS files. I'm happy to test "with default macOS terminal" but I'm not clear how I would know if Im not or how to set it up to test if I am. You mean put all my bash config stuff out of the way and relog with just the /etc/bash config items?

the-j0k3r commented 5 years ago

. I'm happy to test "with default macOS terminal" but I'm not clear how I would know if Im not or how to set it up to test if I am.

I can always reproduce by resizing (either via dragging the separation bar or clicking the "Fullscreen" button.

I missed that part, doh! moment, even in op its described, my mistake,but still no dice. IDK if Im missing something, if I am let me know, share a gif also =) but theres no issue apparent as you can see below.

generic

I'm happy to test "with default macOS terminal" but I'm not clear how I would know if Im not or how to set it up to test if I am

No idea either, I setup macOS only to test issues like this... But you could try uninstalling it and try.

Thanks again for quick reply.

stklik commented 5 years ago

Right, here's my screencast. (sorry if bad quality, did it for the first time). As you will see, the from my hostname (nyx) the line skip happens exactly when I resize (~20 seconds in).

screencast

the-j0k3r commented 5 years ago

Cant see the descenders being cut off at all there, or line skip?

the-j0k3r commented 5 years ago

I cant seem reproduce this or see any issues reported with a clean macOS install without any 3rd party fonts or terminal addons like powerline. Any further videos provided by users, dont show any such issues.

So I must assume that users are costuming their terminal or using some font that breaks this.

I recommend that if you are using powerline or any 3rd party fonts to either use a better font or in case of powerline type addons, either remove them or report the issue to that project, since it works per default.

MLBurnham commented 5 years ago

I had this same issue on Ubuntu and it seems to be cause by an interaction with atom-ide-ui. With atom-ide-ui disabled the problem never occurs. With it enabled it will happen when resizing the window. If you disable atom-ide-ui after resizing the window, the problem seems to get worse rather than better.

the-j0k3r commented 5 years ago

@MLBurnham Thanks for that insight into the issue.

It is definitely some interaction between 3rd party something or other, though its hard to pinpoint because most ppl reporting dont provide that kind of detail with their reports, so its hard to pinpoint.

I believe using the modern xterm.js instead of the unmaintained term.js would make the terminal more robust and resistant to these interaction issues between 3rd parties and less buggy overall, and there's nothing I can do about that at this time, so its dependent on contributors to submit solutions.

Thanks again for your share.

the-j0k3r commented 4 years ago

Also here is a possible fix! Install CascadiaPL.ttf from https://github.com/microsoft/cascadia-code/releases it has native Powerline ligatures, this is a new free font by MS and its opensource and professionally done, this could be better than using fonts modified by enthusiasts, Please test.

You will also need to setup the terminal to use this CascadiaPL.ttf font, after which the issue should be gone.

However please notice that platformio-ide-terminal may also display other issues with Powerline type input modifiers mostly due to #426 so until there's xterm support nothing will improve in that front.

Any xterm additions are user contributed anyone can contribute via pr to this project or to my fork upstream at https://github.com/bus-stop/terminus which is now completely written in JavaScript.

Hope this helps.

the-j0k3r commented 4 years ago

no reply, closing