sublimehq / sublime_text

Issue tracker for Sublime Text
https://www.sublimetext.com
807 stars 39 forks source link

Inline Diffs add huge blank blocks to view and minimap #4747

Open deathaxe opened 3 years ago

deathaxe commented 3 years ago

Description

Something is causing inline diffs to be followed by huge blank space. It doesn't happen in safe mode and I already ruled out GitGutter, color schemes, themes by disabling them and font settings and hardware_accelleration by commenting user settings out. Also removed mdpopups and LSP temporarily, which are known to interact with phantoms.

I can't reproduce in SAFE MODE.

I wonder what could break this behavior, though, nor wouldn't I expect any plugin or theme to break it this way. Maybe a malicious phantom css?

It seems the larger the diff is the larger the blank space after.

EDIT: The culprit turns out to be wrap_width together with wrap_width_style : min. Can reproduce it in SAFE MODE.

Steps to reproduce

  1. Start Sublime Text in SAFE MODE
  2. Change settings
    "wrap_width": 100,
    "wrap_width_style": "min",
  3. Open a (git tracked) file
  4. Do some modifications in one line
  5. Display inline diff for a larger modification

Expected behavior

No blank space being added.

Actual behavior

When displaying inline diffs those add huge blocks of blank space.

Markdown:

Animation

Python:

grafik

Environment

deathaxe commented 3 years ago

This is what it looks like in SAFE MODE

Animation