MiniProgramer
Messages postés37Date d'inscriptionsamedi 5 juillet 2008StatutMembreDernière intervention24 juillet 2008
-
20 juil. 2008 à 12:11
MiniProgramer
Messages postés37Date d'inscriptionsamedi 5 juillet 2008StatutMembreDernière intervention24 juillet 2008
-
20 juil. 2008 à 14:45
salut
je voudrais faire le Scrollbar max et le Scrollbar Min comme ça :
scrollbar1.Max:= Image1.Width * 2;
scrollbar1.Min:=trunc(Image1.Width / 2);
C'est Possible ?
j ai essayée comme ça ;
procedure TForm1.ScrollBar1Change(Sender: TObject);
var
ImageWidth0:=Image1.Picture.Width;// La Taille originale
Imageheight0:=Image1.Picture.height;
begin
Je voudrais faire selement zoom max 5 fois et zoom min 50%:
Scrollbar1.max := Image1.Picture*5; // zoo max : 500%
Scrollbar1.min := Trunc(Image1.Picture/2); // zoo min : 50%
C est tout pas de plus
merci tres bien pour L 'aide
j ai essayee come ca :
procedure TForm1.FormShow(Sender: TObject);
begin
Image1.Width: =Image1.Picture.Width;
Image1.Height:=Image1.Picture.Height;
Scrollbar1.Max:=Image1.Picture.Width*5;
Scrollbar1.Min:=Trunc(Image1.Picture.Width/2);
Scrollbar1.Position:=Image1.Picture.Width;
end;
procedure TForm1.ScrollBar1Change(Sender: TObject);
begin
Image1.Width:=Trunc(Image1.Picture.Width * scrollbar1.Position / Image1.Width);
end;
mais le problem:
Trunc(Image1.Picture.Width * scrollbar1.Position / Image1.Width); // peut etre 0 : (