Skip to main content

A flet component for gradient & animated text

Project description

flet_gradient_text

It displays text with a colorful gradient and optional animation of the gradient.

installation:

pip install flet_gradient_text

🔧 Parameters

  • text(str): The text content to display
  • text_size(optional): default text_size=20, Font size of the text
  • text_weight: optional, Font weight (e.g., ft.FontWeight.BOLD)
  • text_style(optional): property of type ft.TextStyle
  • animate (bool): default animate=False, True to Enable animation
  • duration(float or int): default duration=0.5, Controls the speed of the animation
  • gradient: (optional) Custom gradient to apply over the text, default LinearGradient
  • on_click(optional): Event handler when the text is clicked
  • on_hover(optional): Event handler when hovering over the text

🧩 Usage

import flet as ft
from flet_gradient_text import GradientText

def main(page: ft.Page):
    page.add(
        GradientText(
            text="Hello Gradient!",
            text_size=40,
            text_weight=ft.FontWeight.BOLD,
            animate=True,
            duration=1,
        )
    )

ft.app(target=main)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

flet_gradient_text-1.1.1.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

flet_gradient_text-1.1.1-py3-none-any.whl (3.9 kB view details)

Uploaded Python 3

File details

Details for the file flet_gradient_text-1.1.1.tar.gz.

File metadata

  • Download URL: flet_gradient_text-1.1.1.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.10

File hashes

Hashes for flet_gradient_text-1.1.1.tar.gz
Algorithm Hash digest
SHA256 30a560d3caa183856bb17e43e9331c1c3068348e3f086d12c0d5341e2783b02f
MD5 666d8ab82173a5013b892e84e44684b7
BLAKE2b-256 fdc94a2ec889f336af6c05601ad4240d244569e85e2a5896112cc975d212dadb

See more details on using hashes here.

File details

Details for the file flet_gradient_text-1.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for flet_gradient_text-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e6bd86f0c98858346278cebb1b388c987ba84db770b69c0c70d0c703aa365123
MD5 427362c6af3d3ce2a5b9b8e4cb0dce0a
BLAKE2b-256 b85f34e5a8dcc67a1651d0b4f49fc5fad777c34e32cea8242403bcd7b202f02c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page