History log of /openbsd-current/usr.bin/tmux/popup.c
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 1.53 21-Mar-2024 nicm

Do not notify window-layout-changed if the window is about to be
destroyed (since it may have been freed by the time the notify happens),
from Romain Francoise in GitHub issue 3860.


Revision tags: OPENBSD_7_4_BASE OPENBSD_7_5_BASE
# 1.52 15-Aug-2023 nicm

Add an option menu-selected-style to configure the currently selected
menu item, from Alexis Hildebrandt.


# 1.51 08-Aug-2023 nicm

Add options and flags for menu styles similar to those existing for
popups, from Alexis Hildebrandt. GitHub issue 3650.


# 1.50 21-Jun-2023 nicm

Check fdopen return value, from Christian Menges.


# 1.49 08-Jun-2023 nicm

Fix mismatch between function prototype and definition, from Anindya
Mukherjee.


Revision tags: OPENBSD_7_3_BASE
# 1.48 15-Mar-2023 nicm

Do not leak screen in popups, GitHub issue 3492.


# 1.47 20-Jan-2023 nicm

Add a flag to display-menu to select the manu item chosen first, GitHub
issue 3442.


Revision tags: OPENBSD_7_1_BASE OPENBSD_7_2_BASE
# 1.46 22-Feb-2022 nicm

Use correct size for screen when popup is created without borders.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.52 15-Aug-2023 nicm

Add an option menu-selected-style to configure the currently selected
menu item, from Alexis Hildebrandt.


# 1.51 08-Aug-2023 nicm

Add options and flags for menu styles similar to those existing for
popups, from Alexis Hildebrandt. GitHub issue 3650.


# 1.50 21-Jun-2023 nicm

Check fdopen return value, from Christian Menges.


# 1.49 08-Jun-2023 nicm

Fix mismatch between function prototype and definition, from Anindya
Mukherjee.


Revision tags: OPENBSD_7_3_BASE
# 1.48 15-Mar-2023 nicm

Do not leak screen in popups, GitHub issue 3492.


# 1.47 20-Jan-2023 nicm

Add a flag to display-menu to select the manu item chosen first, GitHub
issue 3442.


Revision tags: OPENBSD_7_1_BASE OPENBSD_7_2_BASE
# 1.46 22-Feb-2022 nicm

Use correct size for screen when popup is created without borders.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.51 08-Aug-2023 nicm

Add options and flags for menu styles similar to those existing for
popups, from Alexis Hildebrandt. GitHub issue 3650.


# 1.50 21-Jun-2023 nicm

Check fdopen return value, from Christian Menges.


# 1.49 08-Jun-2023 nicm

Fix mismatch between function prototype and definition, from Anindya
Mukherjee.


Revision tags: OPENBSD_7_3_BASE
# 1.48 15-Mar-2023 nicm

Do not leak screen in popups, GitHub issue 3492.


# 1.47 20-Jan-2023 nicm

Add a flag to display-menu to select the manu item chosen first, GitHub
issue 3442.


Revision tags: OPENBSD_7_1_BASE OPENBSD_7_2_BASE
# 1.46 22-Feb-2022 nicm

Use correct size for screen when popup is created without borders.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.50 21-Jun-2023 nicm

Check fdopen return value, from Christian Menges.


# 1.49 08-Jun-2023 nicm

Fix mismatch between function prototype and definition, from Anindya
Mukherjee.


Revision tags: OPENBSD_7_3_BASE
# 1.48 15-Mar-2023 nicm

Do not leak screen in popups, GitHub issue 3492.


# 1.47 20-Jan-2023 nicm

Add a flag to display-menu to select the manu item chosen first, GitHub
issue 3442.


Revision tags: OPENBSD_7_1_BASE OPENBSD_7_2_BASE
# 1.46 22-Feb-2022 nicm

Use correct size for screen when popup is created without borders.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.48 15-Mar-2023 nicm

Do not leak screen in popups, GitHub issue 3492.


# 1.47 20-Jan-2023 nicm

Add a flag to display-menu to select the manu item chosen first, GitHub
issue 3442.


Revision tags: OPENBSD_7_1_BASE OPENBSD_7_2_BASE
# 1.46 22-Feb-2022 nicm

Use correct size for screen when popup is created without borders.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.47 20-Jan-2023 nicm

Add a flag to display-menu to select the manu item chosen first, GitHub
issue 3442.


Revision tags: OPENBSD_7_1_BASE OPENBSD_7_2_BASE
# 1.46 22-Feb-2022 nicm

Use correct size for screen when popup is created without borders.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.46 22-Feb-2022 nicm

Use correct size for screen when popup is created without borders.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.45 16-Feb-2022 nicm

Support more mouse buttons when the terminal sends them, GitHub issue
3055.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.44 01-Feb-2022 nicm

A menu must be shown on a client, so always give the client when adding
the items. Also fix mode menus.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.43 17-Jan-2022 nicm

Do not try to strdup NULL, from seL4 at disroot dot org in GitHub issue
3038.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.42 25-Oct-2021 nicm

Add -s and -S to display-popup to set popup and border style, from
Alexis Hildebrandt in GitHub issue 2931.


# 1.41 25-Oct-2021 nicm

Instead of setting the popup default colours in the draw callback, set
it up in popup_display and follow the same routine as panes in the draw
and init_ctx callbacks - use the palette if the option value is default.
Allows application-set fg and bg to work in panes again.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.40 20-Oct-2021 nicm

