mirror of
https://github.com/wez/wezterm.git
synced 2024-12-23 21:32:13 +03:00
dcbbda7702
This commit introduces a 4th draw pass for rendering sixel and iterm images that are attached to cells. Previously, a cell could container either text or an image from the perspective of the renderer. If it had an image then the glyph bitmap would be ignored in favor of the image. However, that causes sixel behavior to diverge from other terminals (https://github.com/wez/wezterm/issues/942) so we need to be render both of these. The simplest way to achieve this is to add a distinct set of texture coordinates for the attached image and then add a draw pass to alpha blend it over the glyph content. The sixel/iterm image processing stage is also adjusted to preserve the prior cell information and "simply" attach the image info to the cell. Previously, the cell would be replaced with a blank cell with the image attached. The result of this is that the notcurses-demo intro section can now render the orca "enveloped in the soft glow of glyphs" rather than caged in a black box. Note that there are some cases where the render turns blocky but I suspect that that is due to some other misunderstanding between wezterm and notcurses and that we'll root cause it as a follow up. |
||
---|---|---|
.. | ||
src | ||
Cargo.toml | ||
README.md |
wezterm-term
This crate provides the core of the virtual terminal emulator implementation used by wezterm. The home for this crate is in the wezterm repo and development is tracked at https://github.com/wez/wezterm/.
It is full featured, providing terminal escape sequence parsing, keyboard and mouse input encoding, a model for the screen cells including scrollback, sixel and iTerm2 image support, OSC 8 Hyperlinks and a wide range of terminal cell attributes.
This crate does not provide any kind of gui, nor does it directly
manage a PTY; you provide a std::io::Write
implementation that
could connect to a PTY, and supply bytes to the model via the
advance_bytes
method.
The entrypoint to the crate is the Terminal struct.
License: MIT