Serg Posted June 28, 2018 Share Posted June 28, 2018 Можно ли скопировать в BMP,JPEG содержимое UniURLFrame? Link to comment Share on other sites More sharing options...
Sherzod Posted June 28, 2018 Share Posted June 28, 2018 Добрый день, Возможно Вам поможет этот демо пример ?: \FMSoft\Framework\uniGUI\Demos\Desktop\HTML2Image Link to comment Share on other sites More sharing options...
Serg Posted June 28, 2018 Author Share Posted June 28, 2018 Спасибо! Link to comment Share on other sites More sharing options...
Serg Posted June 28, 2018 Author Share Posted June 28, 2018 Но это не технологично( Exe! А к Canvas страницы можно как то долезть? Можно ли адаптировать: var bm: TBitmap; ViewObject: IViewObject; SRect: TRect; JPEG:TJPEGImage; begin if Browser.Document <> nil then try Browser.Document.QueryInterface( IViewObject, ViewObject ); if ViewObject <> nil then try bm := TBitmap.Create; bm.Width := Browser.Width; bm.Height := Browser.Height; SRect := Rect( 0, 0, bm.Width, bm.Height ); ViewObject.Draw( DVASPECT_CONTENT, 1, nil, nil, Browser.Handle, bm.Canvas.Handle, @SRect, nil, nil, 0 ); //=========== JPEG:=TJPEGImage.Create; JPEG.Assign(bm); JPEG.SaveToFile( Path ); JPEG.Free; //=========== finally bm.Free; ViewObject._Release; end; except end; Link to comment Share on other sites More sharing options...
Sherzod Posted June 28, 2018 Share Posted June 28, 2018 Если не трудно Вам, сделайте простой тестовый случай Link to comment Share on other sites More sharing options...
Serg Posted July 3, 2018 Author Share Posted July 3, 2018 Добрый день! Сделал Link to comment Share on other sites More sharing options...
Serg Posted July 3, 2018 Author Share Posted July 3, 2018 Вот файл JPEG.zip Link to comment Share on other sites More sharing options...
Sherzod Posted July 3, 2018 Share Posted July 3, 2018 Здравствуйте, Мы проанализируем Link to comment Share on other sites More sharing options...
Serg Posted July 3, 2018 Author Share Posted July 3, 2018 Спасибо! Link to comment Share on other sites More sharing options...
Serg Posted July 4, 2018 Author Share Posted July 4, 2018 Получается? Link to comment Share on other sites More sharing options...
stas Posted July 8, 2018 Share Posted July 8, 2018 И не получится, то что Вы выслали, это работа с TwebBrowser, разные принципы. Потому используйте вариант из FMSoft\Framework\uniGUI\Demos\Desktop\HTML2Image Помимо этого на wkhtmltopdf.org Есть dll, которая делает тоже самое (пробовал pdf, получилось) Использовать dll в проекте достаточно кошерно. Link to comment Share on other sites More sharing options...
Serg Posted July 9, 2018 Author Share Posted July 9, 2018 Спасибо Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now