Skip to content

SVG related #2

Description

@MasterInQuestion

    The "Counting.png" (pre-rendered "Counting.htm") is so notoriously large (~ 1.33 MiB):
    [ Did some palette optimization (merge similar colors and limit color space): <&>now ~ 647.17 KiB</&>. [1] ]
    Why not consider have it converted to SVG?

    Did considered, but to no avail.
    In brief, current SVG definition has broken support for text type contents:
    Primarily, it's missing support for content of non-fixed (undetermined) size (i.e. no wrapping and overflow handling): which is typically the case for texts.
    .
    It also lacks support for many CSS properties: which makes table rendering a bit bothersome.

    Of course, vectorizing the PNG is also an option.
    I'm just not interested to bother.
[ ^
    Caveat of doing it wrong alike:
    https://en.wiktionary.org/wiki/File:emphasis-typography-outline.svg (259 KB?!)
    .
    So boldly bloated... boldface so brazen.

    Rasterized the same image at 10x its nominal size and with WebP Lossless "-z 9":
    Output ~ 224.81 KiB @ 2780x3460; boldly big enough for even very bold usage.
    (zoom level already exceeded that most browsers would support)

    The original SVG after Brotli best compression gave ~ 25.185 KiB though.
    (GZip original by Wikimedia ~ 50.769 KiB)
    [ ^ Transport-level compression. ] ]


=== Further reading ===

    SVG doesn't seem to be well-designed to be used in Plain Text:
    Cannot be properly parsed without uttering that verbose (and much meaningless) `xmlns="http://www.w3.org/2000/svg"`...

    And the very dumbfounding "d" graphic path definition...

    See also:
    https://github.com/MasterInQuestion/talk/discussions/15#discussion-6022492 ("SVG")

[ [1]
    Did further optimization using WebP: finally ~ 278.18 KiB.
    More details: https://github.com/MasterInQuestion/attach/commit/401c58fc3a56d265feadda567f02d79de93ff10c#Counting ]

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions