Many years ago working on natural language to SQL, when we had ambiguities this is how we’d clarify things with the user (albeit with the minimal amount of brackets necessary).
I’m sure somebody posted a link to E-Prime here recently (a form of English where all forms of ‘to be’ are forbidden) and this conversation is a wonderful example of the kinds of conflicts that it helps avoid.
Do you intend to one day support all the paged media bits in pagedjs? I assume it works with their polyfill but it’d be great to have a built in more performant option.
Can you give an example? I'm not that familiar with pagedjs, just pulled it for the benchmark.
My library has support for @page rules, but that's actually pretty basic. I needed more advanced headers/footers and added support for in-html headers/footers like this:
In your <body> you cna define headers/footers by wrapping content in a <section> tag. For example:
<body>
<section>
<header>... any HTML here, full CSS support</header>
<div> Some normal flow content</div>
<footer>Your footer HTML</footer>
</section>
</body>
This structure is purely optional, but it's a really convinient way of designing pages with different styles in the same document.
An HTML file can have any number of these sections meaning you can generate a PDF with different headers/footers.
Some other bits: It has support for 100% height that match the entire page, it can handle forced page breaks inside flexbox containers (Chrome doesn't even try ... just ignores it) and also follows page-break: avoid correctly - so it doesn't randomly split table rows for example.
Things like string-set and string (repeating section headers on each page), counter and target-counter (embedding page number references) etc. Prince and pagedjs support all the CSS3 paged media bits I've found myself needing, just wondering if that was on the roadmap.
Left usenet, left IRC, left LiveJournal, skipped MySpace, left Facebook, left the blogosphere, will leave Twitter and BlueSky. You’re either in touching distance of grass or you’re not, none of this matters.
This is one of those things that I’m glad remains highly personal and stochastic. Programming languages thrive when people are able and willing to create value with them. People thrive when there are options and they can find a language that sings to them.
I'd love some version of these tools that could reliably round-trip pure text. Some heuristic or model that can actually recognise boxes, lines with anchors, parent-child relationships etc, so you can paste in pure text and immediately start rearranging stuff. My experience with Monodraw was that you had to maintain the original file format to do this, so once a diagram was in a markdown file or whatever, you couldn't just cut and paste it and easily edit it. At that point it might as well be any file format rendered as an image.
You need to find the monospace whitespace characters (seems there's a few [0]). Then encode a compressed version of the logical diagram in the white space, steganography style.
Or do something with characters [1] to compress a lot of data into a tiny ball of hair at the end.
Draw.io smuggles the XML in a PNG which I've always admired.
reply