Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions DOCS/man/lua.rst
Original file line number Diff line number Diff line change
Expand Up @@ -931,6 +931,10 @@ REPL.
``keep_open``
Whether to keep the console open on submit. Defaults to ``false``.

It is recommended to set this to ``true`` when nesting ``input.get()``
or ``input.select()`` calls to avoid showing the console quickly closing
and reopening.
Comment on lines 932 to +936
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's worth being a little more specific. Someone reading this for the first time probably has no idea what 'nesting' means.

Suggested change
Whether to keep the console open on submit. Defaults to ``false``.
It is recommended to set this to ``true`` when nesting ``input.get()``
or ``input.select()`` calls to avoid showing the console quickly closing
and reopening.
Whether to keep the console open on submit, allowing further
input. Defaults to ``false``.
If calling ``input.get()`` or ``input.select()`` again from inside the
``submit`` callback, setting this option to ``true`` allows a seamless
transition without the console closing and reopening.


``opened``
A callback invoked when the console is shown. This can be used to
present a list of options with ``input.set_log()``.
Expand Down Expand Up @@ -1027,6 +1031,10 @@ REPL.
``keep_open``
Whether to keep the console open on submit. Defaults to ``false``.

It is recommended to set this to ``true`` when nesting ``input.get()``
or ``input.select()`` calls to avoid showing the console quickly closing
and reopening.
Comment on lines 1032 to +1036
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Whether to keep the console open on submit. Defaults to ``false``.
It is recommended to set this to ``true`` when nesting ``input.get()``
or ``input.select()`` calls to avoid showing the console quickly closing
and reopening.
Whether to keep the console open on submit, allowing further
input. Defaults to ``false``.
If calling ``input.get()`` or ``input.select()`` again from inside the
``submit`` callback, setting this option to ``true`` allows a seamless
transition without the console closing and reopening.


Example:

::
Expand Down