mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-21 23:01:05 +00:00
fix: use kitty old protocol for Konsole
This commit is contained in:
parent
2c84c48208
commit
5f8c20e2b5
4 changed files with 8 additions and 4 deletions
|
|
@ -41,7 +41,7 @@ https://github.com/sxyazi/yazi/assets/17523360/92ff23fa-0cd5-4f04-b387-894c12265
|
|||
| Platform | Protocol | Support |
|
||||
| ----------------- | ----------------------------------------------------------------------------------------------------- | -------------------------------------------------------------- |
|
||||
| kitty | [Kitty unicode placeholders](https://sw.kovidgoyal.net/kitty/graphics-protocol/#unicode-placeholders) | ✅ Built-in |
|
||||
| Konsole | [Inline images protocol](https://iterm2.com/documentation-images.html) | ✅ Built-in |
|
||||
| Konsole | [Kitty old protocol](https://github.com/sxyazi/yazi/blob/main/yazi-adaptor/src/kitty_old.rs) | ✅ Built-in |
|
||||
| iTerm2 | [Inline images protocol](https://iterm2.com/documentation-images.html) | ✅ Built-in |
|
||||
| WezTerm | [Inline images protocol](https://iterm2.com/documentation-images.html) | ✅ Built-in |
|
||||
| Mintty (Git Bash) | [Inline images protocol](https://iterm2.com/documentation-images.html) | ✅ Built-in |
|
||||
|
|
|
|||
|
|
@ -84,8 +84,7 @@ impl Adaptor {
|
|||
protocols.retain(|p| *p == Self::Iterm2);
|
||||
if env_exists("ZELLIJ_SESSION_NAME") {
|
||||
protocols.retain(|p| *p == Self::Sixel);
|
||||
}
|
||||
if *TMUX && protocols.len() > 1 {
|
||||
} else if *TMUX {
|
||||
protocols.retain(|p| *p != Self::KittyOld);
|
||||
}
|
||||
if let Some(p) = protocols.first() {
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ impl Emulator {
|
|||
match self {
|
||||
Self::Unknown(adapters) => adapters,
|
||||
Self::Kitty => vec![Adaptor::Kitty],
|
||||
Self::Konsole => vec![Adaptor::Iterm2, Adaptor::KittyOld, Adaptor::Sixel],
|
||||
Self::Konsole => vec![Adaptor::KittyOld],
|
||||
Self::Iterm2 => vec![Adaptor::Iterm2, Adaptor::Sixel],
|
||||
Self::WezTerm => vec![Adaptor::Iterm2, Adaptor::Sixel],
|
||||
Self::Foot => vec![Adaptor::Sixel],
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
use std::{io::{stderr, BufWriter}, sync::atomic::Ordering};
|
||||
|
||||
use crossterm::{execute, queue, terminal::{BeginSynchronizedUpdate, EndSynchronizedUpdate}};
|
||||
use ratatui::{backend::{Backend, CrosstermBackend}, buffer::Buffer, CompletedFrame};
|
||||
use scopeguard::defer;
|
||||
use yazi_plugin::elements::COLLISION;
|
||||
|
||||
use crate::{app::App, lives::Lives, root::Root};
|
||||
|
|
@ -11,6 +13,9 @@ impl App {
|
|||
return;
|
||||
};
|
||||
|
||||
queue!(stderr(), BeginSynchronizedUpdate).ok();
|
||||
defer! { execute!(stderr(), EndSynchronizedUpdate).ok(); }
|
||||
|
||||
let collision = COLLISION.swap(false, Ordering::Relaxed);
|
||||
let frame = term
|
||||
.draw(|f| {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue