• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Delphi中的颜色

原作者: [db:作者] 来自: [db:来源] 收藏 邀请
//全以红色举例:

//1. RGB 模式:
Self.Color := $0000ff; 
//不过和HTML中的 #ff0000 是反的,应该叫 BGR。


//2. RGB 分值,譬如:
Self.Color := RGB(255,0,0);


//3. Delphi 中的标准模式:
Self.Color := $000000ff;
//其中低3位字节代表RGB(BGR)相应的颜色;
//如果最高位字节是$00,则表示用系统调色板中最相近的颜色;
//最高位字节是$01,则表示用当前调色板中最相近的颜色匹配;
//最高位字节是$02,则用当前设备描述表中逻辑调色板的次相近颜色匹配。


//4. 整数:
Self.Color := 255;
//十六进制转换来的整数。


//5. 颜色常量:
Self.Color := clRed;
//Delphi 预定义的常量有:

clSystemColor = $FF000000;

clScrollBar = TColor(clSystemColor or COLOR_SCROLLBAR);
clBackground = TColor(clSystemColor or COLOR_BACKGROUND);
clActiveCaption = TColor(clSystemColor or COLOR_ACTIVECAPTION);
clInactiveCaption = TColor(clSystemColor or COLOR_INACTIVECAPTION);
clMenu = TColor(clSystemColor or COLOR_MENU);
clWindow = TColor(clSystemColor or COLOR_WINDOW);
clWindowFrame = TColor(clSystemColor or COLOR_WINDOWFRAME);
clMenuText = TColor(clSystemColor or COLOR_MENUTEXT);
clWindowText = TColor(clSystemColor or COLOR_WINDOWTEXT);
clCaptionText = TColor(clSystemColor or COLOR_CAPTIONTEXT);
clActiveBorder = TColor(clSystemColor or COLOR_ACTIVEBORDER);
clInactiveBorder = TColor(clSystemColor or COLOR_INACTIVEBORDER);
clAppWorkSpace = TColor(clSystemColor or COLOR_APPWORKSPACE);
clHighlight = TColor(clSystemColor or COLOR_HIGHLIGHT);
clHighlightText = TColor(clSystemColor or COLOR_HIGHLIGHTTEXT);
clBtnFace = TColor(clSystemColor or COLOR_BTNFACE);
clBtnShadow = TColor(clSystemColor or COLOR_BTNSHADOW);
clGrayText = TColor(clSystemColor or COLOR_GRAYTEXT);
clBtnText = TColor(clSystemColor or COLOR_BTNTEXT);
clInactiveCaptionText = TColor(clSystemColor or COLOR_INACTIVECAPTIONTEXT);
clBtnHighlight = TColor(clSystemColor or COLOR_BTNHIGHLIGHT);
cl3DDkShadow = TColor(clSystemColor or COLOR_3DDKSHADOW);
cl3DLight = TColor(clSystemColor or COLOR_3DLIGHT);
clInfoText = TColor(clSystemColor or COLOR_INFOTEXT);
clInfoBk = TColor(clSystemColor or COLOR_INFOBK);
clHotLight = TColor(clSystemColor or COLOR_HOTLIGHT);
clGradientActiveCaption = TColor(clSystemColor or COLOR_GRADIENTACTIVECAPTION);
clGradientInactiveCaption = TColor(clSystemColor or COLOR_GRADIENTINACTIVECAPTION);
clMenuHighlight = TColor(clSystemColor or COLOR_MENUHILIGHT);
clMenuBar = TColor(clSystemColor or COLOR_MENUBAR);

clBlack = TColor($000000);
clMaroon = TColor($000080);
clGreen = TColor($008000);
clOlive = TColor($008080);
clNavy = TColor($800000);
clPurple = TColor($800080);
clTeal = TColor($808000);
clGray = TColor($808080);
clSilver = TColor($C0C0C0);
clRed = TColor($0000FF);
clLime = TColor($00FF00);
clYellow = TColor($00FFFF);
clBlue = TColor($FF0000);
clFuchsia = TColor($FF00FF);
clAqua = TColor($FFFF00);
clLtGray = TColor($C0C0C0);
clDkGray = TColor($808080);
clWhite = TColor($FFFFFF);
StandardColorsCount = 16;

