aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAram Drevekenin <aram@poor.dev>2026-07-08 11:46:41 +0200
committerGitHub <noreply@github.com>2026-07-08 11:46:41 +0200
commit70c65a9afd5b4cfe41ef0a294831433230dbbcab (patch)
tree1f87786bb9f7f0431c562d926c8e1a3e1e92c47a
parentfix(windows): preserve backslashes when quoting spawned-process arguments (#5... (diff)
downloadsl0ppij-70c65a9afd5b4cfe41ef0a294831433230dbbcab.tar.gz
sl0ppij-70c65a9afd5b4cfe41ef0a294831433230dbbcab.tar.xz
sl0ppij-70c65a9afd5b4cfe41ef0a294831433230dbbcab.zip
Stacked list fixes (#5342)
* clear padding line * better stack ui * fix tests * add pr
-rw-r--r--CHANGELOG.md2
-rw-r--r--zellij-integration-tests/tests/snapshots/misc__previous_swap_layout.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/panes__new_stacked_pane.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/panes__toggle_frames_with_stacked_panes.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_held_members_exit_code_shows_on_its_entry.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_member_exiting_removes_its_entry.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__a_layout_stack_renders_as_a_title_list.snap6
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__a_stack_list_survives_session_resurrection.snap6
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__breaking_the_visible_member_out_promotes_and_moves_it_to_a_new_tab.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__clicking_a_hidden_entry_swaps_it_in.snap6
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__closing_the_visible_member_promotes_its_neighbor.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__entries_share_a_uniform_width_sized_by_the_widest_title.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__floating_the_visible_member_promotes_its_neighbor.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__fullscreen_suspends_the_list_and_restores_it.snap6
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__moving_the_visible_member_reorders_the_list.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__resizing_the_visible_member_keeps_the_list.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__splitting_a_new_pane_reforms_the_list_around_it.snap6
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__stack_renders_as_title_list_above_the_visible_pane.snap6
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__the_visible_members_scroll_state_shows_on_its_entry.snap4
-rw-r--r--zellij-integration-tests/tests/snapshots/stacked_pane_list__up_and_down_move_the_selection_through_the_list.snap6
-rw-r--r--zellij-integration-tests/tests/stacked_pane_list.rs2
-rw-r--r--zellij-server/src/tab/mod.rs24
-rw-r--r--zellij-server/src/ui/pane_boundaries_frame.rs42
23 files changed, 96 insertions, 64 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index ee71eded..f391774c 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -14,7 +14,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
* feat: new title-frames UI (https://github.com/zellij-org/zellij/pull/5318)
* chore: upgrade wasmi to 1.1.0 (https://github.com/zellij-org/zellij/pull/5319)
* fix: fragmented STDIN causing "garbage" input on slow SSH connections (https://github.com/zellij-org/zellij/pull/5320)
-* feat: stacked lists - new stack UI (https://github.com/zellij-org/zellij/pull/5331 and https://github.com/zellij-org/zellij/pull/5337)
+* feat: stacked lists - new stack UI (https://github.com/zellij-org/zellij/pull/5331, https://github.com/zellij-org/zellij/pull/5337 and https://github.com/zellij-org/zellij/pull/5342)
* fix: more verbose startup errors (https://github.com/zellij-org/zellij/pull/5334)
* fix(windows): route Windows Terminal through the VT input path (https://github.com/zellij-org/zellij/pull/5335)
* fix(windows): backslashes dropped when quoting arguments passed to spawned processes (https://github.com/zellij-org/zellij/pull/5336)
diff --git a/zellij-integration-tests/tests/snapshots/misc__previous_swap_layout.snap b/zellij-integration-tests/tests/snapshots/misc__previous_swap_layout.snap
index edf1efb7..58cec6d6 100644
--- a/zellij-integration-tests/tests/snapshots/misc__previous_swap_layout.snap
+++ b/zellij-integration-tests/tests/snapshots/misc__previous_swap_layout.snap
@@ -3,7 +3,7 @@ source: zellij-integration-tests/tests/misc.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #2
+ │ Pane #1 │
+ > │ Pane #2 │
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/panes__new_stacked_pane.snap b/zellij-integration-tests/tests/snapshots/panes__new_stacked_pane.snap
index 6dce9ccd..53780375 100644
--- a/zellij-integration-tests/tests/snapshots/panes__new_stacked_pane.snap
+++ b/zellij-integration-tests/tests/snapshots/panes__new_stacked_pane.snap
@@ -3,7 +3,7 @@ source: zellij-integration-tests/tests/panes.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #2
+ │ Pane #1 │
+ > │ Pane #2 │
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/panes__toggle_frames_with_stacked_panes.snap b/zellij-integration-tests/tests/snapshots/panes__toggle_frames_with_stacked_panes.snap
index a955d0d9..88e86821 100644
--- a/zellij-integration-tests/tests/snapshots/panes__toggle_frames_with_stacked_panes.snap
+++ b/zellij-integration-tests/tests/snapshots/panes__toggle_frames_with_stacked_panes.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/panes.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #2
+ │ Pane #1 │
+ > │ Pane #2 │
┌──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│$ █ │
│ │
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_held_members_exit_code_shows_on_its_entry.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_held_members_exit_code_shows_on_its_entry.snap
index ba84ee58..ee9a1683 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_held_members_exit_code_shows_on_its_entry.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_held_members_exit_code_shows_on_its_entry.snap
@@ -3,7 +3,7 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- > Pane #1
- member-command [ EXIT CODE: 2 ]
+ > │ Pane #1 │
+ │ member-command │ [ EXIT CODE: 2 ]
█
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_member_exiting_removes_its_entry.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_member_exiting_removes_its_entry.snap
index a968820b..79032956 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_member_exiting_removes_its_entry.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_hidden_member_exiting_removes_its_entry.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #3
+ │ Pane #1 │
+ > │ Pane #3 │
$ third-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_layout_stack_renders_as_a_title_list.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_layout_stack_renders_as_a_title_list.snap
index cda205c2..11e6c483 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_layout_stack_renders_as_a_title_list.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_layout_stack_renders_as_a_title_list.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- > Pane #1
- Pane #2
- Pane #3
+ > │ Pane #1 │
+ │ Pane #2 │
+ │ Pane #3 │
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_stack_list_survives_session_resurrection.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_stack_list_survives_session_resurrection.snap
index ccf9842d..d2ac8ca5 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_stack_list_survives_session_resurrection.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__a_stack_list_survives_session_resurrection.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- Pane #2
- > Pane #3
+ │ Pane #1 │
+ │ Pane #2 │
+ > │ Pane #3 │
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__breaking_the_visible_member_out_promotes_and_moves_it_to_a_new_tab.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__breaking_the_visible_member_out_promotes_and_moves_it_to_a_new_tab.snap
index 35a49566..b826bbb3 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__breaking_the_visible_member_out_promotes_and_moves_it_to_a_new_tab.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__breaking_the_visible_member_out_promotes_and_moves_it_to_a_new_tab.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  Tab #2  + 
- Pane #1
- > Pane #2
+ │ Pane #1 │
+ > │ Pane #2 │
$ second-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__clicking_a_hidden_entry_swaps_it_in.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__clicking_a_hidden_entry_swaps_it_in.snap
index 571ada79..f668c907 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__clicking_a_hidden_entry_swaps_it_in.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__clicking_a_hidden_entry_swaps_it_in.snap
@@ -3,9 +3,9 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&swapped_in)
---
Zellij (test)  Tab #1  + 
- > Pane #1
- Pane #2
- Pane #3
+ > │ Pane #1 │
+ │ Pane #2 │
+ │ Pane #3 │
$ first-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__closing_the_visible_member_promotes_its_neighbor.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__closing_the_visible_member_promotes_its_neighbor.snap
index ecb49594..eb49f79c 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__closing_the_visible_member_promotes_its_neighbor.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__closing_the_visible_member_promotes_its_neighbor.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #2
+ │ Pane #1 │
+ > │ Pane #2 │
$ second-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__entries_share_a_uniform_width_sized_by_the_widest_title.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__entries_share_a_uniform_width_sized_by_the_widest_title.snap
index 81785c95..932de18b 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__entries_share_a_uniform_width_sized_by_the_widest_title.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__entries_share_a_uniform_width_sized_by_the_widest_title.snap
@@ -3,7 +3,7 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- > Pane #1
- member-command
+ > │ Pane #1 │
+ │ member-command │
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__floating_the_visible_member_promotes_its_neighbor.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__floating_the_visible_member_promotes_its_neighbor.snap
index f912750c..e2764c1c 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__floating_the_visible_member_promotes_its_neighbor.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__floating_the_visible_member_promotes_its_neighbor.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #2
+ │ Pane #1 │
+ > │ Pane #2 │
$ second-member
$
┌ Pane #3 ──────────────────────────────────────── PIN [ ] ┐
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__fullscreen_suspends_the_list_and_restores_it.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__fullscreen_suspends_the_list_and_restores_it.snap
index e04f4c85..c13c5953 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__fullscreen_suspends_the_list_and_restores_it.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__fullscreen_suspends_the_list_and_restores_it.snap
@@ -3,9 +3,9 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- Pane #2
- > Pane #3
+ │ Pane #1 │
+ │ Pane #2 │
+ > │ Pane #3 │
$ third-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__moving_the_visible_member_reorders_the_list.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__moving_the_visible_member_reorders_the_list.snap
index 4992e1f6..51856330 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__moving_the_visible_member_reorders_the_list.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__moving_the_visible_member_reorders_the_list.snap
@@ -7,8 +7,8 @@ expression: normalized(&grid_snapshot)
$ first-member
$
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
- > Pane #3
- Pane #2
+ > │ Pane #3 │
+ │ Pane #2 │
$ third-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__resizing_the_visible_member_keeps_the_list.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__resizing_the_visible_member_keeps_the_list.snap
index e6411622..c27f1e30 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__resizing_the_visible_member_keeps_the_list.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__resizing_the_visible_member_keeps_the_list.snap
@@ -7,7 +7,7 @@ expression: normalized(&grid_snapshot)
$ first-member
$
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
- Pane #2
- > Pane #3
+ │ Pane #2 │
+ > │ Pane #3 │
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__splitting_a_new_pane_reforms_the_list_around_it.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__splitting_a_new_pane_reforms_the_list_around_it.snap
index cde05d3f..19ad4045 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__splitting_a_new_pane_reforms_the_list_around_it.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__splitting_a_new_pane_reforms_the_list_around_it.snap
@@ -3,9 +3,9 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- Pane #2
- > Pane #3
+ │ Pane #1 │
+ │ Pane #2 │
+ > │ Pane #3 │
$ third-member
$
────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__stack_renders_as_title_list_above_the_visible_pane.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__stack_renders_as_title_list_above_the_visible_pane.snap
index e04f4c85..c13c5953 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__stack_renders_as_title_list_above_the_visible_pane.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__stack_renders_as_title_list_above_the_visible_pane.snap
@@ -3,9 +3,9 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- Pane #2
- > Pane #3
+ │ Pane #1 │
+ │ Pane #2 │
+ > │ Pane #3 │
$ third-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__the_visible_members_scroll_state_shows_on_its_entry.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__the_visible_members_scroll_state_shows_on_its_entry.snap
index 155453b0..cf60fd92 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__the_visible_members_scroll_state_shows_on_its_entry.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__the_visible_members_scroll_state_shows_on_its_entry.snap
@@ -3,8 +3,8 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&grid_snapshot)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #2 [ SCROLL: 21/22 ]
+ │ Pane #1 │
+ > │ Pane #2 │ [ SCROLL: 21/22 ]
line1
line2
line3
diff --git a/zellij-integration-tests/tests/snapshots/stacked_pane_list__up_and_down_move_the_selection_through_the_list.snap b/zellij-integration-tests/tests/snapshots/stacked_pane_list__up_and_down_move_the_selection_through_the_list.snap
index dad03f9a..e4252167 100644
--- a/zellij-integration-tests/tests/snapshots/stacked_pane_list__up_and_down_move_the_selection_through_the_list.snap
+++ b/zellij-integration-tests/tests/snapshots/stacked_pane_list__up_and_down_move_the_selection_through_the_list.snap
@@ -3,9 +3,9 @@ source: zellij-integration-tests/tests/stacked_pane_list.rs
expression: normalized(&middle_member_selected)
---
Zellij (test)  Tab #1  + 
- Pane #1
- > Pane #2
- Pane #3
+ │ Pane #1 │
+ > │ Pane #2 │
+ │ Pane #3 │
$ second-member
$ █
Ctrl + <g> LOCK  <p> PANE  <t> TAB  <n> RESIZE  <h> MOVE  <s> SEARCH  <o> SESSION  <q> QUIT  ...
diff --git a/zellij-integration-tests/tests/stacked_pane_list.rs b/zellij-integration-tests/tests/stacked_pane_list.rs
index e3404f8c..8bb401cf 100644
--- a/zellij-integration-tests/tests/stacked_pane_list.rs
+++ b/zellij-integration-tests/tests/stacked_pane_list.rs
@@ -50,7 +50,7 @@ layout {
"#;
fn selected_entry(title: &str) -> String {
- format!("> {}", title)
+ format!("> │ {}", title)
}
fn add_stacked_pane_and_wait_for_selected_entry(
diff --git a/zellij-server/src/tab/mod.rs b/zellij-server/src/tab/mod.rs
index 45657176..dc9c0409 100644
--- a/zellij-server/src/tab/mod.rs
+++ b/zellij-server/src/tab/mod.rs
@@ -50,7 +50,7 @@ use crate::{
panes::grid::namespace_notification_id,
panes::sixel::SixelImageStore,
panes::{FloatingPanes, TiledPanes},
- panes::{LinkHandler, PaneId, PluginPane, TerminalPane},
+ panes::{LinkHandler, PaneId, PluginPane, TerminalPane, EMPTY_TERMINAL_CHARACTER},
plugins::PluginInstruction,
pty::{ClientTabIndexOrPaneId, PtyInstruction, VteBytes},
thread_bus::ThreadSenders,
@@ -1530,10 +1530,15 @@ impl Tab {
};
let lists: Vec<StackList> = self.stack_lists.values().cloned().collect();
for list in lists {
- let rect = match self.tiled_panes.get_pane(list.visible) {
- Some(p) => p.position_and_size(),
+ let (rect, visible_content_offset) = match self.tiled_panes.get_pane(list.visible) {
+ Some(p) => (p.position_and_size(), p.get_content_offset()),
None => continue,
};
+ let entry_x = rect.x + visible_content_offset.left;
+ let entry_cols = rect
+ .cols
+ .as_usize()
+ .saturating_sub(visible_content_offset.left + visible_content_offset.right);
let widest_member_title = list
.members
.iter()
@@ -1550,6 +1555,8 @@ impl Tab {
let stack_is_focused = active_panes.values().any(|p_id| *p_id == list.visible);
for (rank, member) in list.members.iter().enumerate() {
let mut header_geom = rect;
+ header_geom.x = entry_x;
+ header_geom.cols.set_inner(entry_cols);
header_geom.y = rect.y + rank;
header_geom.rows = Dimension::fixed(1);
header_geom.stacked = None;
@@ -1593,6 +1600,17 @@ impl Tab {
)?;
}
}
+ let mut padding_row = Vec::with_capacity(entry_cols);
+ for _ in 0..entry_cols {
+ padding_row.push(EMPTY_TERMINAL_CHARACTER);
+ }
+ let padding_chunk =
+ CharacterChunk::new(padding_row, entry_x, rect.y + list.members.len());
+ output.add_character_chunks_to_multiple_clients(
+ vec![padding_chunk],
+ connected_clients.iter().copied(),
+ None,
+ )?;
}
Ok(())
}
diff --git a/zellij-server/src/ui/pane_boundaries_frame.rs b/zellij-server/src/ui/pane_boundaries_frame.rs
index 73420336..5aca749d 100644
--- a/zellij-server/src/ui/pane_boundaries_frame.rs
+++ b/zellij-server/src/ui/pane_boundaries_frame.rs
@@ -743,10 +743,14 @@ impl PaneFrame {
.with_context(|| format!("failed to render title '{}'", self.title))
}
fn render_stack_list_entry(&self, entry: &StackListEntry) -> Vec<TerminalCharacter> {
- let usable_cols = self.geom.cols.saturating_sub(2);
+ let usable_cols = self.geom.cols;
let selection_marker = "> ";
let marker_width = selection_marker.width();
- let inner_width = entry.width.min(usable_cols.saturating_sub(marker_width));
+ let corner_padding = 1;
+ let corner_overhead = 2 * (1 + corner_padding);
+ let inner_width = entry
+ .width
+ .min(usable_cols.saturating_sub(marker_width + corner_overhead));
let content = if entry.label.width() <= inner_width {
entry.label.clone()
} else {
@@ -761,7 +765,7 @@ impl PaneFrame {
truncated.push('…');
truncated
};
- let full_width_entry_length = marker_width + inner_width;
+ let full_width_entry_length = marker_width + corner_overhead + inner_width;
let entry_start = usable_cols.saturating_sub(full_width_entry_length) / 2;
let left_budget = entry_start;
let (mut focus_part, focus_length) = self
@@ -773,6 +777,15 @@ impl PaneFrame {
line.push(EMPTY_TERMINAL_CHARACTER);
}
let unfocused_color = self.style.colors.frame_unselected.map(|frame| frame.base);
+ let style_entry_text = |text: &str| {
+ if entry.is_selected || entry.is_emphasized {
+ foreground_color(text, self.color)
+ } else if entry.stack_is_focused {
+ foreground_color(text, unfocused_color)
+ } else {
+ dimmed_foreground_color(text, unfocused_color)
+ }
+ };
if entry.is_selected {
line.append(&mut foreground_color(selection_marker, None));
} else {
@@ -780,18 +793,19 @@ impl PaneFrame {
line.push(EMPTY_TERMINAL_CHARACTER);
}
}
- let mut styled_content = if entry.is_selected || entry.is_emphasized {
- foreground_color(&content, self.color)
- } else if entry.stack_is_focused {
- foreground_color(&content, unfocused_color)
- } else {
- dimmed_foreground_color(&content, unfocused_color)
- };
- line.append(&mut styled_content);
- let entry_padding = full_width_entry_length.saturating_sub(marker_width + content.width());
- for _ in 0..entry_padding {
+ line.append(&mut foreground_color(boundary_type::VERTICAL, None));
+ for _ in 0..corner_padding {
line.push(EMPTY_TERMINAL_CHARACTER);
}
+ line.append(&mut style_entry_text(&content));
+ let content_padding = inner_width.saturating_sub(content.width());
+ for _ in 0..content_padding {
+ line.push(EMPTY_TERMINAL_CHARACTER);
+ }
+ for _ in 0..corner_padding {
+ line.push(EMPTY_TERMINAL_CHARACTER);
+ }
+ line.append(&mut foreground_color(boundary_type::VERTICAL, None));
let mut occupied_columns = entry_start + full_width_entry_length;
let (mut scroll_part, scroll_length) = self
.bracketed_scroll_indicator(usable_cols.saturating_sub(occupied_columns))
@@ -1267,7 +1281,7 @@ impl PaneFrame {
if let Some(entry) = &self.stack_list_entry {
character_chunks.push(CharacterChunk::new(
self.render_stack_list_entry(entry),
- self.geom.x + 1,
+ self.geom.x,
self.geom.y,
));
return Ok((character_chunks, None));