当前位置: 首页>>代码示例>>PHP>>正文


PHP PiePlot::ShowBorder方法代码示例

本文整理汇总了PHP中PiePlot::ShowBorder方法的典型用法代码示例。如果您正苦于以下问题:PHP PiePlot::ShowBorder方法的具体用法?PHP PiePlot::ShowBorder怎么用?PHP PiePlot::ShowBorder使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PiePlot的用法示例。


在下文中一共展示了PiePlot::ShowBorder方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: createPlot

 public function createPlot()
 {
     $size = '0.25';
     $plot = new \PiePlot($this->data);
     $plot->SetLegends($this->legends);
     $plot->SetSize($size);
     $plot->SetCenter(0.25, 0.32);
     $plot->ShowBorder();
     $plot->SetColor('black');
     $this->grafico->add($plot);
 }
开发者ID:evandrolacerda,项目名称:caps_laravel,代码行数:11,代码来源:GraficoPizza.php

示例2: PieGraph

<?php

require '../include/core/common.php';
include '../include/jpgraph/jpgraph.php';
include '../include/jpgraph/jpgraph_pie.php';
unset($data);
for ($i = 1; $i <= SURVEY_MAX_ALTERNATIVES; $i++) {
    if (isset($_GET['alt_' . $i])) {
        $data[$i] = $_GET['alt_' . $i];
    }
}
if (count($data) == 0 && is_numeric($_GET['poll_id'])) {
    $poll = poll_fetch(array('id' => $_GET['poll_id']));
    for ($i = 1; $i <= SURVEY_MAX_ALTERNATIVES; $i++) {
        if (strlen($poll[0]['alt_' . $i]) > 0) {
            $data[$i] = $poll[0]['alt_' . $i . '_votes'];
        }
    }
}
$graph = new PieGraph(190, 160);
$graph->SetAntiAliasing();
$graph->SetShadow();
$p1 = new PiePlot($data);
$p1->ShowBorder();
$graph->SetFrame(false, 'darkblue', 2);
$p1->SetSliceColors($survey_chart_colors);
$graph->Add($p1);
$graph->Stroke();
开发者ID:Razze,项目名称:hamsterpaj,代码行数:28,代码来源:poll_chart.php

示例3: array

require_once "jpgraph/jpgraph_pie.php";
// Some data
$data = array(27, 23, 47, 17);
// A new graph
$graph = new PieGraph(350, 200);
$graph->SetShadow();
// Setup title
$graph->title->Set("Example of pie plot with absolute labels");
$graph->title->SetFont(FF_FONT1, FS_BOLD);
// The pie plot
$p1 = new PiePlot($data);
// Move center of pie to the left to make better room
// for the legend
$p1->SetCenter(0.35, 0.5);
// No border
$p1->ShowBorder(false);
// Label font and color setup
$p1->value->SetFont(FF_FONT1, FS_BOLD);
$p1->value->SetColor("darkred");
// Use absolute values (type==1)
$p1->SetLabelType(PIE_VALUE_ABS);
// Label format
$p1->value->SetFormat("\$%d");
$p1->value->Show();
// Size of pie in fraction of the width of the graph
$p1->SetSize(0.3);
// Legends
$p1->SetLegends(array("May (\$%d)", "June (\$%d)", "July (\$%d)", "Aug (\$%d)"));
$graph->legend->Pos(0.05, 0.15);
$graph->Add($p1);
$graph->Stroke();
开发者ID:hcvcastro,项目名称:pxp,代码行数:31,代码来源:pieex6.php

示例4: getColors

            if (strlen($lastTLD)) {
                getColors($colors, $count, $index);
            }
            // reset the counter
            $count = 0;
            $lastTLD = $tld;
        }
        $count++;
    }
    if (strlen($lastTLD)) {
        getColors($colors, $count, $index);
    }
    $graph = new PieGraph($width, $height);
    $graph->SetFrame(false);
    $graph->SetAntiAliasing();
    $pie = new PiePlot($values);
    // set  the actual labels for the wedges
    $pie->SetLabels($labels, 1.1);
    if (count($colors)) {
        $pie->SetSliceColors($colors);
    }
    // set other options
    $pie->SetGuideLines(true, true, true);
    $graph->title->SetFont(FF_FONT2, FS_BOLD);
    $graph->title->Set($chartType);
    $pie->ShowBorder(true, true);
    $pie->SetSize(0.25);
    $graph->Add($pie);
    $graph->img->SetExpired(false);
    $graph->Stroke();
}
开发者ID:kondrats,项目名称:Pagetest,代码行数:31,代码来源:domainPie.php

示例5: grafico_distribucion_tipo_resp

 public function grafico_distribucion_tipo_resp($id_asignacionprueba)
 {
     require_once APPPATH . '/libraries/JpGraph/jpgraph_pie.php';
     $this->rendimiento_global($id_asignacionprueba);
     $data_circ = array($this->totalcorrectas, $this->totalincorrectas, $this->totalomitidas);
     $columnas_circ = array('Correctas', 'Incorrectas', 'Omitidas');
     $graph_circ = new PieGraph(400, 320);
     $graph_circ->title->Set("Distribución por Tipo de Respuesta");
     $graph_circ->SetMarginColor("#fff");
     $graph_circ->SetFrame(true, '#fff', 1);
     $graph_circ->SetBox(false);
     $p1 = new PiePlot($data_circ);
     $p1->ExplodeSlice(0);
     $p1->SetCenter(0.5);
     //$p1->SetLegends('Correctas','Incorrectas','Omitidas');
     $p1->SetLegends($columnas_circ);
     // No border
     $p1->ShowBorder(false);
     $graph_circ->legend->SetPos(0.1, 0.996, 'left', 'bottom');
     $graph_circ->legend->SetFrameWeight(1);
     $p1->SetGuideLines(true, false);
     $p1->SetGuideLinesAdjust(1.5);
     $p1->SetLabelType(PIE_VALUE_PER);
     $p1->value->Show();
     $p1->SetSliceColors(array('#1d71b8', '#ea1d25', 'orange'));
     $graph_circ->Add($p1);
     $graph_circ->Stroke(_IMG_HANDLER);
     global $img_graf_dist_resp;
     $this->img_graf_dist_resp = "assets/images/graf_dist_resp.jpg";
     $graph_circ->img->Stream($this->img_graf_dist_resp);
     /*
     $graph_circ->img->Headers();
     $graph_circ->img->Stream();
     */
 }
开发者ID:aeduc,项目名称:mideteed,代码行数:35,代码来源:Estadistica.php


注:本文中的PiePlot::ShowBorder方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。