There are typically 3 types of usage of an HTML widget in most programing languages or libraries.
An HTML widget can be used to display help and manual documents in an application. In this case, the development team authors HTML document. The feature limits (typically lack of css and javascript) can be workaround by only ship documents that the widget can handle. So tools with small footprint and loads fast are preferred. These tools does not need to handle HTTP protocol beyond being able to open HTML files or strings. This is the major use of HTML widget available today.
Although such usage faces the competition of Lightweight markup languages, HTML widgets have the special advantage that document author can re-use mature and familiar HTML authoring software to prepare documents, and lowered learning barrier of document authors.
An HTML widget can also be used to offer user basic feature to surf the Internet, or as a web browser itself. In such case the tool must be able to handle HTTP protocol; their compatibility requirement and feature requirement must be high. There are two approaches in this direction: build an HTML rendering engine in tcl/tk, as explored by the project tkhtml3, and to embed a web rendering engine, as by TkGecko. Unfortunately both did not manage to reach a production release.
If even implemented, an HTML widget can also offer user editing of rich text content, like that was offered by CK Editor (an HTML editor written in javascript) or Kompozer (an HTML editor based on Mozilla). However none of the known HTML widgets have implementations on this direction.
The following table lists known HTML widgets, all mostly for the 1st type of usage mentioned above.
Libraries containing an HTML widget or standalone HTML widgets | ||||||||
---|---|---|---|---|---|---|---|---|
Project Name | Latest release | HTML | css | image | table | js | sloc | Description |
tkhtml3 | Alpha till 2009 | HTMl 4 | Yes | Yes | Yes | Yes | 53,656 | By Dan Kennedy, Tkhtml3 as a Tk widget supports HTML, CSS and javascript |
tkhtml2 [L1 ] | 2002 | No | Yes | Yes | No | 59,982 | By D. Richard Hipp, Tkhtml2 is faster and more lightweight than Tkhtml3 | |
Iwidgets | 2010 | HTML 3.2 | Yes | The library has scrolledhtml widget. Itself is part of incrtcl project. | ||||
TkWebView | 2009 | No | Yes | Yes | No | 1344 | A script-level widget for displaying HTML, either in a standalone window or embedded in another widget. This product is based on html_display, which is a decade older. | |
HTML display | 04/1999 | HTML 2.0 | No | Yes | Yes | No | 1067 | Supports all HTML/2.0 features, including forms. By 2000, one year after its original author stopped working on this product, others further developed on it but could not submit it to unmaintained upstream. Later Kevin Walzer released it under the new name "TkWebView". No public version repository or project celebration website is set up for this. |
shtmlview | 03/2022 | HTML 3.2 | No | Yes | Yes | No | 3017 | Snit widget and standalone viewer application based mainly on HTML display. Toolbar with basic browse facilities added and some support for tables, support for normal and base64-inline images (gif, png, jpeg, svg), can display as well Markdown files Github repository. |
gnocl::webKit | 01/2012 | HTML 5 | Yes | Yes | Yes | Yes | Wrapper for using the WebKit renderer inside gnocl-based gtk apps. (WebKit is a heavier, more full-featured and cutting edge engine, used in Chrome and Safari browsers.) | |
HelpViewer - based on Tkhtml3.0 | 2017 | HTML4.1 | CSS 2.1 | Yes | Yes | No | HelpViewer Application | |
A TclOO Tkhtml 3.0 megawidget - example of how to render html+css | 2017 | HTML4.1 | CSS 2.1 | Yes | Yes | No | html3widget megawidget / package |
Applications that contain their own HTML widgets | ||||||||
---|---|---|---|---|---|---|---|---|
Project Name | Latest release | HTML | css | image | table | js | sloc | Description |
AlphaTcl WWW menu [L2 ] | 12/2008 | Effectively a text-only HTML widget which can be used for lynx-like web browsing (all implemented in Tcl). When run under Alphatk, the underlying widget is Tk's text. | ||||||
Historical Software Projects no longer available on the Internet | ||||||||
Project Name | Latest release | HTML | css | image | table | js | sloc | Description |
TkGecko | concept till 2000 | HTML 4 | A project to embed gecko engine as a widget | |||||
tkhtml | long time ago | written by D. Richard Hipp. The current tkhtml project is a new project under the same name. | ||||||
chtml of Georage P.S. | 09/2004 | An HTML widget that parses and renders basic HTML | ||||||
hush | 10/1998 | C++ API for Tcl/Tk. Offer many widgets including an HTML widget. Requires Tcl 7.34, Tk 3.6, and TkPixmap extension. | ||||||
PTUI | A Tkinter-based IDE for Python, not Tcl. It includes an HTML viewer based on text. |