aboutsummaryrefslogtreecommitdiff
path: root/alacritty_terminal/src/term/mod.rs
Commit message (Collapse)AuthorAge
* Add alacritty extension script support.rahm2Josh Rahm2024-08-14
| | | | | | | | | This allows an escape code to invoke user-defined extensions found in /home/rahm/.local/bin/alacritty-ext.sh. The terminal passes to this script the escape-code arguments. This allows things like opening links in the browser even through an ssh connection.
* Fix spelling errorsJosh Soref2024-08-14
|
* Fix window being focused by defaultKirill Chibisov2024-08-14
| | | | | | | | | Winit explicitly states that the window is not focused by default and the `Focused` event will deliver the state later on. Also start adding notable changes to alacritty_terminal in its own CHANGELOG. Closes #7866.
* Fix hint `Select` action for hyperlink escapeChristian Duerr2024-08-14
| | | | | | | | | | | | This fixes an issue where the `Select` action for hyperlink escape text would select the entire line, instead of selecting only the hyperlink itself. It also changes the way hyperlinks with the same ID are highlighted, removing the restriction of being on consecutive lines and instead highlighting all visible cells that correspond to the matching hyperlink. Closes #7766.
* Fix log typoshuajin tong2024-08-14
|
* Fix serde tests without default featuresChristian Duerr2024-01-06
| | | Authored-by: James McCoy <jamessan@jamessan.com>
* Implement kitty's keyboard protocolKirill Chibisov2023-12-06
| | | | | | | | The protocol enables robust key reporting for the applications, so they could bind more keys and the user won't have collisions with the normal control keys. Links: https://sw.kovidgoyal.net/kitty/keyboard-protocol Fixes #6378.
* Fix DECRPM reportingKirill Chibisov2023-11-29
| | | | | The DECRQM uses `p` to query, but the reply uses `y`. Fixes #7397.
* Damage only terminal inside `alacritty_terminal`Kirill Chibisov2023-11-23
| | | | | | | | | | | | The damage tracking was including selection and vi_cursor which were rendering viewport related, however all the damage tracking inside the `alacritty_terminal` was _terminal viewport_ related, meaning that it should be affected by `display_offset`. Refactor the damage tracking so `alacritty_terminal` is only tracking actual terminal updates and properly applying display offset to them, while `alacritty` pulls this damage into its own UI damage state. Fixes #7111.
* Add support for DECRPM/DECRQMKirill Chibisov2023-11-23
|
* Update VTE to 0.13.0Kirill Chibisov2023-11-23
|
* Remove `alacritty_config` from alacritty_terminalKirill Chibisov2023-11-10
| | | | | There's no need to force alacritty's user configuration on other users of the crate, thus provide the options actually used by alacritty_terminal itself.
* Fix clippy warningsPavel Roskin2023-10-29
|
* Fix typosPavel Roskin2023-10-25
|
* Update dependenciesChristian Duerr2023-10-08
| | | | This patch applies all breaking and non-breaking dependency updates and bumps MSRV to 1.70.0.
* Add `terminal` config section to control OSCs Kirill Chibisov2023-07-22
| | | | | | | | | | | | | | Some environments demand certain OSC sequences to be disabled or some escape sequence could require handling which is out of scope of alacritty, but could be done by external script (OSC 777). Added section for now just handles the `OSC 52` sequence and changes its default to be `OnlyCopy`, which is handy for remote copy, but `Paste` is redundant because normal `Paste` hotkey could be used as well. Fixes #3386. Co-authored-by: Christian Duerr <contact@christianduerr.com>
* Switch to VTE's built-in ansi featureAnhad Singh2023-05-23
| | | Co-authored-by: Christian Duerr <contact@christianduerr.com>
* Update bitflags to 2.2.1Kirill Chibisov2023-05-17
|
* Fix selection rotation on the last lineChristian Duerr2023-03-24
| | | | | | | | | | | | | This fixes an issue with terminal resizes when the selection is on the last line. Alacritty would fail to rotate lines and keep the selection in the same line index whenever the terminal line count was grown or shrunk. This issue occurred due to the range passed to the selection's rotate function still being based on the old terminal size, which caused the initial or target state of the rotation to be outside of the terminal bounds. Closes #6698.
* Update winit to 0.28Kirill Chibisov2023-02-02
| | | | | | | | Fixes #6644. Fixes #6615. Fixes #6558. Fixes #6515. Fixes #3187. Fixes #62.
* Preserve last column with erase in line rightChristian Duerr2023-01-15
| | | | | | | | | | When the erase in line escape sequence with a parameter of 0 (right) is passed while the wrapline flag is already set, it will no longer clear the last column and instead ignore the operation. The behavior of `\e[1K` and `\e[2K` is unchanged and both will clear the entire first line without clearing the wrapline flag. Closes #6159.
* Fix clippy warningsChristian Duerr2022-10-12
| | | | | This patch applies all clippy lints currently present on the latest clippy master than are compatible with our oldstable clippy (only exception is the `_else(||` stuff).
* Make grid mutably accessible to librariesMikayla Maki2022-07-29
| | | Co-authored-by: Mikayla Maki <mikayla.c.maki@icloud.com>
* Fix hyperlinks not being keyboard actionableKirill Chibisov2022-07-11
| | | | | | This fixes a typo in 694a52b which was filtering all hyperlinks, except only duplicated ones when opening them with keyboard. Co-authored-by: Christian Duerr <contact@christianduerr.com>
* Add support for hyperlink escape sequenceKirill Chibisov2022-07-10
| | | | | | | This commit adds support for hyperlink escape sequence `OSC 8 ; params ; URI ST`. The configuration option responsible for those is `hints.enabled.hyperlinks`. Fixes #922.
* Fix old vi cursor not being properly damagedKirill Chibisov2022-06-07
| | | Co-authored-by: Christian Duerr <contact@christianduerr.com>
* Fix Vi cursor not being damaged on scrollKirill Chibisov2022-05-26
| | | | | There's no need to damage intermediate Vi mode cursor points, since it can't change the terminal content meaning that only the previous and current vi cursor's viewport points matter to damage it properly.
* Extract `SizeInfo` from alacritty_terminalKirill Chibisov2022-04-06
| | | | | The `SizeInfo` is a SizeInfo used for rendering, which contains information about padding, and such, however all the terminal need is number of visible lines and columns.
* Fix OSC 4 color response formatChristian Duerr2022-03-31
| | | | | | | | | | The commit 60ef17e introduced support for the color query response escape for OSC 4, however it did omit the `4;` prefix and started the OSC with just the color index. This patch fixes this bug and correctly responds to queries with full OSC 4 format, including prefix plus color index. Fixes #5981.
* Add colored underline supportKirill Chibisov2022-03-16
| | | | | | | | | This commit adds support for colored underline and refines the dynamic extra storage. The extra storage now is using `Arc` making cloning it way faster compared to `Box` approach which scales really well when it comes to cloning in `Term::write_at_cursor`, since cloning `Arc` is constant time. Fixes #4142.
* Fix crash when searching during resetChristian Duerr2022-03-10
| | | | | | | | | | | | | | | | | | This fixes a crash which occurs when the terminal is reset while searching, due to the vi mode cursor being outside of the visible area. This also fixes an issue where the search state reset would incorrectly clamp the vi mode cursor to the grid, rather than the absolute viewport position. While this fix does resolve all crashes when searching while running `cat /dev/urandom`, it does raise the question if manually clamping the vi mode cursor in every location where it is modified is the right choice. A follow-up to provide a safer API which guarantees correct modification of the vi mode cursor location is probably a good idea. Fixes #5942.
* Add support for dashed and dotted underlinesKirill Chibisov2022-02-14
| | | | This finishes implementation of underline styles provided by `CSI 4 : [1-5] m` escape sequence.
* Add support for drawing undercurlsKirill Chibisov2022-02-08
| | | Fixes #1628.
* Fix alacritty_terminal not emitting damage on color changeKirill Chibisov2022-02-07
|
* Add damage tracking and reporting to compatible compositorsKirill Chibisov2022-02-02
| | | | | | | | | | | | | | This allows compositors to only process damaged (that is, updated) regions of our window buffer, which for larger window sizes (think 4k) should significantly reduce compositing workload under compositors that support/honor it, which is good for performance, battery life and lower latency over remote connections like VNC. On Wayland, clients are expected to always report correct damage, so this makes us a good citizen there. It can also aid remote desktop (waypipe, rdp, vnc, ...) and other types of screencopy by having damage bubble up correctly. Fixes #3186.
* Fix typo in SizeInfo padding_y rustdocÖmer Sinan Ağacan2022-01-21
|
* Add ´?´ support to OSC 4DaftMouse2022-01-15
|
* Fix last column block selectiona5ob7r2022-01-07
| | | | | This fixes a regression introduced in 8e584099, where block selections containing the last cell would have the trailing newline stripped and be joined into one long line on copy.
* Trim \n from hints/semantic-/simple selectiona5ob7r2022-01-04
| | | | | | | | | | Before this patch a hint regex ending in the last column would append a newline, despite this newline being "invisible" to the user. To match the expected behavior, newlines are trimmed from regex hint matches. To ensure consistency the simple and semantic selection also do not include a newline at the end of the copied text anymore. Fixes #5697.
* Keep history position when viewport is cleareda5ob7r2021-12-18
| | | | | | | | This patch resolves a behavior that display area doesn't keep track of content in a scrollback buffer due to display offset reset when viewport clear is invoked. This is similar to #5341, but this problem is caused by viewport clear instead of new outputs to the viewport.
* Remove trailing whitespace from block selectionjeremycostanzo2021-12-18
| | | Fixes #5638.
* Fix vi cursor moving incorrectly with new outputa5ob7r2021-12-03
| | | | | | | | This fixes an issue where the vi cursor would move down one line if it's positioned at the topmost visible line, while at least partially scrolled up into history, when new lines are added to the terminal. This problem is caused by using a display offset of a grid not scrolled yet when scrolling and determining a new vi cursor position.
* Fix crash when vi cursor in history during cleara5ob7r2021-12-03
| | | Fixes #5544.
* Add parameters to `msg create-window` subcommandKirill Chibisov2021-11-22
| | | | | | | | | | | | | | | Alacritty's `msg create-window` subcommand would previously inherit all the CLI parameters from the original executable. However not only could this lead to unexpected behavior, it also prevents multi-window users from making use of parameters like `-e`, `--working-directory`, or `--hold`. This is solved by adding a JSON-based message format to the IPC socket messages which instructs the Alacritty server on which CLI parameters should be used to create the new window. Fixes #5562. Fixes #5561. Fixes #5560.
* Add multi-window supportChristian Duerr2021-10-23
| | | | | | | | | | | | | | | | | | | | | | | | | | Previously Alacritty would always initialize only a single terminal emulator window feeding into the winit event loop, however some platforms like macOS expect all windows to be spawned by the same process and this "daemon-mode" can also come with the advantage of increased memory efficiency. The event loop has been restructured to handle all window-specific events only by the event processing context with the associated window id. This makes it possible to add new terminal windows at any time using the WindowContext::new function call. Some preliminary tests have shown that for empty terminals, this reduces the cost of additional terminal emulators from ~100M to ~6M. However at this point the robustness of the daemon against issues with individual terminals has not been refined, making the reliability of this system questionable. New windows can be created either by using the new `CreateNewWindow` action, or with the `alacritty msg create-window` subcommand. The subcommand sends a message to an IPC socket which Alacritty listens on, its location can be found in the `ALACRITTY_SOCKET` environment variable. Fixes #607.
* Fix fullwidth character crash on resizeChristian Duerr2021-08-01
| | | Fixes #5383.
* Fix insert mode crash with fullwidth charactersChristian Duerr2021-07-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch resolves an issue with fullwidth characters, where it is possible to crash Alacritty by moving a fullwidth character off the side of the terminal using insert mode. This issue occurs since trying to overwrite a fullwidth spacer in the first column leads to an underflow when trying to access its fullwidth character cell. During insert mode before the character is inserted into the cell, the existing content is rotated to the right, which leads to the fullwidth spacer being in the first column even though it is only there temporarily to be immediately overwritten. While it would be possible to clear the flags after rotation, this would still leave the opportunity for other ways to trigger this issue and cause a separate crash. So instead the column is checked while overwriting the spacer to make sure the fullwidth character isn't accessed if it would lead to an underflow. The following is a minimal example for reproducing this crash: ```sh printf "漢" printf "\e[4h" printf "\r" for _ in $(seq 3 $(tput cols)); do printf "x" done printf "\r_" ``` Fixes #5337.
* Fix vi cursor tracking during scrollingChristian Duerr2021-07-17
| | | | | | | | | | | | This resolves an issue with the vi mode cursor where it would not keep track of the content while scrolled up in history but instead slowly leave the viewport due to its absolute positioning. While an alternative solution would have been to always keep the vi mode cursor in the same spot on the viewport, keeping track of the content is not only more easy to implement but it also makes for a nicer connection between the vi mode cursor and the content below it. Fixes #5339.
* Fix copying interrupted tab charactersChristian Duerr2021-07-16
| | | Fixes #5084.
* Fix search regressionsChristian Duerr2021-07-12
| | | Fixes #5315.