Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
california-og
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
9 ms
·
61.
▲
by
california-og
2y ago
For whitespace and for the simplest ASCII sure, but for anything a bit more complex you might have problems with 1. HTML reserved characters like < > and \. 2. overflowing content 3. displaying ASCII made with special encodings and ch
62.
▲
by
california-og
2y ago
It's not trivial to display ASCII art as text in html. There's so many ways to mess it up that unless the site is dedicated to ASCII art, a simple image is really preferable.
63.
▲
by
california-og
2y ago
I wish the article mentioned Computer Nude (1967) by Ken Knowlton. It isn't ASCII, but it is a text mosaic. It was widely circulated at the time, was the first full frontal nude printed in The New York Times, and was somewhat important
64.
▲
by
california-og
2y ago
It's JavaScript for the interactive/reactive parts, but the notebook is implemented in a self-contained HTML file: it handles everything from document structure to editing and display. It's also not dependant on 3rd party sof
65.
▲
Reactive HTML Notebooks
(maxbo.me)
361 points
by
california-og
2y ago
|
54 comments
66.
▲
by
california-og
2y ago
Also: https://www.programmingfonts.org/
67.
▲
by
california-og
2y ago
Thanks for sharing! This was a great read.
68.
▲
by
california-og
2y ago
There's a lot of sites between pure html and modern css. "Simply" rendering things differently would definitely break a lot of sites. Just imagine if browsers started defaulting to *{box-sizing: border-box;}.
69.
▲
by
california-og
2y ago
Your solution is quite nice and probably as simple as site generators get, but I was thinking of using php just for some simple includes etc. Here's my inspiration post which explains what I'm after, and why generators in general
70.
▲
by
california-og
2y ago
I am using 11ty for the blog, and it works great, for now. But there's two reasons I don't like it: 1. I need to have two different versions of my site, dev and prod, which I find very restricting and fragile. 2. I don't like
71.
▲
by
california-og
2y ago
That's genius, thank you!! I will have to try that tomorrow but I have a feeling it might just work : - )
72.
▲
by
california-og
2y ago
There's this article on using css highlights for syntax highlighting: https://frontendmasters.com/blog/syntax-highlighting-with-no...
73.
▲
by
california-og
2y ago
I have been considering using php like that. It would solve most of my issues. The problem is that I would still like to use static hosts, like netlify or GitHub pages, and they don't support php...In addition I would have to run php o
74.
▲
by
california-og
2y ago
Very nice! Simple but effective. Thanks for sharing.
75.
▲
by
california-og
2y ago
(author) The problem is that the opentype "language" doesn't have loops or anything resembling regular expressions, where I could just tell it to sub everything between two characters. So, I could highlight text between quote
76.
▲
by
california-og
2y ago
(author) Because then you're not adding syntax highlighting to the textarea, but to the div... I've done this before and it's janky, with many edge cases that require extra css fiddling. It's just not great. I would rath
77.
▲
by
california-og
2y ago
(Author) Sure, it depends on your requirements, what you want your syntax highlighter to do. I wouldn't use it as my coding font (in its current form at least). But just because a few words inside regular text could be highlighted, doe
78.
▲
by
california-og
2y ago
(Author) For specific keywords, yes, technically you could, but it would require making a separate glyph for each word, which would inflate the file size and require a lot of manual effort for no apparent upside. The substituting logic is a
79.
▲
by
california-og
2y ago
You are probably right, but I would like to see some actual benchmarks and tests. Unfortunately I didn't have time to do them myself yet, but I am curious what the difference between this, a basic font, and a highlighter script would b
80.
▲
by
california-og
2y ago
And about the lookup rules: they are extremely simple. You can search for a single character at a time, or search from a group ("class") of characters. AFAIK, that's it. But if anyone knows better, I would be happy to be prov
81.
▲
by
california-og
2y ago
I was informed that the color palette can be changed with `override-colors` css rule, but havent had time to update the blog post yet.
82.
▲
by
california-og
2y ago
Ah, I think I meant to write that the site doesn't load anything from third parties, but apparently had a slight brain fart.
83.
▲
by
california-og
2y ago
Yeah. Doing it all manually would take ages and be quite error prone. I did generate all the lookup rules with a script, just didn't think it important enough to mention in the blog post.
84.
▲
by
california-og
2y ago
Definitely! For example, Glyphs has a decent python scripting API which could be used to automate the whole process. I used it for automatically assigning each layer the correct color attribute to save me some clicks. And I also generated a
85.
▲
by
california-og
2y ago
Thank you! (I'm the author) I'm also very curious to know if there's some nifty way of improving the lookup logic. What I did was kind of a brute force method, but on the other hand, the CALT "language" is very limi
86.
▲
Font with Built-In Syntax Highlighting
(blog.glyphdrawing.club)
1 points
by
california-og
2y ago
|
0 comments
87.
▲
by
california-og
2y ago
ASCII just refers to the 7bit standard, so if we are pedantic ASCII art is just art using the printable characters of the 128 code points defined in it. Font size doesn't have anything to do with it. But ASCII art is used as an umbrell
88.
▲
by
california-og
2y ago
While DEL didn't stamp a black square on typewriters, it sometimes did so (or something similar, like diagonal stripes) in various digital character sets. ISO 2047[0] established the graphical representations for the control characters
89.
▲
A GIF animation loop, 2015, Duration 1k years
(aslongaspossible.com)
12 points
by
california-og
2y ago
|
2 comments
90.
▲
by
california-og
2y ago
For me HSL is not intuitive at all. I always struggle to remember what hue of each colour is. I would even say that rgb is still the most intuitive for picking a particular color hue, but of course HSL or the newer ones like oklch are much
More ›