-
Notifications
You must be signed in to change notification settings - Fork 30
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
Turtle stamp function #84
Comments
Hi @jamesdbrock , that sounds like a cool idea! So the way the Turtle library works is by accumulating a state which describes the paths that the turtle has drawn, their styles, etc. Then at the end you can render a Turtle state into a Diagram. (Take a look at |
Ah, yes, I see that now, thanks for pointing that out. |
Maybe we could change the type of data TurtleState n = TurtleState
{ ...
, paths :: [Either (TurtlePath n) (Located (QDiagram b V2 n Any ))]
} |
Yes, that makes sense. Although there's no need to use |
Hi, thanks for this library @mgsloan , it's really great!
I want a function which enables the turtle to render any diagram at its current location, with its current orientation.
I would call this function
stamp
, like the idea of using a rubber ink stamp on paper.I think the
stamp
function should have this type signature?I'm going to try to write this
stamp
function. Do you know if anyone else has ever written it? Do you have any advice for writing it?Reference:
http://hackage.haskell.org/package/diagrams-contrib-1.4.4/docs/Diagrams-TwoD-Path-Turtle.html
Possibly related: #5
The text was updated successfully, but these errors were encountered: