Ignore:
Timestamp:
2013/08/24 23:33:52 (11 years ago)
Author:
kimoto
Message:

#2043 typo修正・ソース整形・ソースコメントの改善 for 2.13.0
PHP4的な書き方の修正

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_13-dev/data/class/graph/SC_Graph_Base.php

    r22856 r23124  
    133133class SC_Graph_Base 
    134134{ 
    135     var $arrRGB; 
    136     var $arrColor; 
    137     var $arrDarkColor; 
    138     var $image; 
    139     var $left; 
    140     var $top; 
    141     var $shade_color; 
    142     var $flame_color; 
    143     var $shade_on; 
    144     var $text_color; 
    145     var $labelbg_color; 
    146     var $bgw; 
    147     var $bgh; 
    148     var $clabelbg_color; 
    149     var $title_color; 
    150     var $text_top; 
    151     var $mark_color; 
    152     var $arrLegend; 
     135    public $arrRGB; 
     136    public $arrColor; 
     137    public $arrDarkColor; 
     138    public $image; 
     139    public $left; 
     140    public $top; 
     141    public $shade_color; 
     142    public $flame_color; 
     143    public $shade_on; 
     144    public $text_color; 
     145    public $labelbg_color; 
     146    public $bgw; 
     147    public $bgh; 
     148    public $clabelbg_color; 
     149    public $title_color; 
     150    public $text_top; 
     151    public $mark_color; 
     152    public $arrLegend; 
    153153 
    154154    /** グラフ背景 */ 
    155     var $ARR_GRAPH_RGB; 
     155    public $ARR_GRAPH_RGB; 
    156156 
    157157    /** 背景色 */ 
    158     var $ARR_BG_COLOR; 
     158    public $ARR_BG_COLOR; 
    159159 
    160160    /** 影の色 */ 
    161     var $ARR_SHADE_COLOR; 
     161    public $ARR_SHADE_COLOR; 
    162162 
    163163    /** 縁の色 */ 
    164     var $ARR_FLAME_COLOR; 
     164    public $ARR_FLAME_COLOR; 
    165165 
    166166    /** 文字色 */ 
    167     var $ARR_TEXT_COLOR; 
     167    public $ARR_TEXT_COLOR; 
    168168 
    169169    /** ラベル背景 */ 
    170     var $ARR_LABELBG_COLOR; 
     170    public $ARR_LABELBG_COLOR; 
    171171 
    172172    /** 凡例背景 */ 
    173     var $ARR_LEGENDBG_COLOR; 
     173    public $ARR_LEGENDBG_COLOR; 
    174174 
    175175    /** タイトル文字色 */ 
    176     var $ARR_TITLE_COLOR; 
     176    public $ARR_TITLE_COLOR; 
    177177 
    178178    /** グリッド線色 */ 
    179     var $ARR_GRID_COLOR; 
     179    public $ARR_GRID_COLOR; 
    180180 
    181181    // コンストラクタ 
    182     function __construct($bgw, $bgh, $left, $top) 
     182    public function __construct($bgw, $bgh, $left, $top) 
    183183    { 
    184184        $this->init(); 
     
    210210 
    211211    // リサンプル(画像を滑らかに縮小する) 
    212     function resampled() 
     212    public function resampled() 
    213213    { 
    214214        $new_width = $this->bgw * 0.8; 
     
    221221 
    222222    // オブジェクトカラーの設定 
    223     function setColorList($arrRGB) 
     223    public function setColorList($arrRGB) 
    224224    { 
    225225        $this->arrRGB = $arrRGB; 
     
    236236 
    237237    // 影のありなし 
    238     function setShadeOn($shade_on) 
     238    public function setShadeOn($shade_on) 
    239239    { 
    240240        $this->shade_on = $shade_on; 
     
    242242 
    243243    // 画像を出力する 
    244     function outputGraph($header = true, $filename = '') 
     244    public function outputGraph($header = true, $filename = '') 
    245245    { 
    246246        if ($header) { 
     
    258258 
    259259    // 描画時のテキスト幅を求める 
    260     function getTextWidth($text, $font_size) 
     260    public function getTextWidth($text, $font_size) 
    261261    { 
    262262        $text_len = strlen($text); 
     
    268268            $ret = $arrPos[2] - $arrPos[0]; 
    269269        */ 
     270 
    270271        return $ret; 
    271272    } 
    272273 
    273274    // テキストを出力する 
    274     function setText($font_size, $left, $top, $text, $color = NULL, $angle = 0, $labelbg = false) 
     275    public function setText($font_size, $left, $top, $text, $color = NULL, $angle = 0, $labelbg = false) 
    275276    { 
    276277        // 時計回りに角度を変更 
     
    305306 
    306307    // タイトルを出力する 
    307     function drawTitle($text, $font_size = TITLE_FONT_SIZE) 
     308    public function drawTitle($text, $font_size = TITLE_FONT_SIZE) 
    308309    { 
    309310        // 出力位置の算出 
     
    315316 
    316317    // ログを出力する 
    317     function debugPrint($text) 
     318    public function debugPrint($text) 
    318319    { 
    319320        $text = mb_convert_encoding($text, 'UTF-8', CHAR_CODE); 
     
    327328 
    328329    // カラーラベルを描画 
    329     function drawLegend($legend_max = '', $clabelbg = true) 
     330    public function drawLegend($legend_max = '', $clabelbg = true) 
    330331    { 
    331332        // 凡例が登録されていなければ中止 
     
    377378 
    378379    // カラーラベル背景の描画 
    379     function drawClabelBG($left, $top, $right, $bottom) 
     380    public function drawClabelBG($left, $top, $right, $bottom) 
    380381    { 
    381382        // 影の描画 
     
    389390 
    390391    // 凡例をセットする 
    391     function setLegend($arrLegend) 
    392     { 
    393         $this->arrLegend = array_values((array)$arrLegend); 
     392    public function setLegend($arrLegend) 
     393    { 
     394        $this->arrLegend = array_values((array) $arrLegend); 
    394395    } 
    395396 
     
    402403     * @return void 
    403404     */ 
    404     function init() 
     405    public function init() 
    405406    { 
    406407        // 凡例背景 
     
    439440     * 円の中心点と直径から弧の終端座標を算出する. 
    440441     * 
    441      * @param integer $cx 中心点X座標 
    442      * @param integer $cy 中心点Y座標 
    443      * @param integer $r 半径 
    444      * @param integer $e 角度 
    445      * @return array 円の中心点と直径から弧の終端座標の配列 
     442     * @param  integer $cx 中心点X座標 
     443     * @param  integer $cy 中心点Y座標 
     444     * @param  integer $r 半径 
     445     * @param  integer $e 角度 
     446     * @return array   円の中心点と直径から弧の終端座標の配列 
    446447     */ 
    447     function lfGetArcPos($cx, $cy, $cw, $ch, $e) 
     448    public function lfGetArcPos($cx, $cy, $cw, $ch, $e) 
    448449    { 
    449450        // 三角関数用の角度を求める 
     
    458459 
    459460    /** 画像にテキストを描画する */ 
    460     function lfImageText($dst_image, $text, $font_size, $left, $top, $font, $arrRGB) 
     461    public function lfImageText($dst_image, $text, $font_size, $left, $top, $font, $arrRGB) 
    461462    { 
    462463        $color = ImageColorAllocate($dst_image, $arrRGB[0], $arrRGB[1], $arrRGB[2]); 
     
    469470 
    470471    /** 表示色の取得 */ 
    471     function lfGetImageColor($image, $array) 
     472    public function lfGetImageColor($image, $array) 
    472473    { 
    473474        if (count($array) != 3) { 
     
    480481 
    481482    /** 影用表示色の取得 */ 
    482     function lfGetImageDarkColor($image, $array) 
     483    public function lfGetImageDarkColor($image, $array) 
    483484    { 
    484485        if (count($array) != 3) { 
Note: See TracChangeset for help on using the changeset viewer.