-
Notifications
You must be signed in to change notification settings - Fork 10
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 a plot component to the Radial theme #12
Conversation
85dd715
to
37dd3d3
Compare
Message to reviewers: review #13 before reviewing this. |
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.
It looks pretty clean and is easy to use
|
||
plot.plot( | ||
name: "plot", | ||
plot-style: plot-style, |
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.
not a huge issue, but as it is I don't really think the stoke used in the grid looks good. It creates a lot of weird overlaps and looks a little messy, if possible could you change it to something like this:
stroke: (dash: none, thickness: .2pt, paint: black)
(This is the same grid style I used in the gantt chart, maybe we should use some sort of consistent grid style for charts)
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.
Alright, I'll look into it.
themes/radial/components/graphs.typ
Outdated
#let plot( | ||
title: "", | ||
x-label: "", | ||
y-label: "", |
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.
maybe add a way to change the variables so it's not always x and y, but just have it so those are defaults? like if I'm plotting a velocity time graph, it would make sense to have v and t axis
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.
The API is meant to be as simple as possible. If people want something more advanced they can just use the underlying library.
(also I have no idea how to do this)
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.
Everything looks good to me, I like changing the directions to north, south, east, and west
import cetz.palette | ||
|
||
// Style for the data lines | ||
let plot-colors = (blue, red, green, yellow, pink, orange) |
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.
Boo no rainbow order
let plot-colors = (red, orange, yellow, green, blue, pink)
Summary
This feature adds a basic wrapper around Cetz's plotting library with a relatively simple API.
Checklist