-
-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add new SVG-based screencast #693
Conversation
It seems that the emojis are not aligned well in the screencast. Are you using a monospaced font? |
22a4938
to
61d920d
Compare
Yeah that's true; noticed that as well. I do use a monospaced font (Monaco). Strangely enough it is properly aligned when I don't run it through svg-term. I could change the font, but I kinda like the style... |
This is taken from https://github.com/sharkdp/fd, so all credits go to the original authors. The demo was a bit dated. We've since added more features and changed the output. On top of that, the gif was a bit blurry. The new version is in SVG and the commands can be scripted, so we can change them with a PR and render them through CI.
So under the hood it uses svg-term with the following default font: It's possible that some codepoints are not available in Monaco so it uses one of the fallback font which somehow is not true monospaced (yes this is very common). The culprit is very likely to be the bitmapped font, which is by definition not true monospaced. |
This is very cool, I didn't know you could animate SVG like this 😀 On the topic of font/emoji, are you talking about the report lines with the symbols on the left? I haven't gotten around to fixing fonts on my system, where emojis/symbols by default only sometimes render correctly. Is that affecting the render here or do you both see the same? Something like this project might resolve that by embedding the necessary glyphs. |
Yes
It works for me locally.
Sounds interesting, I'll have a look. |
Not really worth time fixing the minor issue of emojis... |
BTW, if we want consistent style for emojis, a good start is https://gitlab.gnome.org/World/design/icon-library They are all available in Cantarell font (available in Gnome and Google Fonts but notably not present by default in Ubuntu). |
Yes, if you have a font with the correct graphemes/glyphs it should display those. Sometimes depending on the app, fallback font searching logic isn't as extensive that you still get those rectangles, which is what happens for me on Chrome I think. Firefox maintains it's own browser emoji font and has better fallback logic than Chrome (although that recently changed in latest release I think). I am on an ArchLinux based distro though which I am aware of not having a good font config out of the box for this issue, I resolved it once on another system.
❤️
Just requires embedding the font. Or expecting everyone to have no rendering issues on their end. For my system until I mess with font config, it's a common issue. Even on github if someone uses 👍 but with a skin tone variation it just shows as two vertical rectangles next to each other (similar to the screenshot). I get a similar issue on Android phone which no longer receives updates for new emoji if someone tries to send those in a message. |
I'm aware of the proposed fix of embedding the font, but it really doesn't worth it. We move from .gif to .svg based screencast for its lightweights and embedding a font just defeat this purpose... |
That would be the opposite of reducing file size? Investigation
Font glyphs for Summary output:Additional context for viewers like me where the glyph may not render:
There was one other font listed on the system which supports the emoji assigned to "Total", "Redirects", and "Unknown". That font was Subsetting a font to extract only the symbols/emoji needed for an embedI downloaded the new monochrome emoji font by Google and extracted $ docker run --rm -it -v "/tmp/font-subset:/app" talentplatforms/glyphhanger --whitelist="📝🔍✅⏳🔀👻❓🚫" --subset="/app/NotoEmoji-Regular.ttf"
U+23F3,U+2705,U+2753,U+1F47B,U+1F4DD,U+1F500,U+1F50D,U+1F6AB
Subsetting /app/NotoEmoji-Regular.ttf to NotoEmoji-Regular-subset.ttf (was 848.25 KB, now 4.27 KB)
Subsetting /app/NotoEmoji-Regular.ttf to NotoEmoji-Regular-subset.zopfli.woff (was 848.25 KB, now 3.36 KB)
Subsetting /app/NotoEmoji-Regular.ttf to NotoEmoji-Regular-subset.woff2 (was 848.25 KB, now 2.76 KB) The font does not compress further as woff is already an optimal compressed format. You can get the base64 encoded version with required CSS from this online tool, or just reference that for the CSS and generate base64 in the CLI (using $ base64 -w 0 /tmp/font-subset/NotoEmoji-Regular-subset.woff2
d09GMgABAAAAAAsMAA8AAAAAESQAAAqzAAEAgwAAAAAAAAAAAAAAAAAAAAAAAAAAHCAGYD9TVEFUHACBRBEICpgolFMBNgIkAxYLFAAEIAWDFgcgFyQYFBs4DqOifnFSMJK/SMg2S3DvmUTRWxZzRsAlhV/3CElmD2ib94QBiKgoKVbiFHVWIGISUto4BbMGK2OJW6vLKsJYZCrodNweIR2o2i7EfwPmTVhNAwSi+9/vV30XfZh11RJIjdBI8+R87jCIaRP1RqkQkolG08TulrJpQ+rrSrYbSysQ641leOXbu3UUQAAAB0xgAZKUnCEFC8AAAIyAszQG54nMBSwANhi7GABhhRdAm0CNsiVYY1EIGkFhBk4oaG+HO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cVAkVJeFdQQtUQ7EZg0CBXWJUQuGEfNFAG4lu2LjlxrtzliQfDjZdggVrU2B3be0iTQGq6UWhwfEXcw+6IAYhHYkAE9rhDtyxlI8GwXmjshGMDgA= The final CSS embed then becomes: <style>
@font-face {
font-family: "Noto Emoji";
src: url(data:font/woff2;base64,d09GMgABAAAAAAsMAA8AAAAAESQAAAqzAAEAgwAAAAAAAAAAAAAAAAAAAAAAAAAAHCAGYD9TVEFUHACBRBEICpgolFMBNgIkAxYLFAAEIAWDFgcgFyQYFBs4DqOifnFSMJK/SMg2S3DvmUTRWxZzRsAlhV/3CElmD2ib94QBiKgoKVbiFHVWIGISUto4BbMGK2OJW6vLKsJYZCrodNweIR2o2i7EfwPmTVhNAwSi+9/vV30XfZh11RJIjdBI8+R87jCIaRP1RqkQkolG08TulrJpQ+rrSrYbSysQ641leOXbu3UUQAAAB0xgAZKUnCEFC8AAAIyAszQG54nMBSwANhi7GABhhRdAm0CNsiVYY1EIGkFhBk4oaG+HOflCIR/i3b6OmFcPEwpIRL4pXQZBioQCZ7AEZCKLnGgyOB5RbWXlzQiIGBDREOIeR2kmRAITDltgIBAtpuooALevXlgvyfA1sRL3iP3/+3fBVEoEwuoJoJJXfREQcCoWAWXsJfEAaEC+jUsAwDDdxx4BsIB8hwQAM0dW2COAOSA/thJMzgEZgU+WIWaLoxoBNwz7CKZKAEfUBGRhDZgiaAaTTCKltdKcSb50BtsV50Bg2VmyHGhMW48gKhFjknB4BzKdjLG1JZPxAbSRyTSEsCPyhtHI6TaZTAq9XnpoGxgwyEp1RmPkhiXIw8MNj/F5qpAieLDI/ZBeL9cZjUYEk8mEj8FgAHq9vrZrSOFsHER354AM9P0wBuWIaeioZL/U1TCAmia1t3g4/djqnnL9tClcpetst8OE33AozIubbu64nQhGnJe8x+au4Op6QCtYbhhn6j2/uygFfOulhA7TU/w953pFPaLzdc1DUNl0Gt2TJ4PyTdf0OPPSe+1NQ89K5LFhAHBYGxhka2rtvuvGWGsKW3IE5zV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Pn64eWTC/ZpiThmvmp5nXjMwXRs52pMbjNN2rPami4FB6+mIiMZRI+vBBsDQ32rn26HgrayXRboay84ly61blk86OBQAKTk0z7Oi894+VZ+p5Lu5p0y7udZLE86Y/e67mB0cXFEYF89QvXqiTOdFFhdEcoeNCLdMdnr144MncoGG6oZ48h6wNy63JVuSog9rzXTjrBBuHrQsimi+AOH7kfE6PmVlPzvnzPdlm5gBoCCwAwFjnpMaxq1ms1WONRgBAhxtNbRRcYXRVfJKCN2tF4BDiT9xFXfm9tMg6+rtFWwC2u28ILYMdPNCOPQjWw1oczWwYACwABVR/5eE4b4MI1qrZ2MlHoV9BOcZAtSMY1AVECg84Ar4vP4cAgKXlThiDTAc7oIBRuklXAxoatFSbSgAnBMhQ6YQCIkx0QkM4zHTCgDucc8ICHV45moErgroWBICAuAMX6qAeNNAIFVAG5dAMzsCBQAiCYPCPIyeDIN+MdTaLalAVTYVaKIEAYMIhqw7LaoSaUlDFBSpohNaEpWYU/ADXrC6BBzWcVAkVJeFdQQtUQ7EZg0CBXWJUQuGEfNFAG4lu2LjlxrtzliQfDjZdggVrU2B3be0iTQGq6UWhwfEXcw+6IAYhHYkAE9rhDtyxlI8GwXmjshGMDgA=);
}
</style> That can be included in the existing Delivery size comparisonWhen taking gzip encoding into account (which github will use for delivery):
I would argue that is still acceptable, a 90% reduction in size remains compared to the GIF asset. Final resultsThis results in everyone seeing this (you could change the font if you want to use different emoji of course): |
That's a pretty decent analysis. But why the emojis are still not aligned? If they are from the same monospaced font set they should have same width..... |
Previous responseI don't think that font is monospace? It may be intended to be used with non-monospace fonts. Do you have one without that issue? It's a common issue AFAIK. It may be possible that when the emoji font supports the VariationSelector modifer (allows for explicitly hinting monochrome or colour when variations are available), as this page notes. Alternatively, you can open the subsetted font in a font editor GUI and manually ensure a common width for all glyphs. There is non-standard usage as well in fonts patched with Powerline or NerdFonts glyphs which use the unicode PUA (Private User Area), that is non-standard though - thus should not be expected to render the correct glyph if any unless the user has the font (or you embed it). This approach is common for terminal fonts to add symbols with. UPDATE: Inspected the glyphs with the crossplatform font GUI editor BirdFont (open-source). Everything looked fine there, so they are correctly monospace 😅 I went back into the browser and messed around with the generated SVG and CSS to inspect further. There was two different x axis offsets used. Perhaps due to whatever the tooling detected when generating the SVG?: If setting them all to |
Aha! So that might be something that we could report to svgterm. Maybe it's expected behavior or maybe there's a setting somewhere to fix that. If not we can always use sed in our script and add a comment about this discussion. |
honestly we can see that it's not really monospaced... every emoji is twice as wide as the hyphen characters below the "summary".... |
The project doesn't look like it's maintained anymore? So reporting probably wouldn't accomplish much 😅
Yeah I was thinking the same.
I want to generate the SVG myself to reproduce the alignment issue. It seems that currently with this PR you are intending to run the generation script locally, then apply the Looks like we could possibly automate the generation with Docker, if I get that sorted would you like to update the
@lebensterben Well, one part of the issue is the SVG placement had two different offsets which caused the misalignment. I'm not sure if that was from the generation of the cast, or the project that converts the cast to SVG. It may be based on what font it used to calculate width for that caused that variation? I've read that emoji are generally meant to be a square ratio, for monospace fonts about two widths. Each glyph in the font editor showed it horizontally centered: The GUI app used doesn't seem to provide a width measurement, so I assume they're all the same (different levels of zoom in the screenshots, the UI is not pleasant to work with). Anyway, as noted in my prior message, this is a non-issue for us, the SVG graphic for each has an |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reproduced the rendering issue with the following:
docker run --rm -it -v "/tmp/svg:/tmp/svg" alpine ash
# Testing with the current lychee release
apk add cargo openssl-dev node asciinema pv git
cargo install lychee
export PATH="/root/.cargo/bin:${PATH}"
# Testing against the current lychee repo (note TEST.html change in this PR needs to be applied):
mkdir -p /tmp/lychee && cd /tmp/lychee
git clone https://github.com/lycheeverse/lychee .
npm install -g svg-term-cli
# Generate the SVG:
svg-term --command 'assets/screencast.sh' --out '/tmp/svg/screencast.svg' --width 100 --padding 10 --window
# Apply fixes here
Providing the And in my local terminal, it's correct (except the 3 glyphs that are using a different font due to the system choosing that one first as higher priority until I adjust that manually): I have looked through the source of the Somewhere There is an alternative project that does render correctly (and much faster and notably more memory efficient), They also had the rendering issue, but it was resolved. That similarly required embedding the font and adding it to the It will need some additional work to add in the padding, and if you want the window frame that
Regarding feasibility for CI, you'd not get reliable diffs due to the command script having a random delay method which doesn't use a seed for deterministic / repeatable sequence of "random" delays. So you'd still want to manually generate for updates when you know the output has changed. |
Co-authored-by: Brennan Kinney <[email protected]>
Co-authored-by: Brennan Kinney <[email protected]>
Thanks @polarathene for your thorough analysis.
Agreed.
Can you list the tweaks here for documentation? I'm assuming you meant the following:
We should add these dependencies to the documentation or, even better, to a Github action that renders the SVG demo. We can do that at a later point in time, though. Come to think of it, we could even wrap all of that work into a separate Github action for SVG-based demos. It would take a script with commands as an input and render an SVG from it. That's just an idea if someone is looking for a fun hobby project. 😛
We could make it deterministic by hardcoding the delays. I don't think that anyone would necessarily care or even notice. @polarathene, @lebensterben, what do you think about merging this PR as is? We could move |
I would have to read over what I said here, and if I missed anything there's a chance I documented it elsewhere before I had a powercut take out my WIP containers and If not then I can probably recall by going through the process again. I think there was some CSS edits which I'm hoping I saved (I recall porting over the theme colours, and maybe something else..). I also remember I was wanting to provide a Dockerfile for easy reproduction of the cast and SVG. But yes all three of those things were necessary too.
That'd be pretty cool, and not require the Dockerfile in this project :)
Sure. I had made a little utility that rounded the timestamps from the asciicast recording to a specific framerate. Updates aren't that important since it's just content, the diff for SVG updates could just be ignored with
Yeah that's fine. I did want to resolve the improvements here, but due to the data loss event and a busy month that'll have to come later. I should have time later this month or next to make a contribution 👍 |
We can merge this PR. |
This is taken from https://github.com/sharkdp/fd, so all credits
go to the original authors.
The demo was a bit dated. We've since added more features and
changed the output. On top of that, the gif was a bit blurry.
The new version is in SVG and the commands can be scripted, so
we can change them with a PR and render them through CI.