(五)TMainForm的事件和函数 和 TPrinter打印应用
////////// 打印知识
[菜单项file打印] 事件:
procedure TMainForm.filePrintItemClick(Sender: TObject);
begin
{kh1}print;{kh2}
Screen.Cursor := crHourglass;
try
if MDIChildCount0 then
with ActiveMDIChild as TMDIChild do begin
with Printer do begin
BeginDoc; //开始打印
Canvas.Draw(0,0,Image...[ 查看全文 ]