亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? lbleffct.pas

?? 功能強大和形態多樣的TLabel控件
?? PAS
?? 第 1 頁 / 共 3 頁
字號:
unit LblEffct;

{
  This unit implements a label component with 3D effects.
  Written by Keith Wood - 27 May 1995.

  This version of the component (3.0) is shareware. Previous version were
  freeware. If you like the component and use it then please send USD$15
  to the address below. Any correspondence or improvements can be sent to :

     Keith Wood                                 kwood@netinfo.com.au
     4 Watterson Place
     Gilmore  A.C.T.  2905
     Australia

  The label has a highlight and a shadow.  The colours of these
  can be controlled through properties as can their distance
  from the label and their direction.  There are also preset
  combinations of direction/distance and colours.

  The label can be set to operate as a button, ie. initially
  raised it will depress when clicked.

  The label can be rotated to any angle.

  Version 2.0 - 1 Feb 1996
      Added extrusion, keep letters vertical, graduated face and version.
  Version 2.1 - 14 Jun 1996
      Update to work with Delphi 2.0, fix bug with Transparent property,
      fix bug with Alignment property, prepare label offscreen and then display.
  Version 3.0 - 3 Jan 1997
      Added separate graduation colours for highlight and shadow.
      Added extra face graduation options.
      Added resize of highlight/shadow.
      Added bitmap background for text.

  Thanks to Paradox Informant and their starter article on 3D labels.
  Thanks to Bill Murto and his RotateLabel.
  Thanks to Curtis Keisler and his TxtRotat example.
}

interface

uses
  SysUtils, WinTypes, WinProcs, Classes, Graphics, Controls, StdCtrls, Dialogs;

