Quantcast
Channel: Appcelerator Developer Center Q&A Unanswered Questions 20
Viewing all articles
Browse latest Browse all 8068

Can't display a chart on a webview canvas only on sony devices

$
0
0

Hi,

I am using SmoothieCharts to draw a graph on a canvas : http://smoothiecharts.org/.

It works very fine on my devices (Samsung, noname, etc.).

Yet on Sony devices, two users reported that it the canvas was totally blank on their Sony C5303, under Android 4.3.

![blank canvas](https://lh3.googleusercontent.com/-YO28mVRF-Ds/VNfHDcIGKlI/AAAAAAAAADU/A6EM0LJMPF4/s320/nogrid.png "Blank canvas")

I can't make the problem appear on my emulator with Android 4.3.

The application also contains a web link, with the same chart on the web and here it works on the same device...

![Working chart](https://lh5.googleusercontent.com/--RDOnPG0K00/VNfHbjVj-YI/AAAAAAAAADc/0-2HGRtAACE/s1600/expected.png "Working chart")

function dessinerCourbe() {
 
                var courbe = new TimeSeries();
 
                var smoothie = new SmoothieChart({
                    minValue : 0,
                    maxValue : 100,
                    grid : {
                        strokeStyle : 'rgb(125, 0, 0)',
                        fillStyle : 'rgb(60, 0, 0)',
                        lineWidth : 1,
                        millisPerLine : 250,
                        verticalSections : 6
                    }
                });
                smoothie.addTimeSeries(courbe, {
                    strokeStyle : 'rgb(0, 255, 0)',
                    fillStyle : 'rgba(0, 255, 0, 0.4)',
                    lineWidth : 3
                });
                smoothie.streamTo(document.getElementById("graphe"), 1000);
 
                setInterval(function() {
                    courbe.append(new Date().getTime(), getGrapheOrdonne());
                }, 1000);
 
                // Add to SmoothieChart
                smoothie.addTimeSeries(courbe);
            }
        </script>
<canvas id="graphe" width="300" height="200"> </canvas>

I know it's a long shot but I am still asking in case anyone has an idea about where to look for the problem. Any help would be welcomed :)


Viewing all articles
Browse latest Browse all 8068

Trending Articles