Track buffer row divergence while iterating through diff lines
This allows for offsetting head row index of deleted lines to normalize into buffer row space
This commit is contained in:
parent
446bf88655
commit
b9d84df127
2 changed files with 27 additions and 31 deletions
|
@ -552,7 +552,7 @@ impl EditorElement {
|
|||
|
||||
//TODO: This rendering is entirely a horrible hack
|
||||
DiffHunkStatus::Removed => {
|
||||
let row = hunk.buffer_range.start as i64 - 1;
|
||||
let row = hunk.buffer_range.start;
|
||||
|
||||
let offset = line_height / 2.;
|
||||
let start_y = row as f32 * line_height + offset - scroll_top;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue