 
 (defn draw-primitives [g2d items]
   (enable-anti-aliasing g2d)
-  (dorun
-    (for [item (flatten items)]
-      (let [params (:params item)]
-      (set-style g2d params)
-      (draw-primitive g2d (:type item) (complete-coordinates params))))))
+  (doseq [[type params inner] items]
+    (println type params inner)
+    (set-style g2d params)
+    (draw-primitive g2d type (complete-coordinates params))
+    ))
 
 (defn paint-canvas-graphics [^Graphics graphics data]
   (draw-primitives graphics data))


;; test

(def temp-data
  [
   {:type :primitive-round-rect
    :params {:l 20 :t 10 :w 140 :h 140
             :arc-radius 20
             :filled true :color Color/RED}}
   {:type :primitive-ellipse
    :params {:l 25 :t 15 :w 110 :h 90
             :filled true :color Color/YELLOW}}
   {:type :primitive-round-rect
    :params {:x 90 :y 80 :r 160 :b 150
             :arc-width 20 :arc-height 20
             :filled false :color Color/DARK_GRAY
             :stroke {:width 5
                      :dashes [10 10]}}}
   {:type :primitive-polygon
    :params {:vertices [{:x 100 :y 100}
                        {:x 50 :y 150}
                        {:x 50 :y 220}
                        {:x 160 :y 250}]

                      :dashes [20 3 10 3 5 3]
                      :cap :butt
                      :join :bevel
                      :miter-limit 10.0}}]
   [:primitive-text
    {:x 180 :y 120 :text "TEST"
             :color Color/BLUE
             :alpha 0.5
             :font {:name "Arial"
