This commit is contained in:
Nathan Sobo 2023-11-02 16:47:14 -06:00
parent 583c36e24b
commit 7b712ac68f
25 changed files with 13799 additions and 13530 deletions

View file

@ -3,7 +3,7 @@ use super::{
Highlights,
};
use crate::{Anchor, AnchorRangeExt, MultiBufferSnapshot, ToOffset};
use gpui::{fonts::HighlightStyle, Hsla};
use gpui::{HighlightStyle, Hsla};
use language::{Chunk, Edit, Point, TextSummary};
use std::{
any::TypeId,
@ -221,7 +221,7 @@ impl FoldMap {
(FoldMapWriter(self), snapshot, edits)
}
pub fn set_ellipses_color(&mut self, color: Color) -> bool {
pub fn set_ellipses_color(&mut self, color: Hsla) -> bool {
if self.ellipses_color != Some(color) {
self.ellipses_color = Some(color);
true
@ -469,7 +469,7 @@ pub struct FoldSnapshot {
folds: SumTree<Fold>,
pub inlay_snapshot: InlaySnapshot,
pub version: usize,
pub ellipses_color: Option<Color>,
pub ellipses_color: Option<Hsla>,
}
impl FoldSnapshot {
@ -959,7 +959,7 @@ pub struct FoldChunks<'a> {
inlay_offset: InlayOffset,
output_offset: usize,
max_output_offset: usize,
ellipses_color: Option<Color>,
ellipses_color: Option<Hsla>,
}
impl<'a> Iterator for FoldChunks<'a> {

View file

@ -1,6 +1,6 @@
use crate::{Anchor, InlayId, MultiBufferSnapshot, ToOffset};
use collections::{BTreeMap, BTreeSet};
use gpui::fonts::HighlightStyle;
use gpui::HighlightStyle;
use language::{Chunk, Edit, Point, TextSummary};
use multi_buffer::{MultiBufferChunks, MultiBufferRows};
use std::{

View file

@ -4,7 +4,7 @@ use super::{
Highlights,
};
use crate::MultiBufferSnapshot;
use gpui::{AppContext, Entity, Model, ModelContext, Task};
use gpui::{AppContext, FontId, Model, ModelContext, Pixels, Task};
use language::{Chunk, Point};
use lazy_static::lazy_static;
use smol::future::yield_now;
@ -22,7 +22,7 @@ pub struct WrapMap {
edits_since_sync: Patch<u32>,
wrap_width: Option<f32>,
background_task: Option<Task<()>>,
font: (FontId, f32),
font: (FontId, Pixels),
}
#[derive(Clone)]