type
  { Range of offsets for the shadows }
  TEffectDepth = 0..10;

  { Directions in which the offsets can be positioned }
  TEffectDirection = (edNone, edUp, edUpRight, edRight, edDownRight, edDown,
      edDownLeft, edLeft, edUpLeft);

  { Constants for specifying direction component }
  TDirXY = (drX, drY);

  { The preset styles of label effects available }
  TEffectStyle = (esNone, esCustom, esRaised, esSunken, esShadow, esFlying);

  { The preset colour schemes available }
  TColourScheme = (csCustom, csText, csWindows, csEmbossed, csGold, csSteel);

  { Constants for specifying positions of colours }
  TColourPosition = (cpHighlight, cpShadow, cpFace);

  { Range for rotation }
  TAngleRange = 0..360;

  { Options for varying the shadow/highlight for the label }
  TEffectOption = (eoNormal, eoReal, eoExtrude, eoGraduated);

  { Options for varying the face of the label }
  TGraduateOption = (goNone, goVertical, goHorizontal, goFDiagonal,
    goBDiagonal, goBoxed, goRIndented, goLIndented);

  { Options for varying the text size of the label }
  TResizeOption = (rsNone, rsExpand, rsReduce);

  { The label itsef }
  TLabelEffect = class(TCustomLabel)
  private
    { Private declarations }
    FDepthHighlight,
    FDepthShadow: TEffectDepth;
    FDirectionHighlight,
    FDirectionShadow: TEffectDirection;
    FColourHighlight,
    FColourShadow,
    FGraduateHighlight,
    FGraduateShadow,
    FColourFace: TColor;
    FGraduateFace: TGraduateOption;
    FGraduateFrom: TColor;
    FStyleHighlight,
    FStyleShadow: TEffectOption;
    FResizeHighlight,
    FResizeShadow: TResizeOption;
    FEffectStyle: TEffectStyle;
    FColourScheme: TColourScheme;
    FBitmap: TBitmap;
    FAsButton: Boolean;
    FAngle: TAngleRange;
    FKeepLettersVertical: Boolean;
    FVersion: String;
    bChangingStyle,                { Is preset style being invoked ? }
    bChangingScheme: Boolean;      { Is preset colour scheme being invoked ? }
    clrSchemes: array [TColourScheme,TColourPosition] of TColor;
    dDegToRad, dCosAngle, dSinAngle, dCosSquared, dSinSquared: Double;
    procedure SetDepthHighlight(iDepth: TEffectDepth);
    procedure SetDepthShadow(iDepth: TEffectDepth);
    procedure SetDirectionHighlight(edDirection: TEffectDirection);
    procedure SetDirectionShadow(edDirection: TEffectDirection);
    procedure SetColourHighlight(clrHighlight: TColor);
    procedure SetColourShadow(clrShadow: TColor);
    procedure SetGraduateHighlight(clrHighlight: TColor);
    procedure SetGraduateShadow(clrShadow: TColor);
    procedure SetColourFace(clrFace: TColor);
    procedure SetGraduateFace(goGrad: TGraduateOption);
    procedure SetGraduateFrom(clrGrad: TColor);
    procedure SetStyleHighlight(eoStyle: TEffectOption);
    procedure SetStyleShadow(eoStyle: TEffectOption);
    procedure SetResizeHighlight(rsSize: TResizeOption);
    procedure SetResizeShadow(rsSize: TResizeOption);
    procedure SetEffectStyle(esStyle: TEffectStyle);
    procedure SetColourScheme(csScheme: TColourScheme);
    procedure SetBitmap(bmp: TBitmap);
    procedure SetAsButton(bBtn: Boolean);
    procedure SetAngle(aAngle: TAngleRange);
    procedure SetTextAngle(cnv: TCanvas; aAngle: TAngleRange; iHeight: Integer);
    procedure SetKeepLettersVertical(bKeep: Boolean);
    function GetColourFace: TColor;
    procedure ChangeFont(Sender: TObject);
    procedure ChangeBitmap(Sender: TObject);
    function IsCustomEffect: Boolean;
    function IsCustomScheme: Boolean;

  protected
    { Protected declarations }
    procedure Paint; override;
    procedure MouseDown(mbBtn: TMouseButton; ssShift: TShiftState;
        x, y: Integer); override;
    procedure MouseMove(ssShift: TShiftState; x, y: Integer); override;
    procedure MouseUp(mbBtn: TMouseButton; ssShift: TShiftState;
        x, y: Integer); override;

  public
    { Public declarations }
    constructor Create(AOwner:TComponent); override;
    destructor Destroy; override;
    procedure Assign(Source: TPersistent); override;
    property Version: String read FVersion;         { Read-only }

  published
    { Publish specialised properties }
    property DepthHighlight: TEffectDepth read FDepthHighlight
        write SetDepthHighlight stored IsCustomEffect default 1;
    property DepthShadow: TEffectDepth read FDepthShadow
        write SetDepthShadow stored IsCustomEffect default 1;
    property DirectionHighlight: TEffectDirection read FDirectionHighlight
        write SetDirectionHighlight stored IsCustomEffect default edUpLeft;
    property DirectionShadow: TEffectDirection read FDirectionShadow
        write SetDirectionShadow stored IsCustomEffect default edDownRight;
    property ColourHighlight: TColor read FColourHighlight
        write SetColourHighlight stored IsCustomScheme default clWhite;
    property ColourShadow: TColor read FColourShadow
        write SetColourShadow stored IsCustomScheme default clBlack;
    property GraduateHighlight: TColor read FGraduateHighlight
        write SetGraduateHighlight default clGray;
    property GraduateShadow: TColor read FGraduateShadow
        write SetGraduateShadow default clGray;
    property ColourFace: TColor read GetColourFace write SetColourFace;
    property GraduateFace: TGraduateOption read FGraduateFace
        write SetGraduateFace default goNone;
    property GraduateFrom: TColor read FGraduateFrom
        write SetGraduateFrom default clGray;
    property StyleHighlight: TEffectOption read FStyleHighlight
        write SetStyleHighlight default eoNormal;
    property StyleShadow: TEffectOption read FStyleShadow
        write SetStyleShadow default eoNormal;
    property ResizeHighlight: TResizeOption read FResizeHighlight
        write SetResizeHighlight default rsNone;
    property ResizeShadow: TResizeOption read FResizeShadow
        write SetResizeShadow default rsNone;
    property EffectStyle: TEffectStyle read FEffectStyle
        write SetEffectStyle default esRaised;
    property ColourScheme: TColourScheme read FColourScheme
        write SetColourScheme default csWindows;
    property Bitmap: TBitmap read FBitmap write SetBitmap;
    property AsButton: Boolean read FAsButton write SetAsButton default False;
    property Angle: TAngleRange read FAngle write SetAngle default 0;
    property KeepLettersVertical: Boolean read FKeepLettersVertical
        write SetKeepLettersVertical default False;

    { Publish inherited properties }
    property Align;
    property Alignment;
    property Caption;
    property Color;
    property Cursor;
    property DragCursor;
    property DragMode;
    property Enabled;
    property FocusControl;
    property Font;
    property ParentColor;
    property ParentFont;
    property ParentShowHint;
    property ShowAccelChar;
    property ShowHint;
    property Transparent default True;
    property Visible;
    property WordWrap;

    property OnClick;
    property OnDblClick;
    property OnDragDrop;
    property OnDragOver;
    property OnEndDrag;
    property OnMouseDown;
    property OnMouseMove;
    property OnMouseUp;
  end;

