Fork me on GitHub
#beginners
<
2015-08-06
>
meow02:08:47

@einherjar: I'm pretty sure you will be safe with all 3 forms. Certainly the last two. The first will work and I believe based on what I've learned from @dnolen that the first form is likely to be supported by cljs indefinitely.

dnolen02:08:16

@einherjar: aget for this use case is discouraged over goog.object/get

meow02:08:04

I was ignoring the aget issue as I wasn't sure what js/e.target.files was returning.

meow02:08:03

If it doesn't return an array, don't use aget.

dnolen03:08:31

@meow: oops good catch

einherjar12:08:25

Thanks @meow 1 and 3 are easier for me to read, so I’ll use one of them. This does return an array, its the HTML5 file input event. @dnolen: I have a sticky note on my desk about

goog.object/get
vs
aget
so that I don’t accidentally use
aget
on objects. I’ve been trying to keep track of advice/warnings you give in the ClojureScript channel even though most of it is over my head right now.

arathunku15:08:47

There're only 9 people in "incanter" room so I'll try my luck here... incanter/jcharts problem. I'm trying to change color of histogram's data series but it doesn't do anything.

(let [plot (histogram (sample-normal 20))
        render (-> plot .getPlot .getRenderer)]
    (add-histogram plot (sample-normal 20))
    ; changes colors of the outline
    (.setSeriesOutlinePaint render 1 java.awt.Color/BLUE)
    
    ;  nothing, fill paint remains unchanged. ???????
    (.setSeriesFillPaint render 1 java.awt.Color/BLUE)    
    (view plot))