Remove a TODO comment.


# 1.39 20-Oct-2021 nicm

Add -T to set a popup title, from Alexis Hildebrandt in GitHub issue 2941.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.38 14-Oct-2021 nicm

Add popup-border-lines option to set popup line style, from Alexis
Hildebrandt, GitHub issue 2930.


# 1.37 13-Oct-2021 nicm

Add popup-style and popup-border-style options, from Alexis Hildebrandt
in GitHub issue 2927.


# 1.36 11-Oct-2021 nicm

Make positions hidden by overlays range-based rather than character-based,
from Anindya Mukherjee.


# 1.35 11-Oct-2021 nicm

Add -e flag to set environment for popup, from Alexis Hildebrandt in
GitHub issue 2924.


Revision tags: OPENBSD_7_0_BASE
# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.34 17-Aug-2021 nicm

Revert previous; this is not how it should work.


# 1.33 17-Aug-2021 nicm

Start sync before drawing popup.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.32 13-Aug-2021 nicm

Tweak how mouse works on popup: only Meta alone resizes or moves, not
Meta with other modifiers; button 2 on the left or top border opens
menu, right or bottom resizes; button 1 on any border moves.


# 1.31 13-Aug-2021 nicm

Check callback needs to only return 0 (text should be suppressed) if
menu returns 0, otherwise it should check the popup also.


# 1.30 13-Aug-2021 nicm

Fill in some other bits on new panes.


# 1.29 13-Aug-2021 nicm

Add menu options to convert a popup into a pane.


# 1.28 13-Aug-2021 nicm

Adjust overlay check callback before drawing data from pty.


# 1.27 13-Aug-2021 nicm

Add a menu when a popup is present (mouse only for now).


# 1.26 13-Aug-2021 nicm

Add -B flag to remove border from popup.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.25 11-Aug-2021 nicm

Break the colour palette into a struct rather than just a single array
and use that to support the OSC palette-setting sequences in popups.
Also add a pane-colours array option to specify the defaults. GitHub
issue 2815.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.24 05-Aug-2021 nicm

Do not freeze output in panes when a popup is open, let them continue to
redraw. From Anindya Mukherjee .


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.23 21-Jul-2021 nicm

Do not close popups on resize, instead adjust them to fit, from Anindya
Mukherjee.


Revision tags: OPENBSD_6_9_BASE
# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.22 02-Mar-2021 nicm

Drop support for popups where the content is provided directly to tmux
(which does not have many practical uses) and only support running a
program in the popup. display-popup is now simpler and can accept
multiple arguments to avoid escaping problems (like the other commands).


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.21 02-Feb-2021 nicm

Fix popup mouse position.


Revision tags: OPENBSD_6_8_BASE
# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.20 22-Sep-2020 nicm

Resize screen to the correct size (borders need to be taken off).


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.19 16-May-2020 nicm

Separate key flags and modifiers, log key flags, make the "xterm" flag
more explicit and fix M- keys with a leading escape.


# 1.18 16-May-2020 nicm

xterm-keys has been on by default for five years and all other modern
terminals use these key sequences by default. Merge the code into the
main tty and input tree processing (converting the latter to use a tree
rather than a table at the same time) and make the option a no-op.


# 1.17 16-May-2020 nicm

Move editor stuff to common code in popup.c.


# 1.16 16-May-2020 nicm

Only redraw popup on the client it belongs to.


# 1.15 16-May-2020 nicm

Do not hoke into struct window_pane from the tty code and instead set
everything up in tty_ctx. Provide a way to initialize the tty_ctx from a
callback and use it to let popups draw directly through input_parse in
the same way as panes do, rather than forcing a full redraw on every
change.


# 1.14 16-May-2020 nicm

Add 'e' key in buffer mode to open the buffer in an editor.


Revision tags: OPENBSD_6_7_BASE
# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.13 13-Apr-2020 nicm

Add helpers for the simple case of parse string and add to command queue.


# 1.12 13-Apr-2020 nicm

When adding a list of commands to the queue, instead of automatically
creating a new state for each group of commands, require the caller to
create one and use it for all the commands in the list. This means the
current target works even with list with multiple groups (which can
happen if they are defined with newlines).


# 1.11 13-Apr-2020 nicm

Move cmdq_state into cmd-queue.c.


# 1.10 13-Apr-2020 nicm

Rename cmdq_shared to cmdq_state which will better reflect what it is
(going to be) used for.


# 1.9 13-Apr-2020 nicm

Store a key event not a mouse event in the shared data.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.8 13-Apr-2020 nicm

Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
use more clearly defined and preparation for some future work).


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.7 07-Apr-2020 nicm

Limit size to 1x1 (total size 3x3).


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.6 01-Apr-2020 nicm

Support mouse in popups.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.5 31-Mar-2020 nicm

Detach reply escape sequences from the pane so they work in popups.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.4 30-Mar-2020 nicm

Do not check flags after the popup struct has been freed.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.3 28-Mar-2020 nicm

Make two -E only close popup automatically if the command exited with 0.


# 1.2 28-Mar-2020 nicm

Fix how popup height is calculated to take embedded newlines into account.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.


# 1.1 24-Mar-2020 nicm

Add support for overlay popup boxes to show text or output temporarily
above the normal layout. These work similarly to menus and are created
with the display-popup command.