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
6 changes: 6 additions & 0 deletions customtkinter/windows/widgets/ctk_tabview.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
from .core_rendering import DrawEngine
from .core_widget_classes import CTkBaseClass
from .ctk_segmented_button import CTkSegmentedButton
from .font import CTkFont


class CTkTabview(CTkBaseClass):
Expand Down Expand Up @@ -36,6 +37,7 @@ def __init__(self,
segmented_button_selected_hover_color: Optional[Union[str, Tuple[str, str]]] = None,
segmented_button_unselected_color: Optional[Union[str, Tuple[str, str]]] = None,
segmented_button_unselected_hover_color: Optional[Union[str, Tuple[str, str]]] = None,
segmented_button_font: Optional[Union[tuple, CTkFont]] = None,

text_color: Optional[Union[str, Tuple[str, str]]] = None,
text_color_disabled: Optional[Union[str, Tuple[str, str]]] = None,
Expand Down Expand Up @@ -75,6 +77,9 @@ def __init__(self,
height=self._apply_widget_scaling(self._desired_height - self._outer_spacing - self._outer_button_overhang))
self._draw_engine = DrawEngine(self._canvas)

# segmented_button_font font
self._segmented_button_font = CTkFont() if segmented_button_font is None else segmented_button_font

self._segmented_button = CTkSegmentedButton(self,
values=[],
height=self._button_height,
Expand All @@ -88,6 +93,7 @@ def __init__(self,
corner_radius=corner_radius,
border_width=self._segmented_button_border_width,
command=self._segmented_button_callback,
font=self._segmented_button_font,
state=state)
self._configure_segmented_button_background_corners()
self._configure_grid()
Expand Down