delphi HTML 코드

12061 단어 Delphi
################################ ################################################

{
//---------------------------------------------------------------------------------------
  <FONT face= >This A Text</FONT>
  <FONT size=1><SPAN style="FONT-SIZE: 100pt"><P>This A Text</P></SPAN></FONT>
//---------------------------------------------------------------------------------------
      <STRONG>This A Text</STRONG>
      <EM>This A Text</EM>
    <U>This A Text</U>
    <S>This A Text</S>  
//---------------------------------------------------------------------------------------
   <FONT color=#ff0000>This A Text</FONT>
<FONT style="BACKGROUND-COLOR: #0000ff">This A Text</FONT>  
//---------------------------------------------------------------------------------------
}


//--------------------------------------------------------------------------------------- 
{
HTML   -     PasteHTML
//

             <p>This Is a Text</p>
       <pre>This Is a Text</pre>
             <address>This Is a Text</address>
1            <h1>This Is a Text</h1>
2            <h2>This Is a Text</h2>
3            <h3>This Is a Text</h3>
4            <h4>This Is a Text</h4>
5            <h5>This Is a Text</h5>
6            <h6>This Is a Text</h6>
     <ol><li><p>This Is a Text</p></li></ol>
<ul><li><p>This Is a Text</p></li></ul>
         <dir><li><p>This Is a Text</p></li></dir>
         <menu><li><p>This Is a Text</p></li></menu>
         <dl><dt><h2>This Is a Text</h2></dt></dl>
             <dl><dd><h2>This Is a Text</h2></dd></dl>
             <dl><dd><p>This Is a Text</p></dd></dl>
}

//--------------------------------------------------------------------------------------- 

//--------------------------------------------------------------------------------------- 
{
    <P align=left>This Is A Text</P>
    <P align=center>This Is A Text</P>
    <P align=right>This Is A Text</P>
  <p align="justify">This Is A Text</p>
}

//---------------------------------------------------------------------------------------

//--------------------------------------------------------------------------------------- 
{  
    <OL><LI> This Is A Text</LI></OL>
    <UL><LI> This Is A Text</LI></UL>
}

//--------------------------------------------------------------------------------------- 

//--------------------------------------------------------------------------------------- 
{


//--------------------------------------------------------------------------------------- 
// 2
  <BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr>
  <BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr>
    <P style="MARGIN-RIGHT: 0px" dir=ltr>This Is A Text</P></BLOCKQUOTE></BLOCKQUOTE>
//     
    <P style="MARGIN-RIGHT: 0px" dir=ltr>This Is A Text</P>

//---------------------------------------------------------------------------------------     

TAB   This Is A Text    //   TAB tab 2
}


//--------------------------------------------------------------------------------------- 
/ {
     <sup>aaaaaaaaa</sup>
    <sub>aaaaaaaaa</sub>
      
}

//--------------------------------------------------------------------------------------- 

WEB {
WEB          <BODY bgColor=#000080>
WEB      <BODY background=C:\1.jpg >


}

//--------------------------------------------------------------------------------------- 

{
<IMG border=0 hspace=0 alt="" align=baseline src="C:\1.jpg">    


}

//--------------------------------------------------------------------------------------- 

{


//title
//HTTPS https://
<a href="https://www.baidu.com" title=" ">Hello</a>
//FILE file://
<a href="file://C:/1.avi" title=" ">Hello</a>
//FTP ftp:///
<a href="ftp:///C:/1.avi" title=" ">Hello</a>
//HTTP  http:///
<a href="http:///C:/1.avi" title=" ">Hello</a>
//   mailto:  MainTO OutLook Express
<a href="mailto:[email protected]" title=" ">Hello</a>
// news:/
<a href="news:/C:/1.avi" title=" ">Hello</a>
//Telnet  telnet:/
<a href="telnet:/C:/1.avi" title=" ">Hello</a>
// /
<a href="/C:/1.avi" title="Hint ">Hello</a>
}

//--------------------------------------------------------------------------------------- 

{

}

//--------------------------------------------------------------------------------------- 

{
media
real
flash
}


//--------------------------------------------------------------------------------------- 

{


}

//--------------------------------------------------------------------------------------- 

//--------------------------------------------------------------------------------------- 
HTML {

}


//--------------------------------------------------------------------------------------- 
// 1

//--------------------------------------------------------------------------------------- 
{









}



{









}

//--------------------------------------------------------------------------------------- 
{







}

//--------------------------------------------------------------------------------------- 

################################ ################################################











//--------------------------------------------------------------------------------------- 
//--------------------------------------------------------------------------------------- 

1
2 HTML
3



//--------------------------------------------------------------------------------------- 
//
function GetSelText(): string;
begin
  Result :=( (Form1.WebBrowser1.Document as IHTMLDocument2).selection.createRange as IHtmlTxtRange).text;
end;
//--------------------------------------------------------------------------------------- 
// HTML
procedure SetSelHtmlText(s: string);
begin
  ( (Form1.WebBrowser1.Document as IHTMLDocument2).selection.createRange as IHtmlTxtRange).pasteHTML(s);
end;
//--------------------------------------------------------------------------------------- 
//  
procedure SetSelection(Start,Length:integer);
var
  TextRange:IHtmlTxtRange;
  Doc: IHtmlDocument2;
begin
  (Form1.WebBrowser1.Document as IHTMLDocument2).selection.empty;
  TextRange :=(Form1.WebBrowser1.Document as IHTMLDocument2).selection.createRange as IHtmlTxtRange;
  TextRange.collapse(true);
  TextRange.moveEnd( 'character',Start +Length);
  TextRange.moveStart( 'character',Start);
  TextRange.select;
end;
//--------------------------------------------------------------------------------------- 
//



//--------------------------------------------------------------------------------------- 
// HTML



//---------------------------------------------------------------------------------------
Wiz

좋은 웹페이지 즐겨찾기