字数 9 个 阅读时间不到 1 分钟 访问量
APIs for playing videos
类:
-  VideoCanvas–A canvas that is scalable and playable for videos 
 
 VideoCanvas(
    master: containers.Tk | containers.Toplevel | containers.Canvas | None = None,
    *,
    controls: bool = False,
    loop: bool = False,
    click_pause: bool = True,
    expand: typing.Literal["", "x", "y", "xy"] = "xy",
    auto_zoom: bool = False,
    keep_ratio: typing.Literal["min", "max"] | None = None,
    free_anchor: bool = False,
    **kwargs
)
 Bases: containers.Canvas
A canvas that is scalable and playable for videos
- master: parent widget
- controls: whether to enable the built-in UI
- loop: whether the video loops automatically
- click_pause: whether to pause when clicked
- expand: the mode of expand,- xis horizontal, and- yis vertical
- auto_zoom: whether or not to scale its items
- keep_ratio: the mode of aspect ratio,- minfollows the minimum value,- maxfollows the maximum value
- free_anchor: whether the anchor point is free-floating
- kwargs: compatible with other parameters of class- tkinter.Canvas
方法: