Skip to main content

HTML/CSS viewer for Tkinter

Project description

TkinterWeb

A fast and lightweight cross-platform webbrowser for Tkinter.

   

Overview

TkinterWeb offers bindings for the Tkhtml3 widget from http://tkhtml.tcl.tk/tkhtml.html, which enables loading HTML and CSS code into Tkinter applications.

All major operating systems running Python 3+ are supported.

   

Usage

TkinterWeb provides a webbrowser frame, a label widget capable of displaying styled HTML, and an HTML-based geometry manager.

TkinterWeb can be used in any Tkinter application. Here is an example:

import tkinter as tk #import Tkinter
from tkinterweb import HtmlFrame #import the HTML browser

root = tk.Tk() #create the tkinter window
frame = HtmlFrame(root) #create HTML browser

frame.load_website("http://tkhtml.tcl.tk/tkhtml.html") #load a website
frame.pack(fill="both", expand=True) #attach the HtmlFrame widget to the parent window
root.mainloop()

Refer to the GitHub home page for more information.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

tkinterweb-3.24.7.tar.gz (1.4 MB view hashes)

Uploaded Source

Built Distributions

tkinterweb-3.24.7-py3-none-win_amd64.whl (398.7 kB view hashes)

Uploaded Python 3 Windows x86-64

tkinterweb-3.24.7-py3-none-win32.whl (398.2 kB view hashes)

Uploaded Python 3 Windows x86

tkinterweb-3.24.7-py3-none-manylinux1_x86_64.whl (301.3 kB view hashes)

Uploaded Python 3

tkinterweb-3.24.7-py3-none-manylinux1_i686.whl (305.8 kB view hashes)

Uploaded Python 3

tkinterweb-3.24.7-py3-none-macosx_11_0_arm64.whl (260.4 kB view hashes)

Uploaded Python 3 macOS 11.0+ ARM64

tkinterweb-3.24.7-py3-none-macosx_10_6_x86_64.whl (284.1 kB view hashes)

Uploaded Python 3 macOS 10.6+ x86-64

tkinterweb-3.24.7-py3-none-linux_armv7l.whl (282.2 kB view hashes)

Uploaded Python 3

tkinterweb-3.24.7-py3-none-any.whl (1.4 MB view hashes)

Uploaded Python 3

Supported by

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