• ANNOUNCE: shtmlview 1.0.0

    From D Groth@21:1/5 to All on Tue Mar 22 23:37:53 2022
    shtmlview is a Tcl only snit megawidget to display HTML pages with support for most HTML 3.2 tags and Markdown files. It should be used for local HTML and Markdown files only for instance to display help pages within a Tk application. It does not
    support stylesheets, not web forms and not http(s) addresses. As it is a Tcl only extension it does not require any compilation. It is based on old code from Stephen Uhler, Clif Flynt and Robert Heller.

    * Project page: hhttps://github.com/mittelmark/shtmlview
    * Download: https://github.com/mittelmark/shtmlview/archive/refs/tags/v1.0.0.zip
    * Manual: http://htmlpreview.github.io/?https://github.com/mittelmark/shtmlview/blob/master/shtmlview/shtmlview.html
    * Wikipage: https://wiki.tcl-lang.org/page/shtmlview

    Version 1.0.0 adds support for Markdown documents (using tcllibs Markdown library), base64 encoded inline images, support for jpeg (using img::jpeg) and svg images (using svgconvert or terminal applications rsvg-convert or cairosvg), support for the HTML
    3.2 tags sub, sup, small, big, div (the latter can be used for styling). The rendering speed was as well improved, but obviously it is much slower than the binary counterparts tkhtml and tkhtml3. The project has now it's own Github page to allow tagging
    and real versioning.

    Thanks to aplsimple and pepdiz for bug reports and suggestions. Without feedback - no progress!

    D Groth

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Gerry@21:1/5 to All on Tue Mar 29 07:41:49 2022
    Your package looks interesting. One of these long spring evenings
    I may look into it to see how hard it would be to have it use
    entries in an SQLite database rather than files.


    Gerry Snyder
    --

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Bezoar@21:1/5 to Gerry on Tue Apr 12 06:55:39 2022
    On Tuesday, March 29, 2022 at 9:41:53 AM UTC-5, Gerry wrote:
    Your package looks interesting. One of these long spring evenings
    I may look into it to see how hard it would be to have it use
    entries in an SQLite database rather than files.


    Gerry Snyder
    --
    Yes if it supported loading from a buffer rather than just from a file that would be a good enhancement.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From D Groth@21:1/5 to Bezoar on Thu Apr 21 21:31:21 2022
    Dear Gerry and Bezoar,

    In the current Github code I implemented your suggestion so that you can render directly HTML or Markdown strings.

    The method is: `pathName render text ?ext?`

    if html tags are present it will be rendered as HTML. If there are no tags at the beginning per default Markdown is assumed. The format can be enforced as well by providing the default file extension.

    Have a look at the manual page. I am only in doubt currently how to handle links if there are no files ... I think there should be a user defined function to handle links to non-existing files. I'm open here for suggestions.

    https://htmlpreview.github.io/?https://github.com/mittelmark/shtmlview/blob/master/shtmlview/shtmlview.html#section4

    The current Git source code can be downloaded here:

    https://downgit.github.io/#/home?url=https://github.com/mittelmark/shtmlview/tree/main/shtmlview

    Please note that the script was reorganized together with akupries to allow inclusion into tklib. shtmlview is as well there in the current fossil trunk (slighly behind my github code).

    Furthermore a plugin structure was added to allow rendering of other file formats which can be translated into HTML. As an example Tcl's doctools format was already added. So you can render now Tcl doctools manual pages like this: `tclsh shtmlview.tcl
    shtmlview.man`

    Detlef

    Bezoar schrieb am Dienstag, 12. April 2022 um 15:55:41 UTC+2:
    On Tuesday, March 29, 2022 at 9:41:53 AM UTC-5, Gerry wrote:
    Your package looks interesting. One of these long spring evenings
    I may look into it to see how hard it would be to have it use
    entries in an SQLite database rather than files.


    Gerry Snyder
    --
    Yes if it supported loading from a buffer rather than just from a file that would be a good enhancement.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)