TeeChartの使い方 凡例設定

TeeChartの使い方 凡例設定 (TeeChart Pro 8.06)

uessに TeEngineを追加

    With Chart1 do
    begin

      // 凡例————————————–
      //凡例を表示

       Legend.Visible := True;
      //位置 (laLeft, laRight, laTop, laBottom)
       Legend.Alignment := laRight;
      //カスタム位置(Trueの場合はLeft,Topで位置指定)
       Legend.CustomPosition := False;
      //背景色
       Legend.Color := clWindow;
      //文字を系列色にする
       Legend.FontSeriesColor := True;
      //行の反転
       Legend.Inverted := False;
      //凡例スタイル
      //(lsAuto:自動, lsSeries:系列名, lsValues:系列の値
      //, lsLastValues:最後の値, lsSeriesGroups:系列グループ)

       Legend.LegendStyle := lsSeries;
      //テキストスタイル
      //ltsPlain:文字列のみ, ltsLeftValue:値左側表示, ltsRightValue:値右側表示
      //, ltsLeftPercent:%左側表示, ltsRightPercent:%右側表示
      //, ltsXValue:X値, ltsValue:値, ltsPercent:%
      //, ltsXAndValue:X値と値, ltsXAndPercent:X値と%

       Legend.TextStyle := ltsPlain;
       Legend.Font.Size := 10;
      //影
       Legend.Shadow.Visible := True;
       Legend.ShadowSize := 1;
      //凡例とチャートの余白
       Legend.HorizMargin := 0;
      //チェックボックス
       Legend.CheckBoxes := False;
      //幅の自動調整
       Legend.ColumnWidthAuto := True;
      //行間隔
       Legend.VertSpacing := 0;
      //凡例タイトル
       Legend.Title.Visible := True;
       Legend.Title.Text.Clear;
       Legend.Title.Text.Add(‘Title’);
      //凡例に合わせてチャートサイズ変更
       Legend.ResizeChart := True;

   end;

TeeChartの使い方 タイトル,フッター

TeeChartの使い方 タイトル,フッター (TeeChart Pro 8.06)

    With Chart1 do
    begin

      //タイトル
       Title.Visible := True;
       Title.Font.Color := clBlack;
       Title.Font.Size := 11;
       Title.Text.Clear;
       Title.Text.Add(‘Title’);
       Title.Alignment := taCenter;
       Title.Transparent := False;
       Title.Shadow.Visible := True;

      //サブタイトル
       SubTitle.Visible := True;
       SubTitle.Font.Color := clBlue;
       SubTitle.Font.Size := 10;
       SubTitle.Text.Clear;
       SubTitle.Text.Add(‘SubTitle’);
       SubTitle.Alignment := taRightJustify;
       SubTitle.Transparent := True;

      //フッタータイトル
       Foot.Visible := True;
       Foot.Font.Color := clBlack;
       Foot.Font.Size := 11;
       Foot.Text.Clear;
       Foot.Text.Add(‘Footer’);
       Foot.Alignment := taCenter;
       Foot.Transparent := False;
       Foot.Shadow.Visible := False;

      //フッターサブタイトル
       SubFoot.Visible := True;
       SubFoot.Font.Color := clBlue;
       SubFoot.Font.Size := 10;
       SubFoot.Text.Clear;
       SubFoot.Text.Add(‘SubFooter’);
       SubFoot.Alignment := taLeftJustify;
       SubFoot.Transparent := True;

   end;

TeeChartの使い方 外観設定

TeeChartの使い方 外観設定 (TeeChart Pro 8.06)

