Einzelnen Beitrag anzeigen

Muetze1
(Gast)

n/a Beiträge
 
#7

Re: nach dem drehen speichern

  Alt 13. Okt 2004, 09:49
Moin!

Delphi-Quellcode:
procedure TForm1.FileListBox1Click(Sender: TObject);
var
  Jpeg: TJpegImage;
  bmp: TBitmap;
begin
  Jpeg:=TJpegImage.Create;
  bmp := TBitmap.Create;

  try
    jpeg.LoadFromFile(FileListBox1.FileName);
    bmp.Assign(jpeg);
    Image1.Picture.Assign(bmp);

  finally
    bmp.Free;
    jpeg.free;
  end;
end;



procedure TForm1.Image1ContextPopup(Sender: TObject; MousePos: TPoint;
  var Handled: Boolean);
var
  Jpeg: TJpegImage;
begin
  Jpeg:=TJpegImage.Create;

  Try
    Drehen90Grad(Image1.Picture.Bitmap);
    Jpeg.Assign(Image1.Picture.Bitmap);

    Jpeg.SaveToFile(FileListBox1.FileName);
  Finally
    Jpeg.Free;
  End;
end;
MfG
Muetze1
  Mit Zitat antworten Zitat