1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
|
procedure TFormInventaire.RaveGridCreate(rvBand : TRaveBand; myFont : TRaveFontMaster);
var i : Word;
left,top,height,width : Double;
myRect : TRaveRectangle;
myText : TRaveText;
begin
for i:=1 to 18 do
begin
width:=10.2;
left:=1+(width*(i-1));
top:=0;
height:=5.6;
// rectangle du haut myRect:=TRaveRectangle(rvBand.CreateChild(TRaveRectangle,'RP'+inttostr(i)));
myRect.Top:=top/25.4;
myRect.Left:=Left/25.4;
myRect.Width:=width/25.4;
myRect.Height:=Height/25.4;
// texte rectangle haut
myText:=TRaveText(rvBand.CreateChild(TRaveText,'TP'+inttostr(i),(left+1)/25.4,(top+1)/25.4,(width-2)/25.4,(Height-2)/25.4));
myText.FontMirror:=myFont;
myText.FontJustify:=pjCenter;
myText.Text:='340'; // test
top:=top+Height;
// rectangle du bas myRect:=TRaveRectangle(rvBand.CreateChild(TRaveRectangle,'RP'+inttostr(i)));
myRect.Top:=top/25.4;
myRect.Left:=Left/25.4;
myRect.Width:=width/25.4;
myRect.Height:=Height/25.4;
// texte rectangle bas
myText:=TRaveText(rvBand.CreateChild(TRaveText,'TP'+inttostr(i),(left+1)/25.4,(top+1)/25.4,(width-2)/25.4,(Height-2)/25.4));
myText.FontMirror:=myFont;
myText.FontJustify:=pjRight;
myText.Text:='10'; // test
end;
end; |
Partager