uessに TeCanvasを追加

    With Chart1 do
    begin

      //外観=======================================
      //全体の背景色
       Color := clBtnFace;
      //ベベル————————————-
      //(bvNone, bvLowered, bvRaised, bvSpace)
       BevelInner := bvNone;
       BevelOuter := bvRaised;
      //ベベル幅
       BevelWidth := 3;
      //ベベル部とチャート部の境界幅
       BorderWidth := 10;
      //ベベル(枠)の丸み(丸みを付けるとなぜかベベル幅が無効になる)
       BorderRound := 0;
      //外枠—————————————
      //外枠を表示
       Border.Visible := True;
      //外枠の幅
       Border.Width := 5;
      //外枠の色
       Border.Color := clBlue;
      //外枠角のスタイル
      //(esRound, esSquare, esFlat) uess: TeCanvas
       Border.EndStyle := esFlat;
      //余白—————————————
       MarginTop := 2;
       MarginBottom := 2;
       MarginLeft := 2;
       MarginRight := 2;
      //グラデーション
       Gradient.Visible := True;
       Gradient.StartColor := clRed;
       Gradient.EndColor := clWhite;
      //グラデーションの方向
      //(gdTopBottom, gdBottomTop, gdLeftRight, gdRightLeft
      //, gdFromCenter, gdFromTopLeft, gdFromBottomLeft
      //, gdRadial, gdDiagonalUp, gdDiagonalDown);

       Gradient.Direction := gdRadial;
      //影—————————————–
      Shadow.Visible := True;//影有効
      Shadow.Color:=clDkGray;//影の色
      Shadow.HorizSize:=5;//水平サイズ
      Shadow.VertSize:=5;//垂直サイズ
      Shadow.Smooth := True;//なめらか(なめらかな大きい影を付けると重くなる)
      Shadow.Transparency := 0;//透明度(0-100)
      Shadow.SmoothBlur := 0;//ぼかし(Smooth=Trueの場合)
      Shadow.Clip := False;//クリッピング(Smooth=Trueの場合)

      //壁—————————————–
      //壁を表示
       Walls.Visible := True;
      //全部の壁のサイズ(幅)
       Walls.Size := 0;
      //左の壁—–
      //壁を表示
       Walls.Left.Visible := True;
      //壁の色
       Walls.Left.Color := clYellow;
      //枠を表示
       Walls.Left.Frame.Visible := True;
      //枠の色
       Walls.Left.Frame.Color := clRed;
      //枠の幅
       Walls.Left.Frame.Width := 1;
      //3D部を暗くする(壁のサイズが1以上の時)
       Walls.Left.Dark3D := True;
      //チャート回転時系列が隠れないよう壁を自動非表示化
       Walls.Left.AutoHide := True;
      //壁のグラデーション(壁のサイズが1以上だと描画が変?)
      //Walls.Left.Gradient.Visible := True;
      //透明
      //Walls.Left.Transparent := True;
      //開始位置%

       Walls.Left.StartPosition := 0;
      //終了位置%
       Walls.Left.EndPosition := 100;
      //左の壁のサイズ(幅)
      //Walls.Left.Size := 0;
      //透明度

       Walls.Left.Transparency := 0;

      //右(Right),下(Bottom),背面(Back)の壁もほぼ同様

      //チャート背景の枠線
       Walls.Back.Visible := True;
       Walls.Back.Pen.Width := 1;

      //3D—————————————–
      //3D表示

       View3D := True;
      //深さ方向の比率(0-100)
       Chart3DPercent := 15;
      //遠近効果(0-100%)
       View3DOptions.Perspective := 0;
      //水平方向の位置オフセット
       View3DOptions.HorizOffset := 0;
      //垂直方向の位置オフセット
       View3DOptions.VertOffset := 0;
      //フォントサイズ拡大%
       View3DOptions.FontZoom := 100;
      //拡大縮小 整数指定
       View3DOptions.Zoom := 100;
      //拡大縮小 浮動小数点指定
       View3DOptions.ZoomFloat := 100.0;
      //拡大縮小時にテキストも拡大縮小するかどうか
       View3DOptions.ZoomText := True;

      //直交
       View3DOptions.Orthogonal := False;
      //Orthogonal=True の時の設定—–
      //Orthogonal=Trueの時の角度(0-90)
       View3DOptions.OrthoAngle := 0;
      //Orthogonal=Falseの時の設定—–
      //仰角(0-360)整数指定

       View3DOptions.Elevation := 0;
      //仰角(0-360)浮動小数点指定
      //View3DOptions.ElevationFloat := 0.0;
      //回転(0-360)整数指定

       View3DOptions.Rotation := 0;
      //回転(0-360)浮動小数点指定
      //View3DOptions.RotationFloat := 0.0;
      //傾き(0-360)

       View3DOptions.Tilt := 0;

   end;