S or /

SourceClass CodeTheme

from egui.syntax_highlighting import CodeTheme
class CodeTheme:

Methods§

Source@staticmethod def dark(font_size: float) -> CodeTheme§

Example

Source@staticmethod def from_memory(ctx: Context, style: Style) -> CodeTheme§

Load code theme from egui memory.

There is one dark and one light theme stored at any one time.

Source@staticmethod def from_style(style: Style) -> CodeTheme§

Selects either dark or light theme based on the given style.

Sourcedef is_dark(self, /) -> bool§
Source@staticmethod def light(font_size: float) -> CodeTheme§

Example

Sourcedef store_in_memory(self, /, ctx: Context) -> None§

Store theme to egui memory.

There is one dark and one light theme stored at any one time.

def ui(self, /, ui: Ui) -> None§