Add color! macro

This commit is contained in:
oakes
2014-04-08 22:07:01 -04:00
parent 6a0ed22b1e
commit b5e44dae65
2 changed files with 7 additions and 1 deletions

View File

@@ -35,7 +35,8 @@
"catmull-rom-spline!" :methods}
"Circle" {"circle" :methods
"circle!" :methods}
"Color" {"color" :static-fields}
"Color" {"color" :static-fields
"color!" :methods}
"ColorAttribute" {"attribute :color" :constructors
"attribute-type :color" :static-fields
"attribute! :color" :static-methods}

View File

@@ -25,6 +25,11 @@
(u/key->upper (first args))))
`(Color. ~@args)))
(defmacro color!
"Calls a single method on a `color`."
[object k & options]
`(u/call! ^Color ~object ~k ~@options))
; interop
(defmacro app!