home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 1999 January
/
Chip_1999-01_cd.bin
/
zkuste
/
delphi
/
D1
/
CALCBOX.ZIP
/
DEMO
/
SETPROPS.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1996-01-22
|
2KB
|
72 lines
unit Setprops;
interface
uses
SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls,
Forms, Dialogs, StdCtrls, Cvgcalc, ExtCtrls, Buttons;
type
TForm2 = class(TForm)
BitBtn1: TBitBtn;
BitBtn2: TBitBtn;
BitBtn3: TBitBtn;
BitBtn4: TBitBtn;
BitBtn5: TBitBtn;
BitBtn6: TBitBtn;
BitBtn7: TBitBtn;
Bevel1: TBevel;
Shape1: TShape;
CalculatorBox1: TCalculatorBox;
procedure BitBtn1Click(Sender: TObject);
procedure BitBtn2Click(Sender: TObject);
procedure BitBtn3Click(Sender: TObject);
procedure BitBtn4Click(Sender: TObject);
procedure BitBtn5Click(Sender: TObject);
procedure BitBtn6Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form2: TForm2;
implementation
{$R *.DFM}
procedure TForm2.BitBtn1Click(Sender: TObject);
begin
CalculatorBox1.Alignment := taRightJustify;
end;
procedure TForm2.BitBtn2Click(Sender: TObject);
begin
CalculatorBox1.Alignment := taLeftJustify;
end;
procedure TForm2.BitBtn3Click(Sender: TObject);
begin
CalculatorBox1.DecimalPlaces := 0;
end;
procedure TForm2.BitBtn4Click(Sender: TObject);
begin
CalculatorBox1.DecimalPlaces := 4;
end;
procedure TForm2.BitBtn5Click(Sender: TObject);
begin
if DecimalSeparator='.' then CalculatorBox1.DisplayText := '123.45'
else CalculatorBox1.DisplayText := '123,45';
end;
procedure TForm2.BitBtn6Click(Sender: TObject);
begin
CalculatorBox1.DisplayText := '67890';
end;
end.