mirror of
https://github.com/zed-industries/zed.git
synced 2024-09-19 10:29:35 +03:00
💄
This commit is contained in:
parent
bafac35d6a
commit
2e7593dd79
@ -418,11 +418,10 @@ impl FoldMapSnapshot {
|
||||
transform_cursor.seek(&offset, SeekBias::Right, &());
|
||||
let overshoot = offset.0 - transform_cursor.start().display.bytes;
|
||||
let buffer_offset = transform_cursor.start().buffer.bytes + overshoot;
|
||||
let rope_cursor = self.buffer.text_for_range(buffer_offset..self.buffer.len());
|
||||
Chunks {
|
||||
transform_cursor,
|
||||
buffer_offset,
|
||||
buffer_chunks: rope_cursor,
|
||||
buffer_chunks: self.buffer.text_for_range(buffer_offset..self.buffer.len()),
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -377,9 +377,7 @@ impl<'a> Iterator for HighlightedChunks<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
let style_id = self.style_id;
|
||||
self.style_id = StyleId::default();
|
||||
Some((mem::take(&mut self.chunk), style_id))
|
||||
Some((mem::take(&mut self.chunk), mem::take(&mut self.style_id)))
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user