mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-14 15:57:07 +08:00
tkinter.font.Font: make __getitem__ and cget behave the same (#4899)
This commit is contained in:
@@ -46,7 +46,6 @@ class Font:
|
||||
underline: bool = ...,
|
||||
overstrike: bool = ...,
|
||||
) -> None: ...
|
||||
def __getitem__(self, key: str) -> Any: ...
|
||||
def __setitem__(self, key: str, value: Any) -> None: ...
|
||||
@overload
|
||||
def cget(self, option: Literal["family"]) -> str: ...
|
||||
@@ -59,6 +58,9 @@ class Font:
|
||||
@overload
|
||||
def cget(self, option: Literal["underline", "overstrike"]) -> Literal[0, 1]: ...
|
||||
@overload
|
||||
def cget(self, option: str) -> Any: ...
|
||||
__getitem__ = cget
|
||||
@overload
|
||||
def actual(self, option: Literal["family"], displayof: Optional[tkinter.Misc] = ...) -> str: ...
|
||||
@overload
|
||||
def actual(self, option: Literal["size"], displayof: Optional[tkinter.Misc] = ...) -> int: ...
|
||||
|
||||
Reference in New Issue
Block a user