Rich-动画效果-《Python教程》

admin 2025-10-20 00:38:17 编程 来源:ZONE.CI 全球网 0 阅读模式

    在使用进度条时候,我们经常会使用到SpinnerColumn来增加 Loading 效果,这里会使用到spinner参数,其实这个参数在多处方法中都有设置,例如 console.status。但是官方文档中并未给出这个参数具体有哪些值可以设置,本篇文章进行一个整理和介绍,并列出个人认为比较好用的值。

    首先,如果你不知道有哪些值可以选择,那么可以使用如下语句来查看:

    1. $ python -m rich.spinner

    spinner参数可以选择下表中的值,其中标黄色的值,个人认为效果还不错:

    aesthetic arc arrow arrow2 arrow3
    balloon balloon2 betaWave bounce bouncingBall
    bouncingBar boxBounce boxBounce2
    christmas circle circleHalves circleQuarters clock
    dots dots10 dots11 dots12 dots2
    dots3 dots3 dots4 dots5 dots6
    dots7 dots8 dots8Bit dots9 dqpb
    grenade growHorizontal growVertical
    hamburger hearts
    layer line line2
    material monkey moon
    pipe point pong
    shark simpleDots simpleDotsScrolling smiley squareCorners
    squish star star2
    toggle toggle10 toggle11 toggle12 toggle13
    toggle2 toggle3 toggle4 toggle5 toggle6
    toggle7 toggle8 toggle9 triangle
    earth flip noise runner weather
    以太坊cppgolang区别 编程

    以太坊cppgolang区别

    以太坊是一种去中心化的开源平台,它采用智能合约技术,旨在构建和运行不受干扰的分布式应用程序。作为目前最受欢迎的区块链平台之一,以太坊提供了多种编程语言的支持,其
    progolang 编程

    progolang

    Go语言(Golang)是由Google开发的一门静态类型编程语言。作为一名专业的Golang开发者,我深知这门语言的优势和特点。在本文中,我将介绍Golang
    golangn个发送者 编程

    golangn个发送者

    Golang是一种开源的编程语言,由Google团队开发,旨在提高程序的并发性和简化软件开发过程。在Go语言中,有时需要向多个接收者发送信息。本文将介绍如何在G
    golang技能图谱 编程

    golang技能图谱

    从互联网行业的快速发展到人工智能技术的日益成熟,各种编程语言也应运而生。而在这众多的编程语言中,Golang(即Go)作为一门强大且高效的开发语言备受关注。Go
    评论:0   参与:  6