macvim-dev / macvim

Vim - the text editor - for macOS
https://macvim.org
Vim License
7.55k stars 683 forks source link

Black square between tabline and scrollbar #1295

Open adinklotz opened 2 years ago

adinklotz commented 2 years ago

Steps to reproduce

  1. Run a config-less MacVim: mvim -g --clean
  2. Set a non-black color scheme that lets us see what's happening: :colorscheme slate
  3. Disable the GUI tabline - this only applies to the text tabline: :set guioptions-=e
  4. Create a new tab so the tabline shows: :tabnew
Screen Shot 2022-09-21 at 9 58 47 PM

Note the black space that appears at the top-right corner

Expected behaviour

Any of the following:

  1. The tabline extends all the way to the right edge
  2. The scroll bar extends all the way up to the title bar
  3. That gap is left empty but matches the colorscheme background color (what Windows gvim does)

Version of Vim and architecture

Vim 9.0, macOS version arm64, Included patches 1-472

Environment

Operating system: macOS Monterey version 12.6 (21G115) Terminal: iTerm2 (doesn't really apply, I've only seen issue in macvim GUI) $TERM: xterm-256color Shell: zsh 5.8.1

How MacVim was installed

Homebrew cask

Logs and stack traces

No response

Vim configuration where issue is reproducable

Reproducable on almost-clean vim config (with a couple commands as described)

Issue has been tested with given configuration

Issue has been tested with no configuration

Other conditions

eirnym commented 2 years ago

Thank you for an issue.

I took it as a natural tread-off for a pixel-by-pixel resisability (as the opposite to character-by character)

In MacVim I personally don't use tabline (and Vim tabs in general) as I prefer macOS-style ones if I use tabs.

As far as I see what's happening, it matches normal background style, so I'd propose to match this square to tabline background style rather than general one.

adinklotz commented 2 years ago

Yeah I don't really use Vim tabs in MacVim, or in general, but I really like the way vim-airline hijacks the tabline to show buffers, which does require using the Vim text tabline.

For reference, here's how the native text tabline looks in Windows's Gvim: Screenshot 2022-09-22 100145 (of course pretty ugly in that default color scheme, but a better way to handle it than the black square IMO)

Obviously this is a very minor issue, it just disproportionately bugs me to have MacVim messing up the look of my artisanally crafted vimrc haha

ychin commented 2 years ago

This is a bug. I'll try to fix it next release. Incidentally there is a new overlay scroll bar feature coming "soon" which would hopefully mean you don't have to use the old school scroll bars anymore.

And there is also a pull request to revamp of the MacVim tabs that I need to merge but I imagine that won't apply to you if you are going to turn GUI tabs off anyway.