Skip to content

Commit 4ec7d38

Browse files
authored
Merge pull request #5551 from Textualize/fix-iterm-detect
Fix detection of iTerm
2 parents c57bf45 + 91b9b30 commit 4ec7d38

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/)
66
and this project adheres to [Semantic Versioning](http://semver.org/).
77

8+
## Unreleased
9+
10+
### Fixed
11+
12+
- Fixed smooth scrolling broken on iTerm over SSH https://github.com/Textualize/textual/pull/5551
13+
814
## [2.0.4] - 2025-02-17
915

1016
### Fixed

src/textual/_xterm_parser.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,10 @@
4343
)
4444

4545

46-
IS_ITERM = os.environ.get("TERM_PROGRAM", "") == "iTerm.app"
46+
IS_ITERM = (
47+
os.environ.get("LC_TERMINAL", "") == "iTerm2"
48+
or os.environ.get("TERM_PROGRAM", "") == "iTerm.app"
49+
)
4750

4851

4952
class XTermParser(Parser[Message]):

0 commit comments

Comments
 (0)