Google Bubblechart dimension bug

First of all sorry for my English but I'm Italian.

Now... i'm working with motion chart and geochart without a problem, but bubblechart seems that have his way to do things.

I use several chart on my page, some are hidden (display:none) other not, but when i hide bubblechart his dimension change at 400x200 when i wrote on the code 900x600.

This is the code i use with other graph flawlessly:

<div style="width: 100%; clear: left; display: none" id="religioni-frame">
    <div style="width: 50%; float: left; text-align: center">
        <div id="religione-bubble" style="width: 650px; height: 360px;margin: 0 auto"></div>
    </div>
    <div style="width: 50%; float: left; text-align: center;">
        <div id="religioni" style="width: 650px; height: 360px; margin: 0 auto"></div>
    </div>
</div>

but when i use it on bubblechart everything fall apart... and i get a 400x200 stamp...

<div style="height: 900px;display: none" id="bubble-frame">
       <div id="chart_div"  style="width: 900px; height: 400px;"></div>
</div>

if i use it without display:none it takes the right dimensions.

<div style="height: 900px;display: inline" id="bubble-frame">
       <div id="chart_div"  style="width: 900px; height: 400px;"></div>
</div>

here it's a test page https://dl.dropbox.com/u/29200489/IPC/untitled/test.html Solutions?

Upvotes: 0

Views: 149

Answers (1)

liuchan
liuchan

Reputation: 26

Sorry for my english, I'm italian too..

it's better that you always specify width and height

change the "options" line of code like this

var options = {width: 500, height: 900,
colorAxis: {colors: ['yellow', 'red']}
};

et voilà

bye

liuchan

Upvotes: 1

Related Questions