(self, parent, height: int = 300, **kwargs)
| 182 | """ |
| 183 | |
| 184 | def __init__(self, parent, height: int = 300, **kwargs): |
| 185 | super().__init__( |
| 186 | parent, |
| 187 | height=height, |
| 188 | fg_color=COLORS["bg_light"], |
| 189 | corner_radius=DIMENSIONS["corner_radius"], |
| 190 | border_width=1, |
| 191 | border_color=COLORS["border"], |
| 192 | **kwargs, |
| 193 | ) |
| 194 | |
| 195 | self.items: List[ctk.CTkButton] = [] |
| 196 | self.selected_index: Optional[int] = None |
| 197 | self._on_select: Optional[Callable] = None |
| 198 | self._on_double_click: Optional[Callable] = None |
| 199 | |
| 200 | # Enable mouse wheel scrolling |
| 201 | self._bind_scroll_events() |
| 202 | |
| 203 | def add_item(self, text: str, icon: str = "") -> None: |
| 204 | """Add an item to the list.""" |
nothing calls this directly
no test coverage detected