Files correlati : Ricompilazione Demo : [ ] Commento : Riportata la versione 3.1 patch 766 git-svn-id: svn://10.65.10.50/trunk@14628 c028cbd2-c16b-5b4b-a496-9718f37d4682
61 lines
2.4 KiB
ObjectPascal
Executable File
61 lines
2.4 KiB
ObjectPascal
Executable File
unit Unit1;
|
|
|
|
interface
|
|
|
|
uses
|
|
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
|
|
StdCtrls, Buttons;
|
|
|
|
type
|
|
TForm1 = class(TForm)
|
|
Label1: TLabel;
|
|
BitBtn1: TBitBtn;
|
|
BitBtn2: TBitBtn;
|
|
procedure BitBtn2Click(Sender: TObject);
|
|
procedure BitBtn1Click(Sender: TObject);
|
|
private
|
|
{ Private declarations }
|
|
public
|
|
{ Public declarations }
|
|
end;
|
|
|
|
var
|
|
Form1: TForm1;
|
|
|
|
implementation
|
|
|
|
{$R *.DFM}
|
|
|
|
function A_Set_Darkness ( darkness:integer):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_CreatePrn ( selection:integer;FileName:pchar):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_Print_Out ( width,height,copies,amount:integer):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_Prn_Text ( x,y,ori,font,typee,hor_factor,ver_factor:integer;mode:char;numeric:integer;data:pchar):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_Prn_Barcode ( x,y,ori:integer;typee:char;narrow,width,height:integer;mode:char;numeric:integer;data:pchar):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_Prn_Text_TrueType ( x,y,FSize:integer;FType:pchar;Fspin,FWeight,FItalic,FUnline,FStrikeOut:integer;id_name,data:pchar;mem_mode:integer):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_Get_Graphic ( x,y,mem_mode:integer;format:char;filename:pchar):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_Draw_Box ( mode, x, y, width, height, top, side:integer):integer;stdcall;external 'WINPPLA.DLL';
|
|
function A_Draw_Line (mode, x, y, width, height:integer):integer;stdcall;external 'WINPPLA.DLL';
|
|
Procedure A_ClosePrn ();stdcall;external 'WINPPLA.DLL';
|
|
|
|
procedure TForm1.BitBtn2Click(Sender: TObject);
|
|
begin
|
|
Form1.Close;
|
|
end;
|
|
|
|
procedure TForm1.BitBtn1Click(Sender: TObject);
|
|
begin
|
|
A_CreatePrn(1, 'ppla.txt');
|
|
A_Set_Darkness(12);
|
|
A_Get_Graphic(20, 10, 1, 'B', pchar('bb.bmp'));
|
|
A_Prn_Barcode(20, 70, 1, 'A', 0, 0, 20, 'b', 1, pchar('ABCD'));
|
|
A_Prn_Text(20, 55, 1, 9, 0, 1, 1, 'n', 2, pchar('ComScience PPLA Charlie Mei'));
|
|
A_Prn_Text_TrueType(20, 120, 40, pchar('Times New Roman'), 1, 400, 0, 0, 0, pchar('AA'), pchar('Library Test'), 1);
|
|
A_Prn_Text_TrueType(20, 100, 40, pchar('Arial'), 1, 400, 0, 0, 0, pchar('AB'), pchar('Dlephi Linking Succeed'), 1);
|
|
A_Draw_Box(65,50,30,100,50,2,3);
|
|
A_Draw_Line(65,40,50,120,3);
|
|
A_Print_Out(1, 1, 1, 1);
|
|
A_ClosePrn;
|
|
end;
|
|
|
|
end.
|