Hi guys,
Just spotted a bug in RTStackBarPlot.
If you set the height of a bar with the message #barWidth:height: the width is set but the height remains 20 pixels, as defined in #defaultBarHeight.
To reproduce, go to RTStackBarPlot>>#example03 and change the height value parameter in the #barWidth:height: message. Bar always remain 20 pixels.
P.s. I also take this opportunity to say that once you get proficient in Roassal it is really a pleasure to use it!
Cheers, Roberto
Hi Roberto!
Well spotted! This is fixed.
Just for people wondering what the RTStackBarPlot is all about, here is an example:
-=-=-=-=-=-=-=-=-=-= b := RTStackBarPlot new. b interaction popupText. b colorPalette colors: (Array with: Color blue with: Color lightBlue ). b add: #(37 33 0 0 0) title: 'DN1'. b add: #(24 26 17 3 0) title: 'DN2'. b add: #(25 29 15 1 0) title: 'DN3'. b add: #(30 33 6 1 0) title: 'DN4'. b addLegend: #('strongly agree' 'agree' 'neutral' 'disagree' 'strongly disagree'). b barWidth: 260 height: 20.
b addLabelToBars: [ :assoc | (assoc key / b totalSum * 100) asInteger asString, '%' ] if: [:assoc | assoc key > 5 ] color: Color white. b -=-=-=-=-=-=-=-=-=-=
Andrei and I programmed it when Andrei needed to report result of a survey :-)
Cheers, Alexandre
On Jul 22, 2015, at 9:22 PM, roberto.minelli@usi.ch wrote:
Hi guys,
Just spotted a bug in RTStackBarPlot.
If you set the height of a bar with the message #barWidth:height: the width is set but the height remains 20 pixels, as defined in #defaultBarHeight.
To reproduce, go to RTStackBarPlot>>#example03 and change the height value parameter in the #barWidth:height: message. Bar always remain 20 pixels.
P.s. I also take this opportunity to say that once you get proficient in Roassal it is really a pleasure to use it!
Cheers, Roberto