clMoneyGreen = TColor($C0DCC0);
clSkyBlue = TColor($F0CAA6);
clCream = TColor($F0FBFF);
clMedGray = TColor($A4A0A0);
ExtendedColorsCount = 4;

clNone = TColor($1FFFFFFF);
clDefault = TColor($20000000);

{ The following "cl" values come from the Web Named Color palette and
  are stored in the Windows COLORREF byte order x00bbggrr }
clWebSnow = $FAFAFF;
clWebFloralWhite = $F0FAFF;
clWebLavenderBlush = $F5F0FF;
clWebOldLace = $E6F5FD;
clWebIvory = $F0FFFF;
clWebCornSilk = $DCF8FF;
clWebBeige = $DCF5F5;
clWebAntiqueWhite = $D7EBFA;
clWebWheat = $B3DEF5;
clWebAliceBlue = $FFF8F0;
clWebGhostWhite = $FFF8F8;
clWebLavender = $FAE6E6;
clWebSeashell = $EEF5FF;
clWebLightYellow = $E0FFFF;
clWebPapayaWhip = $D5EFFF;
clWebNavajoWhite = $ADDEFF;
clWebMoccasin = $B5E4FF;
clWebBurlywood = $87B8DE;
clWebAzure = $FFFFF0;
clWebMintcream = $FAFFF5;
clWebHoneydew = $F0FFF0;
clWebLinen = $E6F0FA;
clWebLemonChiffon = $CDFAFF;
clWebBlanchedAlmond = $CDEBFF;
clWebBisque = $C4E4FF;
clWebPeachPuff = $B9DAFF;
clWebTan = $8CB4D2;
// yellows/reds yellow -> rosybrown
clWebYellow = $00FFFF;
clWebDarkOrange = $008CFF;
clWebRed = $0000FF;
clWebDarkRed = $00008B;
clWebMaroon = $000080;
clWebIndianRed = $5C5CCD;
clWebSalmon = $7280FA;
clWebCoral = $507FFF;
clWebGold = $00D7FF;
clWebTomato = $4763FF;
clWebCrimson = $3C14DC;
clWebBrown = $2A2AA5;
clWebChocolate = $1E69D2;
clWebSandyBrown = $60A4F4;
clWebLightSalmon = $7AA0FF;
clWebLightCoral = $8080F0;
clWebOrange = $00A5FF;
clWebOrangeRed = $0045FF;
clWebFirebrick = $2222B2;
clWebSaddleBrown = $13458B;
clWebSienna = $2D52A0;
clWebPeru = $3F85CD;
clWebDarkSalmon = $7A96E9;
clWebRosyBrown = $8F8FBC;
// greens palegoldenrod -> darkseagreen
clWebPaleGoldenrod = $AAE8EE;
clWebLightGoldenrodYellow = $D2FAFA;
clWebOlive = $008080;
clWebForestGreen = $228B22;
clWebGreenYellow = $2FFFAD;
clWebChartreuse = $00FF7F;
clWebLightGreen = $90EE90;
clWebAquamarine = $D4FF7F;
clWebSeaGreen = $578B2E;
clWebGoldenRod = $20A5DA;
clWebKhaki = $8CE6F0;
clWebOliveDrab = $238E6B;
clWebGreen = $008000;
clWebYellowGreen = $32CD9A;
clWebLawnGreen = $00FC7C;
clWebPaleGreen = $98FB98;
clWebMediumAquamarine = $AACD66;
clWebMediumSeaGreen = $71B33C;
clWebDarkGoldenRod = $0B86B8;
clWebDarkKhaki = $6BB7BD;
clWebDarkOliveGreen = $2F6B55;
clWebDarkgreen = $006400;
clWebLimeGreen = $32CD32;
clWebLime =  
                       
                    
                    

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
怎么在delphi中读取Excel数据(各种详细操作)发布时间:2022-07-18
下一篇:
DELPHI中通过SHBrowseForFolder函数实现选择目录发布时间:2022-07-18
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap