clear text layout cache when setting diagnostics
@@ -478,6 +478,7 @@ pub fn set_language(&mut self, language: LapceLanguage) {
}
pub fn set_diagnostics(&mut self, diagnostics: &[EditorDiagnostic]) {
+ self.clear_text_layout_cache();
self.diagnostics = Some(Arc::new(
diagnostics
.iter()
