颜色名称 | 颜色效果 | Hex | HTML |
---|---|---|---|
clBlack | $000000 | #000000 | |
clMaroon | $000080 | #800000 | |
clGreen | $008000 | #008000 | |
clOlive | $008080 | #808000 | |
clNavy | $800000 | #000080 | |
clPurple | $800080 | #800080 | |
clTeal | $808000 | #008080 | |
clGray | $808080 | #808080 | |
clSilver | $C0C0C0 | #C0C0C0 | |
clRed | $0000FF | #FF0000 | |
clLime | $00FF00 | #00FF00 | |
clYellow | $00FFFF | #FFFF00 | |
clBlue | $FF0000 | #0000FF | |
clFuchsia | $FF00FF | #FF00FF | |
clAqua | $FFFF00 | #00FFFF | |
clLtGray | $C0C0C0 | #C0C0C0 | |
clDkGray | $808080 | #808080 | |
clWhite | $FFFFFF | #FFFFFF | |
clMoneyGreen | $C0DCC0 | #C0DCC0 | |
clSkyBlue | $F0CAA6 | #A6CAF0 | |
clCream | $F0FBFF | #FFFBF0 | |
clMedGray | $A4A0A0 | #A0A0A4 | |
clWebSnow | $FAFAFF | #FFFAFA | |
clWebFloralWhite | $F0FAFF | #FFFAF0 | |
clWebLavenderBlush | $F5F0FF | #FFF0F5 | |
clWebOldLace | $E6F5FD | #FDF5E6 | |
clWebIvory | $F0FFFF | #FFFFF0 | |
clWebCornSilk | $DCF8FF | #FFF8DC | |
clWebBeige | $DCF5F5 | #F5F5DC | |
clWebAntiqueWhite | $D7EBFA | #FAEBD7 | |
clWebWheat | $B3DEF5 | #F5DEB3 | |
clWebAliceBlue | $FFF8F0 | #F0F8FF | |
clWebGhostWhite | $FFF8F8 | #F8F8FF | |
clWebLavender | $FAE6E6 | #E6E6FA | |
clWebSeashell | $EEF5FF | #FFF5EE | |
clWebLightYellow | $E0FFFF | #FFFFE0 | |
clWebPapayaWhip | $D5EFFF | #FFEFD5 | |
clWebNavajoWhite | $ADDEFF | #FFDEAD | |
clWebMoccasin | $B5E4FF | #FFE4B5 | |
clWebBurlywood | $87B8DE | #DEB887 | |
clWebAzure | $FFFFF0 | #F0FFFF | |
clWebMintcream | $FAFFF5 | #F5FFFA | |
clWebHoneydew | $F0FFF0 | #F0FFF0 | |
clWebLinen | $E6F0FA | #FAF0E6 | |
clWebLemonChiffon | $CDFAFF | #FFFACD | |
clWebBlanchedAlmond | $CDEBFF | #FFEBCD | |
clWebBisque | $C4E4FF | #FFE4C4 | |
clWebPeachPuff | $B9DAFF | #FFDAB9 | |
clWebTan | $8CB4D2 | #D2B48C | |
clWebYellow | $00FFFF | #FFFF00 | |
clWebDarkOrange | $008CFF | #FF8C00 | |
clWebRed | $0000FF | #FF0000 | |
clWebDarkRed | $00008B | #8B0000 | |
clWebMaroon | $000080 | #800000 | |
clWebIndianRed | $5C5CCD | #CD5C5C | |
clWebSalmon | $7280FA | #FA8072 | |
clWebCoral | $507FFF | #FF7F50 | |
clWebGold | $00D7FF | #FFD700 | |
clWebTomato | $4763FF | #FF6347 | |
clWebCrimson | $3C14DC | #DC143C | |
clWebBrown | $2A2AA5 | #A52A2A | |
clWebChocolate | $1E69D2 | #D2691E | |
clWebSandyBrown | $60A4F4 | #F4A460 | |
clWebLightSalmon | $7AA0FF | #FFA07A | |
clWebLightCoral | $8080F0 | #F08080 | |
clWebOrange | $00A5FF | #FFA500 | |
clWebOrangeRed | $0045FF | #FF4500 | |
clWebFirebrick | $2222B2 | #B22222 | |
clWebSaddleBrown | $13458B | #8B4513 | |
clWebSienna | $2D52A0 | #A0522D | |
clWebPeru | $3F85CD | #CD853F | |
clWebDarkSalmon | $7A96E9 | #E9967A | |
clWebRosyBrown | $8F8FBC | #BC8F8F | |
clWebPaleGoldenrod | $AAE8EE | #EEE8AA | |
clWebLightGoldenrodYellow | $D2FAFA | #FAFAD2 | |
clWebOlive | $008080 | #808000 | |
clWebForestGreen | $228B22 | #228B22 | |
clWebGreenYellow | $2FFFAD | #ADFF2F | |
clWebChartreuse | $00FF7F | #7FFF00 | |
clWebLightGreen | $90EE90 | #90EE90 | |
clWebAquamarine | $D4FF7F | #7FFFD4 | |
clWebSeaGreen | $578B2E | #2E8B57 | |
clWebGoldenRod | $20A5DA | #DAA520 | |
clWebKhaki | $8CE6F0 | #F0E68C | |
clWebOliveDrab | $238E6B | #6B8E23 | |
clWebGreen | $008000 | #008000 | |
clWebYellowGreen | $32CD9A | #9ACD32 | |
clWebLawnGreen | $00FC7C | #7CFC00 | |
clWebPaleGreen | $98FB98 | #98FB98 | |
clWebMediumAquamarine | $AACD66 | #66CDAA | |
clWebMediumSeaGreen | $71B33C | #3CB371 | |
clWebDarkGoldenRod | $0B86B8 | #B8860B | |
clWebDarkKhaki | $6BB7BD | #BDB76B | |
clWebDarkOliveGreen | $2F6B55 | #556B2F | |
clWebDarkgreen | $006400 | #006400 | |
clWebLimeGreen | $32CD32 | #32CD32 | |
clWebLime | $00FF00 | #00FF00 | |
clWebSpringGreen | $7FFF00 | #00FF7F | |
clWebMediumSpringGreen | $9AFA00 | #00FA9A | |
clWebDarkSeaGreen | $8FBC8F | #8FBC8F | |
clWebLightSeaGreen | $AAB220 | #20B2AA | |
clWebPaleTurquoise | $EEEEAF | #AFEEEE | |
clWebLightCyan | $FFFFE0 | #E0FFFF | |
clWebLightBlue | $E6D8AD | #ADD8E6 | |
clWebLightSkyBlue | $FACE87 | #87CEFA | |
clWebCornFlowerBlue | $ED9564 | #6495ED | |
clWebDarkBlue | $8B0000 | #00008B | |
clWebIndigo | $82004B | #4B0082 | |
clWebMediumTurquoise | $CCD148 | #48D1CC | |
clWebTurquoise | $D0E040 | #40E0D0 | |
clWebCyan | $FFFF00 | #00FFFF | |
clWebAqua | $FFFF00 | #00FFFF | |
clWebPowderBlue | $E6E0B0 | #B0E0E6 | |
clWebSkyBlue | $EBCE87 | #87CEEB | |
clWebRoyalBlue | $E16941 | #4169E1 | |
clWebMediumBlue | $CD0000 | #0000CD | |
clWebMidnightBlue | $701919 | #191970 | |
clWebDarkTurquoise | $D1CE00 | #00CED1 | |
clWebCadetBlue | $A09E5F | #5F9EA0 | |
clWebDarkCyan | $8B8B00 | #008B8B | |
clWebTeal | $808000 | #008080 | |
clWebDeepskyBlue | $FFBF00 | #00BFFF | |
clWebDodgerBlue | $FF901E | #1E90FF | |
clWebBlue | $FF0000 | #0000FF | |
clWebNavy | $800000 | #000080 | |
clWebDarkViolet | $D30094 | #9400D3 | |
clWebDarkOrchid | $CC3299 | #9932CC | |
clWebMagenta | $FF00FF | #FF00FF | |
clWebFuchsia | $FF00FF | #FF00FF | |
clWebDarkMagenta | $8B008B | #8B008B | |
clWebMediumVioletRed | $8515C7 | #C71585 | |
clWebPaleVioletRed | $9370DB | #DB7093 | |
clWebBlueViolet | $E22B8A | #8A2BE2 | |
clWebMediumOrchid | $D355BA | #BA55D3 | |
clWebMediumPurple | $DB7093 | #9370DB | |
clWebPurple | $800080 | #800080 | |
clWebDeepPink | $9314FF | #FF1493 | |
clWebLightPink | $C1B6FF | #FFB6C1 | |
clWebViolet | $EE82EE | #EE82EE | |
clWebOrchid | $D670DA | #DA70D6 | |
clWebPlum | $DDA0DD | #DDA0DD | |
clWebThistle | $D8BFD8 | #D8BFD8 | |
clWebHotPink | $B469FF | #FF69B4 | |
clWebPink | $CBC0FF | #FFC0CB | |
clWebLightSteelBlue | $DEC4B0 | #B0C4DE | |
clWebMediumSlateBlue | $EE687B | #7B68EE | |
clWebLightSlateGray | $998877 | #778899 | |
clWebWhite | $FFFFFF | #FFFFFF | |
clWebLightgrey | $D3D3D3 | #D3D3D3 | |
clWebGray | $808080 | #808080 | |
clWebSteelBlue | $B48246 | #4682B4 | |
clWebSlateBlue | $CD5A6A | #6A5ACD | |
clWebSlateGray | $908070 | #708090 | |
clWebWhiteSmoke | $F5F5F5 | #F5F5F5 | |
clWebSilver | $C0C0C0 | #C0C0C0 | |
clWebDimGray | $696969 | #696969 | |
clWebMistyRose | $E1E4FF | #FFE4E1 | |
clWebDarkSlateBlue | $8B3D48 | #483D8B | |
clWebDarkSlategray | $4F4F2F | #2F4F4F | |
clWebGainsboro | $DCDCDC | #DCDCDC | |
clWebDarkGray | $A9A9A9 | #A9A9A9 | |
clWebBlack | $000000 | #000000 |
unit Unit1;interfaceuses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls;type TForm1 = class(TForm) Button1: TButton; procedure Button1Click(Sender: TObject); end;var Form1: TForm1;implementation{$R *.dfm}{这是专为这个表写的一个转换函数}function HexColorToHtmlColor(s: string): string;var i: Integer; R,G,B: Byte;begin i := StrToInt(s); R := i and $FF; G := (i shr 8) and $FF; B := (i shr 16) and $FF; Result := #35 + Format('%.2x%.2x%.2x',[R,G,B]);end;procedure TForm1.Button1Click(Sender: TObject);var List: TStringList; i: Integer; s1,s2,s3: string;begin List := TStringList.Create; List.LoadFromFile('c:\temp\Delphi.txt'); for i := 0 to List.Count - 1 do begin s1 := List.Names[i]; s2 := List.ValueFromIndex[i]; s3 := HexColorToHtmlColor(s2); List[i] := '<tr><td>' + s1 + '</td><td style="background-color:' + s3 + '"></td><td>' + s2 + '</td><td>' + s3 + '</td></tr>'; end; List.SaveToFile('c:\temp\Html.txt'); List.Free;end;end.
联系客服