Skip to content
Open
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
9 changes: 1 addition & 8 deletions textual_terminal/_terminal.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,8 @@

from textual.widget import Widget
from textual import events
from textual.app import DEFAULT_COLORS

from textual import log
from textual.design import ColorSystem


class TerminalPyteScreen(pyte.Screen):
Expand Down Expand Up @@ -370,12 +368,7 @@ def detect_color(self, color: str) -> str:
def detect_textual_colors(self) -> dict:
"""Returns the currently used colors of textual depending on dark-mode."""

if self.app.dark:
color_system: ColorSystem = DEFAULT_COLORS["dark"]
else:
color_system: ColorSystem = DEFAULT_COLORS["light"]

return color_system.generate()
return self.app.current_theme.to_color_system().generate()

def initial_display(self) -> TerminalDisplay:
"""Returns the display when initially creating the terminal or clearing it."""
Expand Down