Closed
Description
I see a lot of F3 key events on the console when I have a VerticalScroll which is taking up 100% of the height of an inline app, eg:
Key(key='f3', character=None, name='f3', is_printable=False) >>> VerticalScroll() method=<Widget.on_key>
Key(key='f3', character=None, name='f3', is_printable=False) >>> Screen(id='_default') method=<Widget.on_key>
Key(key='f3', character=None, name='f3', is_printable=False) >>> MyApp(title='MyApp', classes={'-dark-mode'}, pseudo_classes={'focus', 'dark', 'inline'}) method=<App.on_key>
To recreate:
from textual.app import App, ComposeResult
from textual.containers import VerticalScroll
from textual.widgets import Button
class TestApp(App):
def compose(self) -> ComposeResult:
# yield Header()
with VerticalScroll():
yield Button("hello", id="output")
if __name__ == "__main__":
app = TestApp()
app.run(inline=True)
run with textual run --dev test.py
and you will see f3 key events in the console; it appears they are raised each time the app gains or loses focus, or redraws.
Uncomment the Header
, run with inline=False
, or set a css height under 100% and they stop appearing.
Metadata
Metadata
Assignees
Labels
No labels