domtronn / spaceline-all-the-icons.el

A Spaceline Mode Line theme using All The Icons for Emacs
MIT License
235 stars 25 forks source link

Separator position and height #41

Closed jwintz closed 6 years ago

jwintz commented 7 years ago

Hello,

I've played with custom faces in order to get a coloured space line with doom-theme-one, but for one reason, the right-most hand separator is not in the good place is its height is a little bit smaller than expected.

Any clue ?

screen shot 2017-05-22 at 20 25 55
haaspors commented 7 years ago

Try showing the clock. I think this is because you are not showing the clock/time segment and/or battery status. There is an right to inactive before this, maybe a bug? @domtronn

domtronn commented 7 years ago

@jwintz @ieei Sorry for the late reply, and yep, @ieei is right, you need to show something there.

Spaceline breaks down the segments into blocks, and it auto alternates the colours of those blocks - If a block doesn't have any content or is nil, then it'll skip over that changing the colours of the other blocks, which for my purpose is quite annoying!

See, the separators are just characters with a specific background and foreground and at the moment they're not dynamic at all, and kind of depend on the same order.

I could maybe fix this by forcing the segment to always have content, or try playing around with the :skip-alternate property (which I thought I was using)... I'll investigate and get back to you.

side note...

There's also a bit of a regression/improvement with one of the newer versions of Spaceline 😅 It now hides blocks based on the width of the screen and there's no way to turn that off. What this means is you'll get blocks disappear and separators that transition to the wrong colours (see screenshot)

screen shot 2017-05-30 at 09 26 30

I'm looking into a way to improve this hopefully!

jwintz commented 7 years ago

Oh! I can see you're using my --with-natural-title-bar patch on emacs-plus ! Quite honoured ;-)

As for the separators, I agree, something has to be displayed on the right most hand side.

However, following a previous discussion, the clock may only be visible when it makes sense (at least for me), when emacs is fullscreen.

With no clock displayed, the HUD segment should be referred to as the last one and then, be drawn correctly.

jwintz commented 7 years ago

Hello,

I'm reopening this issue, as it makes me feel that on my config, all space line items like buffer name, project name, linked file, cursor position and fullscreen icon are part of the same segments (c.f.) the screenshot.

On the other hand, they are separate segments on README image of spaceline-all-the-icons.

It is related to my config ?

The same applies to vc-current-branch, fly check issues and vc-diffs.

As the space line has become responsive it would be great if any of these items belonged to on single statement ...

domtronn commented 7 years ago

Hey @jwintz, Good news is, it's not your config! I've been looking into this for a long time and unfortunately it's not really possible...

The way that I define separators ( so that they work cross platform without sRGB issues ) means that they're treated as individual segments of their own and are hardcoded with the colour transitions between the segments. This has to happen, otherwise the colours transitions don't work correctly.

This means that with the "responsiveness" of the spaceline you'll always have issues with the colours when you hide segments. Personally I think the responsiveness is a bad thing as it will always hide information and you quite often get massive gaps left over.

In theory, being able to define priorities on the segments makes sense but I've not been able to get it working very well 😞

I'm not feeling super motivated to fix or investigate this at the moment as it feels like a huge regression... As such, I'd recommend adding the following config

 (setq spaceline-responsive nil))

If the responsiveness is something you really want, I'd welcome any more information or PRs 🙂 👍

jwintz commented 7 years ago

Hey @domtronn, here is for more information. I have followed your advice, by disabling the responsiveness, and also, left the clock icon displayed even though not fullscreen, but that does not change the problem with the separators.

screen shot 2017-07-25 at 10 46 53

However, it answers one of my previous questions, I admit that segments are actually divided, when I played with custom set faces, (like the white palette of your screenshot for spaceline-highlight-face, I have to find a palette that suites doom-theme-one, knowing that with solaire-mode it changes the modeline background wrt to wether the buffer is editable or not).

I'll try and update package to see if newer versions fix it.

PS: Should I try to propose a PR, can you point me to the place where separator icons are computed ?