Skip to content

Instantly share code, notes, and snippets.

@uehaj
Created September 27, 2014 14:49
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
import Window
thickLine = { defaultLine | width <- 20 }
roundLine = { thickLine | cap <- Round }
smoothLine = { thickLine | join <- Clipped, cap <-Round }
main = let
disp w h = collage w h
[ move (-100,250) <| outlined thickLine <| ngon 5 100
, move (-100,250) <| outlined thickLine <| polygon [(200, 0),(250,100),(150,100)]
, move (-100,0) <| outlined roundLine <| ngon 5 100
, move (-100,0) <| outlined roundLine <| polygon [(200, 0),(250,100),(150,100)]
, move (-100,-250) <| outlined smoothLine <| ngon 5 100
, move (-100,-250) <| outlined smoothLine <| polygon [(200, 0),(250,100),(150,100)]
]
in disp <~ Window.width ~ Window.height
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment