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.2.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.2-py3-none-any.whl (3.9 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: flet_gradient_text-1.1.2.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.2.tar.gz
Algorithm Hash digest
SHA256 eedd111eab881dd7d5e51f40792a6662065380c86c3b6a2ffb3b0168a6a324d9
MD5 255e07983e051d465a9111dc32fbd927
BLAKE2b-256 7c155f3f80bfc20d4659d335907ae5879d8a5a40a28df83d430526a25cc45bf3

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for flet_gradient_text-1.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b8636f1f0a1e3fddaf123dbdc0e35a40a12901dd76d6fc1088873d8041e7d0d9
MD5 fdcc43c58a8326a187a3d2c2597be15f
BLAKE2b-256 6d33a7f331cab01591bdefccefcf9fe7c43cac42d116382de928f29bbac03d1b

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