📄 un_css.pas
字号:
SHtmlFile.Add('</div>');
SHtmlFile.Add('</div>');
end;
SHtmlFile.Add(' </div>');
SHtmlFile.Add(' </center>');
SHtmlFile.Add(' </body></html>');
SHtmlFile.SaveToFile(ExtractFilePath(Application.ExeName)+'Temp.htm');
FMRss.WebBrowser1.Navigate(ExtractFilePath(Application.ExeName)+'Temp.htm');
SHtmlFile.Free;
end;
procedure SaveTempHTML5(A5, B5, C5, D5: TstringList;
TitleName5: string; Counts5: integer);
var
SHtmlFile:TStringList;
i:integer;
begin
SHtmlFile:=TStringList.Create ;
SHtmlFile.Clear;
SHtmlFile.Add('<html><head><title></title><meta http-equiv="Content-Type" content="text/html; charset=gb2312">');
SHtmlFile.Add('<style type="text/css">');
SHtmlFile.Add(' td,p,li,input,select,div,span {font-size:12px;}');
SHtmlFile.Add(' table,td,img,div,span{border: none;margin: 0px 0px 0px 0px;padding: 0px 0px 0px 0px;}');
SHtmlFile.Add(' .f10 {font-size: 10px;}');
SHtmlFile.Add(' .f12 {font-size: 12px;}');
SHtmlFile.Add(' .f14 {font-size: 14px;}');
SHtmlFile.Add(' .f16 {font-size: 16px;}');
SHtmlFile.Add(' .lh17 {line-height:17px;}');
SHtmlFile.Add(' .lh19 {line-height:19px;}');
SHtmlFile.Add(' A:link {color:#00f;}');
SHtmlFile.Add(' A:visited {color:#800080;}');
SHtmlFile.Add(' A:active {color:#f00;}');
SHtmlFile.Add(' A:hover {color:#f00;}');
SHtmlFile.Add(' .tree a:link {text-decoration: none;color:#CC0085;font-weight: bold;}');
SHtmlFile.Add(' .tree a:visited {text-decoration: none;color:#CC0085;font-weight: normal;}');
SHtmlFile.Add(' .tree a:active,.tree a:hover {text-decoration: none;color:#FF98CD;}');
SHtmlFile.Add(' .tree {color:#222;line-height:19px;width:96%;text-align:left;}');
SHtmlFile.Add(' .tree #channel{font-size:16px;font-weight:bold;color:#CC0085;text-align:center;padding:10px 0 10px 0;border:1px solid #D2C9CC;border-top:5px solid #666666;clear:both;margin-bottom:5px;margin-top:5px;background-color:#F8F4F5;}');
SHtmlFile.Add(' .tree #block{margin-bottom:5px;border:1px solid #D2C9CC;background-color:#fff;clear:both;}');
SHtmlFile.Add(' .tree #title{font-weight:bold;font-size:14px;clear:both;padding:7px 0 5px 5px;background-color:#F8F4F5;margin-bottom:7px;color:#CC0085;}');
SHtmlFile.Add(' .tree #author{color:#808080;float:left;}');
SHtmlFile.Add(' .tree #time{color:#808080;float:right;}');
SHtmlFile.Add(' .tree #description{clear:both;}');
SHtmlFile.Add(' .tree #readall{text-align:right;font-weight:bold;color:#CC0085;}');
SHtmlFile.Add(' .tree #readall a{text-decoration:underline;font-weight: bold;}');
SHtmlFile.Add(' .subBlk{padding:7px 10px 7px 10px;}');
SHtmlFile.Add('</style>');
SHtmlFile.Add('</head>');
SHtmlFile.Add('<body bgcolor=#EDE1E5 topmargin=5 marginheight=5 leftmargin=5 marginwidth=5>');
SHtmlFile.Add('<center>');
SHtmlFile.Add('<div id='''+'list'''+' class='''+'tree'''+'>');
if TitleName5<>'' then
SHtmlFile.Add('<div id='''+'channel'''+'>'+TitleName5+'</div>');
for i:=0 to counts5-1 do
begin
SHtmlFile.Add('<div id='''+'block'''+'>');
SHtmlFile.Add(' <div id='''+'title'''+'>'+'·<a href='+D5.Strings[i]+' target=_blank>'+A5.Strings[i]+'</a></div>');
SHtmlFile.Add(' <div class='''+'subBlk'''+'>');
if B5.Count=D5.Count then
SHtmlFile.Add(' <div id='''+'time'''+'>'+B5.Strings[i]+'</div>')
else
SHtmlFile.Add(' <div id='''+'time'''+'>'+' '+'</div>');
if C5.Count=D5.Count then
SHtmlFile.Add(' <div id='''+'description'''+'> '+C5.Strings[i]+'</div><p>')
else
SHtmlFile.Add(' <div id='''+'description'''+'> '+'<没有摘要说明>'+'</div><p>');
SHtmlFile.Add(' <div id='''+'readall'''+'>[<a href='+D5.Strings[i]+' target=_blank>阅读全文</a>]</div>');
SHtmlFile.Add('</div>');
SHtmlFile.Add('</div>');
end;
SHtmlFile.Add(' </div>');
SHtmlFile.Add(' </center>');
SHtmlFile.Add(' </body></html>');
SHtmlFile.SaveToFile(ExtractFilePath(Application.ExeName)+'Temp.htm');
FMRss.WebBrowser1.Navigate(ExtractFilePath(Application.ExeName)+'Temp.htm');
SHtmlFile.Free;
end;
procedure SaveTempHTML6(A6, B6, C6, D6: TstringList;
TitleName6: string; Counts6: integer);
var
SHtmlFile:TStringList;
i:integer;
begin
SHtmlFile:=TStringList.Create ;
SHtmlFile.Clear;
SHtmlFile.Add('<html><head><title></title><meta http-equiv="Content-Type" content="text/html; charset=gb2312">');
SHtmlFile.Add('<style type="text/css">');
SHtmlFile.Add(' td,p,li,input,select,div,span {font-size:12px;}');
SHtmlFile.Add(' table,td,img,div,span{border: none;margin: 0px 0px 0px 0px;padding: 0px 0px 0px 0px;}');
SHtmlFile.Add(' .f10 {font-size: 10px;}');
SHtmlFile.Add(' .f12 {font-size: 12px;}');
SHtmlFile.Add(' .f14 {font-size: 14px;}');
SHtmlFile.Add(' .f16 {font-size: 16px;}');
SHtmlFile.Add(' .lh17 {line-height:17px;}');
SHtmlFile.Add(' .lh19 {line-height:19px;}');
SHtmlFile.Add(' A:link {color:#00f;}');
SHtmlFile.Add(' A:visited {color:#800080;}');
SHtmlFile.Add(' A:active {color:#f00;}');
SHtmlFile.Add(' A:hover {color:#f00;}');
SHtmlFile.Add(' .tree a:link {text-decoration: underline;color:#0C365E;font-weight: bold;} ');
SHtmlFile.Add(' .tree a:visited {text-decoration: underline;color:#0C365E;font-weight: normal;} ');
SHtmlFile.Add(' .tree a:active,.tree a:hover {text-decoration: underline;color:#FD0100;} ');
SHtmlFile.Add(' .tree {color:#222;line-height:19px;width:96%;text-align:left;}');
SHtmlFile.Add(' .tree #channel{font-size:16px;font-weight:bold;color:#0C365E;;padding:8px 0 10px 15px;border:1px dotted #B6B6B6;clear:both;margin-bottom:8px;margin-top:8px;background-color:#fff;}');
SHtmlFile.Add(' .tree #block{margin-bottom:9px;padding-top:10px;border:1px dotted #B6B6B6;padding:9px 9px 9px 9px;background-color:#fff;}');
SHtmlFile.Add(' .tree #title{font-weight:bold;font-size:14px;clear:both;margin-bottom:5px;margin-top:5px;color:#0C365E}');
SHtmlFile.Add(' .tree #author{color:#808080;float:left;margin-top:10px;}');
SHtmlFile.Add(' .tree #time{color:#808080;float:right;margin-top:10px;}');
SHtmlFile.Add(' .tree #description{clear:both;}');
SHtmlFile.Add(' .tree #readall{text-align:right;font-weight:bold;}');
SHtmlFile.Add(' .tree #readall a{font-weight:bold;}');
SHtmlFile.Add('</style>');
SHtmlFile.Add('</head>');
SHtmlFile.Add('<body bgcolor=#DAE5E9 topmargin=5 marginheight=5 leftmargin=5 marginwidth=5>');
SHtmlFile.Add('<center>');
SHtmlFile.Add('<div id='''+'list'''+' class='''+'tree'''+'>');
if TitleName6<>'' then
SHtmlFile.Add('<div id='''+'channel'''+'>'+TitleName6+'</div>');
for i:=0 to counts6-1 do
begin
SHtmlFile.Add('<div id='''+'block'''+'>');
SHtmlFile.Add(' <div id='''+'title'''+'>'+'·<a href='+D6.Strings[i]+' target=_blank>'+A6.Strings[i]+'</a></div>');
if B6.Count=D6.Count then
SHtmlFile.Add(' <div id='''+'time'''+'>'+B6.Strings[i]+'</div>')
else
SHtmlFile.Add(' <div id='''+'time'''+'>'+' '+'</div>');
if C6.Count=D6.Count then
SHtmlFile.Add(' <div id='''+'description'''+'> '+C6.Strings[i]+'</div><p>')
else
SHtmlFile.Add(' <div id='''+'description'''+'> '+'<没有摘要说明>'+'</div><p>');
SHtmlFile.Add(' <div id='''+'readall'''+'>[<a href='+D6.Strings[i]+' target=_blank>阅读全文</a>]</div>');
SHtmlFile.Add('</div>');
end;
SHtmlFile.Add(' </div>');
SHtmlFile.Add(' </center>');
SHtmlFile.Add(' </body></html>');
SHtmlFile.SaveToFile(ExtractFilePath(Application.ExeName)+'Temp.htm');
FMRss.WebBrowser1.Navigate(ExtractFilePath(Application.ExeName)+'Temp.htm');
SHtmlFile.Free;
end;
procedure SaveTempHTML7(A7, B7, C7, D7: TstringList;
TitleName7: string; Counts7: integer);
var
SHtmlFile:TStringList;
i:integer;
begin
SHtmlFile:=TStringList.Create ;
SHtmlFile.Clear;
SHtmlFile.Add('<html><head><title></title><meta http-equiv="Content-Type" content="text/html; charset=gb2312">');
SHtmlFile.Add('<style type="text/css">');
SHtmlFile.Add(' td,p,li,input,select,div,span {font-size:12px;}');
SHtmlFile.Add(' table,td,img,div,span{border: none;margin: 0px 0px 0px 0px;padding: 0px 0px 0px 0px;}');
SHtmlFile.Add(' .f10 {font-size: 10px;}');
SHtmlFile.Add(' .f12 {font-size: 12px;}');
SHtmlFile.Add(' .f14 {font-size: 14px;}');
SHtmlFile.Add(' .f16 {font-size: 16px;}');
SHtmlFile.Add(' .lh17 {line-height:17px;}');
SHtmlFile.Add(' .lh19 {line-height:19px;}');
SHtmlFile.Add(' A:link {color:#00f;}');
SHtmlFile.Add(' A:visited {color:#800080;}');
SHtmlFile.Add(' A:active {color:#f00;}');
SHtmlFile.Add(' A:hover {color:#f00;}');
SHtmlFile.Add(' .tree a:link{text-decoration: underline;color:#303392;font-weight: bold;}');
SHtmlFile.Add(' .tree a:visited {text-decoration: underline;color:#303392;font-weight: normal;}');
SHtmlFile.Add(' .tree a:active,.tree a:hover {text-decoration: none;color:#6766CE;}');
SHtmlFile.Add(' .tree {color:#464646;width:96%;text-align:left;}');
SHtmlFile.Add(' .tree #channel{font-size:16px;font-weight:bold;color:#000;text-align:center;padding:5px 0 10px 0;border-bottom:1px dotted #C0C0C0;clear:both;margin-bottom:8px;}');
SHtmlFile.Add(' .tree #block{margin-top:0px;clear:both;margin-bottom:10px;}');
SHtmlFile.Add(' .tree #title{font-weight:bold;float:left;font-size:14px;}');
SHtmlFile.Add(' .tree #author{color:#666;}');
SHtmlFile.Add(' .tree #time{color:#898989;float:left;margin-left:5px;}');
SHtmlFile.Add(' .tree #description{line-height:19px;}');
SHtmlFile.Add(' .tree #readall{text-align:right;}');
SHtmlFile.Add(' .blkDes{border:1px solid #E3E3E3;margin:0 4px 0 15px;padding:7px 7px 7px 7px;display:none;clear:both;position:absolute;background-color:#fff;}');
SHtmlFile.Add('</style>');
SHtmlFile.Add('<script language='''+'javascript'''+' type='''+'text/javascript'''+'>');
SHtmlFile.Add('<!--');
SHtmlFile.Add('var count = 2;');
SHtmlFile.Add('function iniClass(){if(count<2) Show(0);}');
SHtmlFile.Add('function GetObj(objName){if(document.getElementById){return eval('''+'document.getElementById("'+''''+'+' + 'objName'+'+' + ''''+'")'''+');}else{return eval('''+'document.all.''' +'+'+ 'objName);}}');
SHtmlFile.Add('function Show(itemNo){var tempTop = GetObj('''+'i'''+'+'+'itemNo).parentElement.offsetTop + ((GetObj('''+'i'''+'+'+'itemNo).parentElement == GetObj('''+'i'''+'+'+'itemNo).parentElement.parentElement)?0:GetObj('''+'i'''+'+'+'itemNo).parentElement.parentElement.offsetTop) + GetObj('''+'i'''+'+'+'itemNo).parentElement.firstChild.offsetHeight;GetObj('''+'i'''+'+'+'itemNo).style.display = '''+'block'''+';if((tempTop+GetObj('''+'i'''+'+'+'itemNo).offsetHeight)>(document.body.scrollTop+document.body.clientHeight)&&(GetObj('''+'i'''+'+'+'itemNo).offsetHeight<document.body.clientHeight)) tempTop=tempTop-GetObj('''+'i'''+'+'+'itemNo).offsetHeight-20;GetObj('''+'i'''+'+'+'itemNo).style.top = tempTop + '''+'px'''+';}');
SHtmlFile.Add('function Hide(itemNo){if(count>1) GetObj('''+'i'''+'+'+'itemNo).style.display = '''+'none'''+';}');
SHtmlFile.Add('//-->');
SHtmlFile.Add('</script>');
SHtmlFile.Add('</head>');
SHtmlFile.Add('<body bgcolor=#F0EFF5 topmargin=5 marginheight=5 leftmargin=5 marginwidth=5 onload='''+'iniClass()'''+'>');
SHtmlFile.Add('<center>');
SHtmlFile.Add('<div id='''+'list'''+' class='''+'tree'''+'>');
if TitleName7<>'' then
SHtmlFile.Add('<div id='''+'channel'''+'>'+TitleName7+'</div>');
for i:=0 to Counts7-1 do
begin
SHtmlFile.Add('<div id='''+'block'''+'>');
SHtmlFile.Add('<div id='''+'title'''+' onMouseOver='''+'Show('+inttostr(i)+')'''+' onMouseOut='''+'Hide('+inttostr(i)+')'''+'>·<a href='+D7.Strings[i]+' target=_blank>'+A7.Strings[i]+'</a></div>');
if B7.Count=D7.Count then
SHtmlFile.Add('<div id='''+'time'''+'>'+B7.Strings[i]+'</div>')
else
SHtmlFile.Add(' <div id='''+'time'''+'>'+' '+'</div>');
SHtmlFile.Add('<div id='''+'i'+inttostr(i)+''''+' class='''+'blkDes'''+'>');
if C7.Count=D7.Count then
SHtmlFile.Add(' <div id='''+'description'''+'> '+C7.Strings[i]+'</div><p>')
else
SHtmlFile.Add(' <div id='''+'description'''+'> '+'<没有摘要说明>'+'</div><p>');
SHtmlFile.Add(' </div>');
SHtmlFile.Add('</div>');
END;
SHtmlFile.Add('</div></center></body></html>');
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -