Originally it was partially correct in that it did sound the bell, but it
also then exited the application and printed the details of the button --
the text didn't mention the latter aspect. This corrects that and removes
mention of the bell sound because we've now removed that.
While in this part of the docs we do want to keep the bell (see key02), it
was an error in the code that it included this event in key01. Removing it
from here because adding this bit of code for key02 is a key (no pun) part
of the docs.
Don't ping the terminal bell on every key-press. This might be okay on some
systems, on others (we're looking at you Windows) it's a wee bit
distracting.
See #955.
Addresses the issue raised in #939. Here I rework Screen._reset_focus so
that, rather than deal with siblings, it deals with the focus chain. It now
also optionally takes a list of DOMNodes to avoid and will, as that
suggests, avoid them when looking for somewhere to move focus to.
As a preference the new version of this will seek to settle focus on the
nearest (in the chain) *previous* non-excluded DOMNode.
NOTE: Currently the return value of Widget.walk_children is cast to a list
to ensure that it doesn't get consumed (as of the time of commit, it's still
qan iterable). Once https://github.com/Textualize/textual/pull/952 has been
accepted I'll change this (remove the cast).
This change ensures that, for example, the widget remains in the
Screen.focus_chain so that it's easier to handle passing off focus on
removal.
To help address #939.
Originally it returned an iterable, building that up from a list anyway. In
local discussion it's been decided that it makes more sense to simply return
the list. There's no obvious advantage to doing it a different way.
* checkbox widget
* fixes
* Checkbox additions, fix content width in horizontal layout
* Update docs, add tests for checkbox
* Remove some test code
* Small renaming of test class
Co-authored-by: Will McGugan <willmcgugan@gmail.com>