Fix#877. Avoid calculating scrollback buffer size on each render, since the calculation becomes slower proportionally to the amount of lines buffered, and to the width of each line.
* wip: keep track of scrollback buffer size
* account for lines dropped by bounded_push
* fix: use saturating sub
* fix: account for 0 width lines
* remove log messages
* optimize EMPTY_TERMINAL_CHARACTER diff
return a diff for EMPTY_TERMINAL_CHARACTER only when necessary (when new_styles different than current), so to avoid
emitting a ansi reset code every time.
* simply character styles diffing logic
* refactor(tab): close_pane returns closed pane
Prepare for break pane command by making close_pane return the closed
pane. Also split the function up to hopefully be more readable.
* more refactoring
* refactor(screen): support multiple mirrored clients
* style(fmt): make rustfmt happy
* style(clippy): make clippy happy
* whitespace
* github, y u no update CI?!
* is this a cache issue?
* is it the checkout cache?
* no cache at all?
* Debug
* fix gototab
* decoment
* gototab none in wasm_vm
* gototab none in wasm_vm
* the fun never ends
* tests(e2e): update infra and add multiple user mirroring test
* refactor(tab): change structs in tabs and terminal panes to support multiple users
* style(fmt): make rustfmt happy
* style(fmt): make clippy happy
* fix(options): handling ond verwriting cli opts
* previously it was only possible to turn off certain features with a
command line option, now it is possible to also overwrite this
behavior in a sane way, for that some breaking changes happened:
following options got renamed and inverted:
```
disable_mouse_mode -> mouse_mode
no_pane_frames -> pane_frames
```
following cli options got added:
```
mouse-mode [bool]
pane-frames [bool]
simplified-ui [bool]
```
the following cli flag got removed:
```
simplified-ui
```
They can be specified in the following way:
```
zellij options --mouse-mode true
```
in order to enable the mouse mode, even if it is turned off in the
config file:
```
mouse_mode: false
```
The order is now as follows:
1. corresponding flag (`disable-mouse-mode`)
2. corresponding option (`mouse-mode`)
3. corresponding config option (`mouse_mode`)
* add: options and flags for the same value conflict
* example:
```
zellij options --mouse-mode true --disable-mouse-mode`
```
```
$ error: The argument '--mouse-mode <mouse-mode>' cannot be used with '--disable-mouse-mode'
```
add the ability to toggle boolean options with a cli flag:
example:
if the pane frames are turned off in the config file,
then passing in the `--no-pane-frames` flag will toggle the
pane frames on
* Half-page scroll actions #794
* fix(performance): do not hang when resizing large line wraps (#814)
* fix(performance): do not hang when resizing large line wraps
* style(fmt): make rustfmt happy
* style(clippy): make clippy happy
* docs(changelog): scroll fix
* fix(compatibility): home and end key fix (#815)
* fix(compatibility): handle home/end keys properly from terminfo
* style(fmt): make rustfmt happy
* style(fmt): remove unused import
* docs(changelog): home end key fix
* docs(changelog): fix link
* fix(typo): Correct typo from `occured` to `occurred` (#821)
* docs(changelog): fix a typo
* fix(docs): fix wrong arguments for `cargo make run` given in CONTRIBUTING.md (#819)
* docs(changelog): update `cargo-make` for `v0.35.3`
* fix(warning): Fix an unused import warning of std::fs on macos (#820)
* docs(changelog): fix unused import on darwin
* add: `WriteChars` action (#825)
* Behaves like the `Write` action, but one can specify
strings themselves instead of their bytecodes.
Usage:
WriteChars: "cargo make test",
* docs(changelog): Add `WriteChars` action
* fix(docs): Fix a typo and some grammatical errors in bug_report.md (#826)
* docs(changelog): fix typo bug_report template
* add: `rust-version` (msrv) field to `Cargo.toml` (#828)
* specifies the minimum version the package can be compiled with,
may be ignored with `--ignore-rust-version` option
ref: https://doc.rust-lang.org/nightly/cargo/reference/manifest.html#the-rust-version-field
* docs(changelog): add `rust-version` to `Cargo.toml`
* fix(unix): forkpty => openpty (#830)
* fix(unix): forkpty => openpty
* style(fmt): make rustfmt happy
* docs(changelog): forkpty => openpty
* Fix: move `colors_transform` to `colorsys` (#832)
* `colors_transform` is deprecated and superceded by `colorsys`
ref: https://crates.io/crates/colors-transform
* docs(changelog): `colors_transform` to `colorsys`
* feat(ui): add right-click support to plugins
* chore(docs): update changelog
* chore(warnings): remove unused imports (#833)
* rename var sroll_rows and review snapshots
* style(fmt): make rustfmt happy
Co-authored-by: Aram Drevekenin <aram@poor.dev>
Co-authored-by: Ken Matsui <26405363+ken-matsui@users.noreply.github.com>
Co-authored-by: a-kenji <aks.kenji@protonmail.com>
Co-authored-by: Tw <tw19881113@gmail.com>
Co-authored-by: Brooks Rady <b.j.rady@gmail.com>
* feature(resize): Non directional resize
* Implement special cases
* fix resizing for panes that have `+` cross section
* fix resizing for panes that have `T` cross section
* fix panics
* Add Nondirection resize keys to plugin
* fix formatting
* fix: clippy warnings
* fix the last edge case
* implemented some of the suggested changes
* Remove helper function and elevate comment to top of function
* Use `=` to keep it consistent with Normal mode mapping as its easier to use
* Remove extra reference borrowing
* fix an edge case
* add test for nondirectional resize increase/decrease
* fix(controls): add + to resize
* refactor(resize): simplify methods
* fix(resize): properly resize opposite corner pane
Co-authored-by: Aram Drevekenin <aram@poor.dev>
* fix(compatibility): handle wide characters inserted in line middle
* fix(compatibility): more wide char handling
* style(fmt): make rustfmt happy
* style(fmt): make clippy happy
* style(fmt): make clippyt happy
* style(fmt): make rustfmt happy... again
The current code waits for 30ms after reading new data to refresh the
screen in order to batch input together. This reduces the number of
refreshes, but also adds perceptible latency as keystrokes will only get
visual feedback after a 30 ms delay.
Improve this by immediately refreshing if more than 30ms have already
passed since the last refresh. That way punctual events like keystrokes
get immediate feedback, while heavier input still gets batched together.
* refactor(screen): support multiple mirrored clients
* style(fmt): make rustfmt happy
* style(clippy): make clippy happy
* whitespace
* github, y u no update CI?!
* is this a cache issue?
* is it the checkout cache?
* no cache at all?
* Debug
* fix gototab
* decoment
* gototab none in wasm_vm
* gototab none in wasm_vm
* the fun never ends
* style(fmt): make rustfmt happy
* feat(plugin): Add mouse events for plugins
* Add double click support in strider
* Add support for mouse clicks in tab-bar and fix bug in strider with selecting past the list of files and random double click action
* continue working on mouse support for tab bar
* finish tab change
* fix fmt and fix bug in strider double-click
* fix clippy
* cleanup dbgs and logs
* fix clippy
* noop change to rerun e2e tests
* Rebase and fix mouse click behavior in tab-bar and strider after rebase
* fix fmt
* remove dbgs and and comment in tab-line/main.rs
* cargo fmt
* Code review suggestions
* rebase fix
* fix clippy
* fix mouse selection for tabs in tab-bar
* call update_tabs on closing panes
* screen: avoid explit render after update_tabs
update_tabs causes a render anyway, by updating plugins, and after that
a render is requested.
* fix#306: Buffer new vte events when pane is scrolled up
* Exit scroll mode after pressing [Enter] once
* clear scroll of active pane when changing from scroll mode to normal or locked mode
* Increase render interval
* fix(ui): offset content after viewport construction
* Added the feature to display fullscreen information on the second line of the status-bar.
* fix(strider): update host mount-point
* fix(plugin): create missing data directories as needed
* feat(layout): specify only tab name in `tabs` section (#722)
Allow specifying only the tab name in the `tabs` section
- For example this is now possible:
```
tabs:
- name: first
parts:
- direction: Vertical
- direction: Vertical
- name: second
- name: third
```
For that the tab section defaults the direction to
`direction::Horizontal`
- Adds an error upon specifying a tab name inside the `parts` section
of the tab-layout
* docs(changelog): Solely name tab in `tabs` section
* feature(release): Copy default config to the examples folder on release (#736)
fixes#733
* docs(changelog): Copy example config on release
* Update default config (#737)
* feat(plugin): add manifest to allow for plugin configuration (#660)
* feat(plugins-manifest): Add a plugins manifest to allow for more configuration of plugins
* refactor(plugins-manifest): Better storage of plugin metadata in wasm_vm
* fix(plugins-manifest): Inherit permissions from run configuration
* refactor(plugins-manifest): Rename things for more clarity
- The Plugins/Plugin structs had "Config" appended to them to clarify
that they're metadata about plugins, and not the plugins themselves.
- The PluginType::OncePerPane variant was renamed to be just
PluginType::Pane, and the documentation clarified to explain what it
is.
- The "service" nomenclature was completely removed in favor of
"headless".
* refactor(plugins-manifest): Move security warning into start plugin
* refactor(plugins-manifest): Remove hack in favor of standard method
* refactor(plugins-manifest): Change display of plugin location
The only time that a plugin location is displayed in Zellij is the
border of the pane. Having `zellij:strider` display instead of just
`strider` was a little annoying, so we're stripping out the scheme
information from a locations display.
* refactor(plugins-manifest): Add a little more documentation
* fix(plugins-manifest): Formatting
Co-authored-by: Jesse Tuchsen <not@disclosing>
* chore(docs): update changelog
* feat(sessions): mirrored sessions (#740)
* feat(sessions): mirrored sessions
* fix(tests): input units
* style(fmt): make rustfmt happy
* fix(tests): make mirrored sessions e2e test more robust
* refactor(sessions): remove force attach
* style(fmt): rustfmtify
* docs(changelog): update change
* fix(e2e): retry on all errors
Co-authored-by: Brooks J Rady <b.j.rady@gmail.com>
Co-authored-by: a-kenji <aks.kenji@protonmail.com>
Co-authored-by: spacemaison <tuchsen@protonmail.com>
Co-authored-by: Jesse Tuchsen <not@disclosing>
Co-authored-by: Aram Drevekenin <aram@poor.dev>
* feat(sessions): mirrored sessions
* fix(tests): input units
* style(fmt): make rustfmt happy
* fix(tests): make mirrored sessions e2e test more robust
* refactor(sessions): remove force attach
* style(fmt): rustfmtify
* docs(changelog): update change
* fix(e2e): retry on all errors