procedure DrawCadre(const X1,Y1,X2,Y2 : integer; const Model : TLineModel);
var i : integer;
begin
GotoXY(X1,Y1); write(Model[0]);
GotoXY(X1,Y2); write(Model[1]);
GotoXY(X2,Y1); write(Model[2]);
GotoXY(X2,Y2); write(Model[3]);
for i := X1+1 to X2-1 do begin
GotoXY(i,Y1); write(Model[4]);
GotoXY(i,Y2); write(Model[4]);
end;
for i := Y1+1 to Y2-1 do begin
GotoXY(X1,i); write(Model[5]);
GotoXY(X2,i); write(Model[5]);
end;
end;
mais bon ... pour une raison qui m'echape encore j'avais fait ça aussi :
Function MAJ(s : string) : string;
var x : byte;
Begin
For x := 1 to length(s) do begin
s[x] := upcase(s[x]);
end;
maj := s;
End;
elguevel
Messages postés718Date d'inscriptionjeudi 19 décembre 2002StatutMembreDernière intervention22 novembre 20163 24 juil. 2006 à 15:50
24 juil. 2006 à 17:38
type
TLineModel : array[0..5] of char;
const
BasicLine : TLineModel = ('+','+','+','+','-','|');
SimpleLine : TLineModel = (#201,#200,#187,#188,#205,#186);
DoubleLine : TLineModel = (#218,#192,#191,#217,#196,#179);
procedure DrawCadre(const X1,Y1,X2,Y2 : integer; const Model : TLineModel);
var i : integer;
begin
GotoXY(X1,Y1); write(Model[0]);
GotoXY(X1,Y2); write(Model[1]);
GotoXY(X2,Y1); write(Model[2]);
GotoXY(X2,Y2); write(Model[3]);
for i := X1+1 to X2-1 do begin
GotoXY(i,Y1); write(Model[4]);
GotoXY(i,Y2); write(Model[4]);
end;
for i := Y1+1 to Y2-1 do begin
GotoXY(X1,i); write(Model[5]);
GotoXY(X2,i); write(Model[5]);
end;
end;
mais bon ... pour une raison qui m'echape encore j'avais fait ça aussi :
Function MAJ(s : string) : string;
var x : byte;
Begin
For x := 1 to length(s) do begin
s[x] := upcase(s[x]);
end;
maj := s;
End;
24 juil. 2006 à 15:50