Skip to main content

Tkinter Custom Widgets

Project description

Tkinter Custom Widgets

This package contains custom tkinter widgets that might be useful.

Installation

pip install tkinterwidgets

Widgets


  • Label

    Features

    • Transparent background
    • Control opacity

    Usage

    tkinterwidgets.Label(parent,OPTIONS)
    

    Options

    • All the options of native tkinter Label except bg/background since the background is transparent.
    • opacity - Used to specify the opacity of the contents on a scale of 0 to 1 (where 0 implies transparent and 1 implies opaque). The default is set to 1.
    • transcolor - Used to specify the color to be used to create the transparency effect (you can imagine this as a green screen but of the specified color, make sure that the visible contents of the label do not have this color). The default is set to SystemButtonFace .

    Methods

    • pack - Same usage as that of the pack geometry manager in tkinter.
    • config/configure - Set values of one or more options.

    Current Limitations / Issues

    • Only pack geometry manager can be used.
    • Can not be treated as a window in Canvas.create_window() or Text.window_create() or any similar usage.
    • In some cases, the label remains outside the window when the size of the window is reduced.

    Sample Code

    from tkinter import *
    import tkinterwidgets as tkw 
    
    root=Tk()
    root.config(bg='yellow')
    
    label=Label(root,text='Default Label')
    label.pack()
    
    trans_label=tkw.Label(root,text='tkinterwidgets Label',opacity=0.7)
    trans_label.pack(pady=10)
    
    root.mainloop()
    

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

tkinterwidgets-0.0.2.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

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

tkinterwidgets-0.0.2-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file tkinterwidgets-0.0.2.tar.gz.

File metadata

  • Download URL: tkinterwidgets-0.0.2.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.23.0 setuptools/51.3.3 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.3

File hashes

Hashes for tkinterwidgets-0.0.2.tar.gz
Algorithm Hash digest
SHA256 6f6365d76293a4a21160383145552b78886abeaeae4ec4f6dfeabc7f5513a16b
MD5 9876037cf9a845490e57d8f4815926e9
BLAKE2b-256 252cb279a4f870155facfca71a436a927da1942e649d18d1f1543c3bb35e16c1

See more details on using hashes here.

File details

Details for the file tkinterwidgets-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: tkinterwidgets-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.23.0 setuptools/51.3.3 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.3

File hashes

Hashes for tkinterwidgets-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3fbb9a614fca67388d841d795473b9917e0e68847edc13874a0a262b71513965
MD5 8be4c0fae15326af6141389db2b22521
BLAKE2b-256 82185c65367183610e5ad5afa0b1a174dedcbae070b026ce5654723052f98e7f

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