分享

如何在 "万一的 Delphi 博客" 回复自动格式化的着色代码?

 独孤求财 2012-03-28

1、先提交回复, 第一次提交时先不要代码, 可有文字;

2、再修改回复, 修改时包其中的 <br/> 换行标记, 也可以用 <br/> 添加新的换行;

3、然后按下面方式提交回复: <pre class=Delphi style="font-size:13.8px; line-height: 132%;"> <hr> //Delphi 代码... <hr> </pre> <pre class=cpp style="font-size:13.8px; line-height: 132%;"> <hr> //C/C++ 代码... <hr> </pre> <pre class=cs style="font-size:13.8px; line-height: 132%;"> <hr> //C# 代码... <hr> </pre>

注意: 重新开启才能看到效果; 建议把上面文本加入到输入法的自定义文本里面.

查看回复效果: http://www.cnblogs.com/del/archive/2009/01/03/1367468.html#1419896
//Delphi 代码:
program Project1;

{$APPTYPE CONSOLE}

uses
  SysUtils;

begin
  try
    Writeln('Delphi 2009');
    Readln;
  except
    on E:Exception do
      Writeln(E.Classname, ': ', E.Message);
  end;
end.


//C/C++ 代码: #include <stdio.h> #pragma hdrstop #include <tchar.h> #pragma argsused int _tmain(int argc, _TCHAR* argv[]) {   printf("C++Builder 2009");   getchar();   return 0; }

//C# 代码: using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace ConsoleApplication1 {   class Program   {     static void Main(string[] args)     {       Console.WriteLine("Visual C# 2008");       Console.ReadLine();     }   } }

    本站是提供个人知识管理的网络存储空间,所有内容均由用户发布,不代表本站观点。请注意甄别内容中的联系方式、诱导购买等信息,谨防诈骗。如发现有害或侵权内容,请点击一键举报。
    转藏 分享 献花(0

    0条评论

    发表

    请遵守用户 评论公约