Rework hover delay, respect editor font size, and enable hover in multibuffers

This commit is contained in:
Keith Simmons
2022-06-09 17:03:44 -07:00
parent ee33fb03f2
commit b51bd87c10
5 changed files with 253 additions and 239 deletions
+2 -1
View File
@@ -937,7 +937,7 @@ impl MultiBuffer {
&self,
position: impl ToOffset,
cx: &AppContext,
) -> Option<(ModelHandle<Buffer>, Range<text::Anchor>)> {
) -> Option<(ExcerptId, ModelHandle<Buffer>, Range<text::Anchor>)> {
let snapshot = self.read(cx);
let position = position.to_offset(&snapshot);
@@ -945,6 +945,7 @@ impl MultiBuffer {
cursor.seek(&position, Bias::Right, &());
cursor.item().map(|excerpt| {
(
excerpt.id.clone(),
self.buffers
.borrow()
.get(&excerpt.buffer_id)