procedure Register;

implementation

const
  sLabelEffectVersion = '3.0';

procedure Register;
begin
  RegisterComponents('MyControl', [TLabelEffect]);
end;

{ Initialisation }
constructor TLabelEffect.Create(AOwner: TComponent);
begin
  inherited Create(AOwner);

  { Colour schemes cannot be constant since Custom version varies }
  clrSchemes[csText, cpHighlight] := clWhite;
  clrSchemes[csText, cpFace] := clBlack;
  clrSchemes[csText, cpShadow] := clGray;

  clrSchemes[csWindows, cpHighlight] := clWhite;
  clrSchemes[csWindows, cpFace] := clGray;
  clrSchemes[csWindows, cpShadow] := clBlack;

  clrSchemes[csEmbossed, cpHighlight] := clWhite;
  clrSchemes[csEmbossed, cpFace] := clSilver;
  clrSchemes[csEmbossed, cpShadow] := clBlack;

  clrSchemes[csGold, cpHighlight] := clYellow;
  clrSchemes[csGold, cpFace] := clOlive;
  clrSchemes[csGold, cpShadow] := clBlack;

  clrSchemes[csSteel, cpHighlight] := clAqua;
  clrSchemes[csSteel, cpFace] := clTeal;
  clrSchemes[csSteel, cpShadow] := clNavy;

  clrSchemes[csCustom, cpHighlight] := clrSchemes[csWindows, cpHighlight];
  clrSchemes[csCustom, cpFace] := clrSchemes[csWindows, cpFace];
  clrSchemes[csCustom, cpShadow] := clrSchemes[csWindows, cpShadow];

  { Initialise default values for internal fields }
  FDepthHighlight := 1;
  FDepthShadow := 1;
  FDirectionHighlight := edUpLeft;
  FDirectionShadow := edDownRight;
  FStyleHighlight := eoNormal;
  FStyleShadow := eoNormal;
  FResizeHighlight := rsNone;
  FResizeShadow := rsNone;
  FEffectStyle := esRaised;
  FColourScheme := csWindows;
  FColourHighlight := clrSchemes[FColourScheme, cpHighlight];
  FColourShadow := clrSchemes[FColourScheme, cpShadow];
  FGraduateFace := goNone;
  FGraduateFrom := clrSchemes[FColourScheme, cpFace];
  FGraduateHighlight := clrSchemes[FColourScheme, cpFace];
  FGraduateShadow := clrSchemes[FColourScheme, cpFace];
  FBitmap := TBitmap.Create;
  FBitmap.OnChange := ChangeBitmap;
  FAsButton := False;
  FAngle := 0;
  FKeepLettersVertical := False;
  FVersion := sLabelEffectVersion;

  bChangingStyle := False;
  bChangingScheme := False;
  dDegToRad := PI / 180;
  dCosAngle := 1;         { Cos(FAngle * dDegToRad) }
  dCosSquared := 1;
  dSinAngle := 0;         { Sin(FAngle * dDegToRad) }
  dSinSquared := 0;

  AutoSize := False;
  Height := 33;
  Width := 142;
  Transparent := True;
  Font.Color := clrSchemes[FColourScheme, cpFace];
  Font.Name := 'Times New Roman';
  Font.Size := 20;
  Font.OnChange := ChangeFont;
end;

{ Free resources }
destructor TLabelEffect.Destroy;
begin
  FBitmap.Free;

  inherited Destroy;
end;

{ Copy to a new label }
procedure TLabelEffect.Assign(Source: TPersistent);
begin
  if Source is TLabelEffect then  { Can copy }
    with TLabelEffect(Source) do
    begin
      Self.Alignment := Alignment;
      Self.DragCursor := DragCursor;
      Self.DragMode := DragMode;
      Self.Enabled := Enabled;
      Self.FocusControl := FocusControl;
      Self.ShowAccelChar := ShowAccelChar;
      Self.Hint := Hint;
      Self.ParentShowHint := ParentShowHint;
      Self.ShowHint := ShowHint;
      Self.Tag := Tag;
      Self.Transparent := Transparent;
      Self.Visible := Visible;
      Self.WordWrap := WordWrap;

      Self.Bitmap.Assign(Bitmap);
      Self.Caption := Caption;
      Self.ParentColor := ParentColor;
      Self.Color := Color;
      Self.ColourHighlight := ColourHighlight;
      Self.ColourShadow := ColourShadow;
      Self.ParentFont := ParentFont;
      Self.Font.Assign(Font);
      Self.ColourScheme := ColourScheme;
      Self.Cursor := Cursor;
      Self.DepthHighlight := DepthHighlight;
      Self.DepthShadow := DepthShadow;
      Self.DirectionHighlight := DirectionHighlight;
      Self.DirectionShadow := DirectionShadow;
      Self.EffectStyle := EffectStyle;
      Self.GraduateFace := GraduateFace;
      Self.GraduateFrom := GraduateFrom;
      Self.GraduateHighlight := GraduateHighlight;
      Self.GraduateShadow := GraduateShadow;
      Self.ResizeHighlight := ResizeHighlight;
      Self.ResizeShadow := ResizeShadow;
      Self.StyleHighlight := StyleHighlight;
      Self.StyleShadow := StyleShadow;
      Self.Angle := Angle;
      Self.KeepLettersVertical := KeepLettersVertical;
      Self.AsButton := AsButton;
    end
  else  { Try default assign }
    inherited Assign(Source);
