Skip to content
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

svg: gray time-info subtext not aligned (a fix: -Tsvg:cairo) #103

Open
tfiers opened this issue Jan 30, 2023 · 4 comments
Open

svg: gray time-info subtext not aligned (a fix: -Tsvg:cairo) #103

tfiers opened this issue Jan 30, 2023 · 4 comments
Labels
known limitation A bug or quirk that's not core to this package's functioning

Comments

@tfiers
Copy link
Owner

tfiers commented Jan 30, 2023

After 4a5bcd7 (using html for gray subtext w/ "[$time ms]"),
noticed svg looks wonky (PNG is fine)

btw, document that :pdf works nicely too :)
(and add link to the above outputs page)
Maybe a new arg (see #-T link above): renderer (:cairo, or nothing)

@tfiers
Copy link
Owner Author

tfiers commented Jan 30, 2023

-Tsvg

-Tsvg:cairo

(and -Tpng for good measure)

@tfiers
Copy link
Owner Author

tfiers commented Jan 30, 2023

the cairo svg draws each character as a path (it does dedup: has a library of 'glyphs' (letters & numbers) at the top it reuses).

  • can you still have links? (urls: clickable nodes, i.e. svg: clickable nodes (urls to repos) #24)
  • our darkmode posprocessing don't work here no more (the svg source is all different; no separate "node" groups etc anymore)

another possible fix: more postprocessing of the svg. like in the graphviz gitlab thread: "align center and set x to center of node"

@tfiers
Copy link
Owner Author

tfiers commented Jan 30, 2023

also lol click the above svg's to open as standalone images in firefox. both are effed up.
png good old just works.

if you want both light and dark, you can, with png, btw:
(documenter too?)
https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#specifying-the-theme-an-image-is-shown-to
i.e.

<picture>
  <source media="(prefers-color-scheme: dark)" srcset="dark.png">
  <source media="(prefers-color-scheme: light)" srcset="light.png">
<picture>

(the extra (nonDRY) img attribute is for: 1) accesibility? can't picture or source have alt text? 2) backwards compat?. Is it necessary?)

@tfiers tfiers added the known limitation A bug or quirk that's not core to this package's functioning label Jan 30, 2023
@tfiers
Copy link
Owner Author

tfiers commented Feb 3, 2023

Hm maybe the edges should be gray in the above. (They're too noisy. Scaling (average of neighbour relsizes?) was first idea, but is hardee)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
known limitation A bug or quirk that's not core to this package's functioning
Projects
None yet
Development

No branches or pull requests

1 participant