mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-25 21:31:09 +08:00
Add types to tkinter.colorchooser.askcolor (#8588)
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import sys
|
||||
from tkinter import Misc, _Color
|
||||
from tkinter.commondialog import Dialog
|
||||
from typing import ClassVar
|
||||
|
||||
@@ -8,4 +9,12 @@ if sys.version_info >= (3, 9):
|
||||
class Chooser(Dialog):
|
||||
command: ClassVar[str]
|
||||
|
||||
def askcolor(color: str | bytes | None = ..., **options) -> tuple[None, None] | tuple[tuple[float, float, float], str]: ...
|
||||
if sys.version_info >= (3, 9):
|
||||
def askcolor(
|
||||
color: str | bytes | None = ..., *, initialcolor: _Color = ..., parent: Misc = ..., title: str = ...
|
||||
) -> tuple[None, None] | tuple[tuple[int, int, int], str]: ...
|
||||
|
||||
else:
|
||||
def askcolor(
|
||||
color: str | bytes | None = ..., *, initialcolor: _Color = ..., parent: Misc = ..., title: str = ...
|
||||
) -> tuple[None, None] | tuple[tuple[float, float, float], str]: ...
|
||||
|
||||
Reference in New Issue
Block a user