facebookarchive / atom-ide-ui

A collection of user interfaces for Atom IDE.
http://ide.atom.io
Other
936 stars 79 forks source link

Editor datatip does not use ui theme font size (but buffer data tip does) #23

Open mehcode opened 7 years ago

mehcode commented 7 years ago

Description

Editor datatip does not use ui theme font size (but buffer data tip does). I have a 2k monitor on linux and set my ui theme font size to 16 (using one-dark).

When hovering on the gutter, the datatip has the correct font size.

When hovering in the editor, the datatip has the atom default font size and does not respect the ui theme font size.

screenshot from 2017-09-13 11-19-59

Also notice that I'm able to spawn the same datatip from both the editor and the gutter at the same time by just moving my cursor.

Expected Behavior

The datatip should use the ui theme font size.

Actual Behavior

The datatip does not use the ui theme font size.

Versions

$ atom-beta --version
Atom    : 1.21.0-beta0
Electron: 1.6.9
Chrome  : 56.0.2924.87
Node    : 7.4.0

Additional Details

$ apm ls --installed
Community Packages (7) /home/mehcode/.atom/packages
├── atom-ide-ui@0.3.1
├── file-icons@2.1.11
├── highlight-selected@0.13.1
├── ide-rust@0.1.0
├── language-rust@0.4.12
├── minimap@4.29.6
└── minimap-highlight-selected@4.6.1
Arcanemagus commented 7 years ago

Looks like this is because the gutter ones are being appended to the parent of the workspace element here: https://github.com/facebook-atom/atom-ide-ui/blob/754553a6403e4b068da7a843b84687696b68156a/modules/atom-ide-ui/pkg/atom-ide-diagnostics-ui/lib/gutter.js#L281 (This ends up being the base <body>.)

dwSun commented 6 years ago

Will it be possible to have a separate setting for the datatip font size? Or, where I can find the config file and modify it?

The words are too small to read. 2018-03-19 22-21-35

damieng commented 6 years ago

@dwSun You can change the font size by overriding it in your stylesheet, e.g.

.datatip-marked-container {
  font-size:1.5em;
}
dwSun commented 6 years ago

@damieng Thanks, this almost fix the problem. It looks that the datatip is rending the pydoc inside python source as markdown. I will start a new issue at ide-python.

2018-03-20 13-54-46

damieng commented 6 years ago

There are only two formats supported by the protocol - plain text and markdown. Given that linspace formats correct it might be the language server doing the wrong thing for the example. If you enable LSP debugging with atom.config.set('core.debugLSP', true) in the devtools window then restart you should see the hover response message there when you hover and you can see what the body of it looks like - you can then paste it here.

dwSun commented 6 years ago

@damieng, started 2 issues. As the owner of ide-python said:

I'm afraid this requires some upstream fixes in either the python language server or the protocol specifications.

This problem involves too much things than what I have expected early.