end;

{ Only store these properties if a custom effect style }
function TLabelEffect.IsCustomEffect: Boolean;
begin
  Result := (EffectStyle = esCustom);
end;

{ Only store these properties if a custom colour scheme }
function TLabelEffect.IsCustomScheme: Boolean;
begin
  Result := (ColourScheme = csCustom);
end;

{ Change face colour too }
procedure TLabelEffect.ChangeFont(Sender: TObject);
begin
  SetColourFace(Font.Color);
  Invalidate;
end;

{ Set highlight depth and repaint }
procedure TLabelEffect.SetDepthHighlight(iDepth: TEffectDepth);
begin
  if FDepthHighlight <> iDepth then
  begin
    FDepthHighlight := iDepth;
    if not bChangingStyle then  { Default to custom style when changed }
      SetEffectStyle(esCustom);
    Invalidate;
  end;
end;

{ Set shadow depth and repaint }
procedure TLabelEffect.SetDepthShadow(iDepth: TEffectDepth);
begin
  if FDepthShadow <> iDepth then
  begin
    FDepthShadow := iDepth;
    if not bChangingStyle then  { Default to custom style when changed }
      SetEffectStyle(esCustom);
    Invalidate;
  end;
end;

{ Set highlight direction and repaint }
procedure TLabelEffect.SetDirectionHighlight(edDirection: TEffectDirection);
begin
  if FDirectionHighlight <> edDirection then
  begin
    FDirectionHighlight := edDirection;
    if not bChangingStyle then  { Default to custom style when changed }
      SetEffectStyle(esCustom);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩福利视频网| 国产精品麻豆久久久| 亚洲电影一区二区三区| 欧美伊人久久久久久久久影院| 亚洲美腿欧美偷拍| 欧美高清视频一二三区| 日本色综合中文字幕| 日韩视频免费直播| 国产成人综合亚洲91猫咪| 中文一区二区完整视频在线观看| 99热这里都是精品| 一区二区三区高清在线| 6080午夜不卡| 国产剧情一区二区| 亚洲激情六月丁香| 欧美一区二区免费视频| 国产精品一区三区| 一区二区三区在线影院| 欧美一区二区三区在线观看| 国产在线一区二区| 亚洲三级在线免费观看| 51久久夜色精品国产麻豆| 国产一区二区三区精品视频| 中文字幕一区二区三区乱码在线| 欧美色综合久久| 国产伦精品一区二区三区免费 | 麻豆精品在线视频| 国产欧美日韩激情| 欧美日韩一区国产| 国产成人在线免费| 亚洲不卡在线观看| 国产欧美日韩中文久久| 欧美性受xxxx| 粉嫩av一区二区三区粉嫩| 亚洲电影一区二区| 欧美激情综合在线| 制服丝袜成人动漫| av高清久久久| 久久精品国产77777蜜臀| 亚洲三级电影全部在线观看高清| 欧美一级专区免费大片| 97久久精品人人爽人人爽蜜臀| 免费在线观看不卡| 亚洲最大成人网4388xx| 久久精品人人爽人人爽| 欧美一级艳片视频免费观看| av激情综合网| 成人爽a毛片一区二区免费| 天天av天天翘天天综合网| 国产精品卡一卡二卡三| 久久―日本道色综合久久| 欧美日韩国产中文| 91色视频在线| 成人午夜在线播放| 精品一区二区三区香蕉蜜桃| 亚洲综合色在线| 成人免费在线视频| 欧美激情一区三区| 国产亚洲污的网站| 精品日韩成人av| 日韩三级电影网址| 欧美精品1区2区| 欧美区在线观看| 欧美亚洲自拍偷拍| 色狠狠桃花综合| 99精品在线免费| 99久久婷婷国产精品综合| 国产精品白丝jk黑袜喷水| 精品在线播放午夜| 青青青伊人色综合久久| 五月综合激情网| 亚洲福中文字幕伊人影院| 一级精品视频在线观看宜春院| 国产精品国产三级国产aⅴ原创 | 久久av老司机精品网站导航| 亚洲午夜视频在线| 亚洲午夜久久久久中文字幕久| 成人免费视频在线观看| 国产精品久久久久精k8| 国产精品免费视频网站| 国产精品美日韩| 中文字幕一区二区三区在线不卡 | 五月激情丁香一区二区三区| 亚洲一本大道在线| 亚洲成人动漫精品| 日韩精品成人一区二区在线| 日韩国产在线一| 久久er精品视频| 国产高清精品久久久久| 床上的激情91.| 色呦呦一区二区三区| 欧美亚洲日本国产| 制服视频三区第一页精品| 精品久久免费看| 国产欧美日韩麻豆91| 亚洲精品日日夜夜| 日韩精品国产精品| 国产精品自拍毛片| 91蜜桃在线免费视频| 欧美区视频在线观看| 精品久久久网站| 亚洲欧洲无码一区二区三区| 一区二区三区免费网站| 日韩av网站在线观看| 国产不卡免费视频| 99re6这里只有精品视频在线观看| 欧美午夜精品久久久久久超碰 | 国产一区在线观看麻豆| 国产成人一区在线| 欧美视频自拍偷拍| 日韩欧美一区在线观看| 国产欧美日韩精品在线| 亚洲人123区| 日韩成人一级片| 懂色av一区二区三区免费看| 91黄色小视频| 久久精品一二三| 午夜日韩在线观看| 国产盗摄一区二区三区| 欧美日韩极品在线观看一区| 久久午夜羞羞影院免费观看| 亚洲免费高清视频在线| 久久99久久99| 97se亚洲国产综合自在线观| 91精品国产免费久久综合| 国产精品乱码一区二三区小蝌蚪| 亚洲3atv精品一区二区三区| 国产成人免费视频精品含羞草妖精| 色诱视频网站一区| 久久婷婷一区二区三区| 亚洲一区二区三区三| 国产乱妇无码大片在线观看| 欧美人狂配大交3d怪物一区| 国产精品国产三级国产aⅴ入口| 亚瑟在线精品视频| 91色porny蝌蚪| 国产无人区一区二区三区| 五月天网站亚洲| 91麻豆国产福利在线观看| 亚洲精品一区二区三区四区高清| 一级特黄大欧美久久久| www.在线欧美| 国产香蕉久久精品综合网| 蜜乳av一区二区三区| 欧洲另类一二三四区| 中日韩av电影| 国产在线观看一区二区| 欧美一区二区三区在| 亚洲一卡二卡三卡四卡| 91偷拍与自偷拍精品| 国产欧美日韩激情| 国产美女娇喘av呻吟久久| 日韩免费性生活视频播放| 日韩精品一级二级| 欧美日韩精品一区二区| 亚洲精品中文在线观看| 97精品国产97久久久久久久久久久久| 久久婷婷成人综合色| 亚洲国产成人午夜在线一区| 免费观看在线综合| 欧美日韩高清在线| 精品久久人人做人人爱| 久久精品国产亚洲aⅴ| 91精品国产91久久久久久一区二区 | 欧美日韩国产一区二区三区地区| 中文字幕视频一区| 成人动漫一区二区在线| 中文字幕精品在线不卡| 粉嫩高潮美女一区二区三区| 亚洲国产精品精华液ab| 国产精品资源网| 久久影院电视剧免费观看| 捆绑变态av一区二区三区| 日韩亚洲欧美中文三级| 六月丁香婷婷色狠狠久久| 精品盗摄一区二区三区| 国产最新精品精品你懂的| 国产婷婷一区二区| av综合在线播放| 亚洲激情在线播放| 欧美精品在线一区二区| 日韩影视精彩在线| 精品国产不卡一区二区三区| 国产一区二区三区综合| 国产欧美日韩中文久久| 99热精品国产| 亚洲成人免费在线| 日韩午夜三级在线| 国产麻豆午夜三级精品| 亚洲丝袜另类动漫二区| 欧美揉bbbbb揉bbbbb| 日韩成人一区二区三区在线观看| 精品日韩一区二区三区免费视频| 国产一区二区0| 亚洲色图在线播放| 日韩一区二区影院| 福利电影一区二区| 亚洲一二三四区| 精品伦理精品一区| 91免费观看视频在线|