I looked at that fiddle in Chrome and I don't see any issues with the pie slice text.
On Thursday, November 14, 2013 8:56:20 PM UTC-5, Edward Fung wrote: > > My pie charts also have this problem. I will post my code later > But if I go to your fiddle (http://jsfiddle.net/asgallant/6kLQj/) with > google chrome, the display problem happens. > if I switch to firefox, there is NO display problem. > I guess it is an issue with cross-browser support. > My google chrome and firefox version are "Version 31.0.1650.48 m" and "25.0" > respectively. > > > On Thursday, November 14, 2013 11:30:57 PM UTC+8, asgallant wrote: >> >> Could you post code that reproduces the problem? >> >> On Thursday, November 14, 2013 3:01:27 AM UTC-5, Edward Fung wrote: >>> >>> Sorry to revive this post. >>> But I have problem displaying your piechart in the given jsfiddle. >>> >>> >>> On Tuesday, June 25, 2013 12:38:08 AM UTC+8, asgallant wrote: >>>> >>>> I tried it out and can't duplicate the issue in any browser: >>>> http://jsfiddle.net/asgallant/6kLQj/. If the fiddle displays properly >>>> for you, check your site's CSS to make sure there isn't anything >>>> interfering with the chart. >>>> >>>> On Monday, June 24, 2013 12:01:30 PM UTC-4, Nitin Jaiswal wrote: >>>>> >>>>> Asgallant, here is the javascript: >>>>> >>>>> >>>>> <div style="float:none" id="draw_chart1"></div> >>>>> <script type="text/javascript"> >>>>> // Load the Visualization API and the piechart package. >>>>> google.load("visualization", "1", {packages:["corechart"]}); >>>>> >>>>> >>>>> // Set a callback to run when the Google Visualization API is loaded. >>>>> google.setOnLoadCallback(drawChart); >>>>> >>>>> >>>>> function drawChart() { >>>>> >>>>> >>>>> // Create our data table out of JSON data loaded from server. >>>>> var data = new >>>>> google.visualization.DataTable({"cols":[{"label":"Question","type":"string"},{"label":"Total >>>>> >>>>> Attempt","type":"number"}],"rows":[{"c":[{"v":"asd"},{"v":5}]},{"c":[{"v":"asd"},{"v":7}]},{"c":[{"v":"sdfas"},{"v":2}]}]}); >>>>> >>>>> var options = { >>>>> is3D: true, >>>>> width: 700, >>>>> height: 300, >>>>> chartArea: {width:400, height:400, left:9,top:9,bottom:0,right:0} >>>>> }; >>>>> // Instantiate and draw our chart, passing in some options. >>>>> // Do not forget to check your div ID >>>>> var chart = new >>>>> google.visualization.PieChart(document.getElementById('draw_chart1')); >>>>> chart.draw(data, options); >>>>> } >>>>> >>>>> >>>>> </script> >>>>> >>>>> >>>>> On Mon, Jun 24, 2013 at 8:12 PM, asgallant <[email protected]>wrote: >>>>> >>>>>> The PHP code doesn't help me here, can you open the page in a >>>>>> browser, view the source, and paste the javascript here? >>>>>> >>>>>> On Monday, June 24, 2013 1:06:19 AM UTC-4, [email protected] wrote: >>>>>>> >>>>>>> Hi asgallant, >>>>>>> >>>>>>> Here is my code... >>>>>>> >>>>>>> >>>>>>> <?php >>>>>>> $survey_question = "SELECT id,answer,total_attempt,questionid from >>>>>>> survey_answer where `questionid` = $ques_id AND `answer`!='' AND >>>>>>> status='1' >>>>>>> ORDER BY id ASC"; >>>>>>> $answers_result = @mysql_query($survey_question); >>>>>>> $table = array(); >>>>>>> $table['cols'] = array( >>>>>>> array('label' => 'Question', 'type' => 'string'), >>>>>>> array('label' => 'Total Attempt', 'type' => 'number') >>>>>>> ); >>>>>>> $rows = array(); >>>>>>> while($r = mysql_fetch_assoc($answers_result)) { >>>>>>> //print_r($r); >>>>>>> $temp = array(); >>>>>>> $temp[] = array('v' => (string) $r['answer']); // you will >>>>>>> probably need to transform this into the Date object format >>>>>>> $temp[] = array('v' => (int) $r['total_attempt']); // typecast to >>>>>>> int, float, whatever - if you don't, it will be interpreted as a string >>>>>>> $rows[] = array('c' => $temp); >>>>>>> } >>>>>>> $table['rows'] = $rows; >>>>>>> $jsonData = json_encode($table); >>>>>>> //echo $jsonData; >>>>>>> ?> >>>>>>> <div id="draw_chart<?php echo $questio_print ?>"></div> >>>>>>> <script type="text/javascript"> >>>>>>> // Load the Visualization API and the piechart package. >>>>>>> google.load("visualization", "1", {packages:["corechart"]}); >>>>>>> // Set a callback to run when the Google Visualization API is >>>>>>> loaded. >>>>>>> google.setOnLoadCallback(drawChart); >>>>>>> function drawChart() { >>>>>>> >>>>>>> // Create our data table out of JSON data loaded from server. >>>>>>> var data = new google.visualization.DataTable(<?php echo >>>>>>> $jsonData ?>); >>>>>>> var options = { >>>>>>> is3D: true, >>>>>>> width: 900, >>>>>>> height: 300 >>>>>>> }; >>>>>>> // Instantiate and draw our chart, passing in some options. >>>>>>> // Do not forget to check your div ID >>>>>>> var chart = new google.visualization.PieChart( >>>>>>> document.getElementById('draw_chart<?php echo $questio_print ?>')); >>>>>>> chart.draw(data, options); >>>>>>> } >>>>>>> </script> >>>>>>> >>>>>>> >>>>>>> >>>>>>> On Friday, June 21, 2013 9:10:17 PM UTC+5:30, asgallant wrote: >>>>>>>> >>>>>>>> You can't adjust the placement of the text. If you post code that >>>>>>>> replicates the problem, I'll take a look and see if there are any >>>>>>>> tricks I >>>>>>>> can come up with to end-route the problem. >>>>>>>> >>>>>>>> On Friday, June 21, 2013 3:25:50 AM UTC-4, [email protected]: >>>>>>>>> >>>>>>>>> Hello there, >>>>>>>>> >>>>>>>>> I am facing a very strange problem that the text inside slice is >>>>>>>>> going half outside the slice. >>>>>>>>> >>>>>>>>> Please help me in adjusting the text. >>>>>>>>> >>>>>>>>> Screenshot attached. >>>>>>>>> >>>>>>>>> <https://lh3.googleusercontent.com/-HwsVI5HZToQ/UcP_2AU_-AI/AAAAAAAAAAM/jIvyLv-PTL4/s1600/51c3fc98d535cfc546000016.jpeg> >>>>>>>>> >>>>>>>>> -- >>>>>> You received this message because you are subscribed to a topic in >>>>>> the Google Groups "Google Visualization API" group. >>>>>> To unsubscribe from this topic, visit >>>>>> https://groups.google.com/d/topic/google-visualization-api/buKfiCbALRU/unsubscribe >>>>>> . >>>>>> To unsubscribe from this group and all its topics, send an email to >>>>>> [email protected]. >>>>>> To post to this group, send email to [email protected] >>>>>> . >>>>>> Visit this group at >>>>>> http://groups.google.com/group/google-visualization-api. >>>>>> For more options, visit https://groups.google.com/groups/opt_out. >>>>>> >>>>>> >>>>>> >>>>> >>>>> -- You received this message because you are subscribed to the Google Groups "Google Visualization API" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/google-visualization-api. For more options, visit https://groups.google.com/groups/opt_out.
