refactor: tweak with bufferline icon spacing
This commit is contained in:
parent
c8e3a569ce
commit
0d3e4f3bb8
1 changed files with 10 additions and 5 deletions
|
@ -650,11 +650,16 @@ impl EditorView {
|
|||
let config = editor.config();
|
||||
let icon = config.icons.mime.get(lang);
|
||||
|
||||
let text = format!(
|
||||
" {icon} {}{} ",
|
||||
fname,
|
||||
if doc.is_modified() { "[+]" } else { "" }
|
||||
);
|
||||
let text = if lang == icon {
|
||||
format!(" {} {}", fname, if doc.is_modified() { "[+] " } else { "" })
|
||||
} else {
|
||||
format!(
|
||||
" {icon} {} {}",
|
||||
fname,
|
||||
if doc.is_modified() { "[+] " } else { "" }
|
||||
)
|
||||
};
|
||||
|
||||
let used_width = viewport.x.saturating_sub(x);
|
||||
let rem_width = surface.area.width.saturating_sub(used_width);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue