Comments (4)
Confirmed. I have this problem when I use:
HtmlViewer1.Print();
Under Lazarus 1.2.6 FPC 2.6.4
The problem is in
ThtDocument.Clear
... inherited Clear;
This do the print but the program crashes
I've tried your workaround and doesn't works for me, the application just crashes
from htmlviewer.
Thanks for spotting this issue.
from htmlviewer.
The error throws in PrintList.Free;
function THtmlViewer.Print(Prn: ThtPrinter; FromPage: Integer; ToPage: Integer; Mode: ThtPrintPreviewMode): Integer;
...
PrintList := ThtDocument.CreateCopy(SectionList);
try
...
finally
PrintList.Free;
end;
...
i changed this and it helps - no memory leak is produced:
procedure ThtDocument.Clear;
begin
...
if not IsCopy then
inherited Clear;
...
end;
from htmlviewer.
commit 68484f2 fixes this issue.
The issue was induced by adding TSections twice.
from htmlviewer.
Related Issues (20)
- Is font embedding supported? HOT 1
- MHT-Files supported by HTMLViewer? HOT 2
- Images can not be imported into a richedit HOT 4
- OS 12.6 Monterey: Error: Identifier not found ["FontSerif", "FontMono", "FontSans", "FontCursive", "FontHelvet"]
- PrintPreview is showing images not as it should (black box), as well as the font is different HOT 6
- 'FullDisplaySize' adds Margins on Top and Bottom (2*14px) HOT 1
- body or css background image HOT 2
- CSS Property "white-space:nowrap" does not work in THtmlViewer
- Barcode support
- Transparent in icon display bug? HOT 1
- How to use this package HOT 2
- How can i print page on Linux in Lazarus? HOT 3
- Control not working in Lazarus 3.99 on Linux. HOT 2
- How to install the components HOT 3
- How to install in C++Builder Community Edition?
- How to compile jsbesen demo with lazarus?
- Problem installing on Delphi 10.1 HOT 1
- Html Viewer for RAD Studio 12 HOT 2
- Printing problem multible documents
- Compile errors using FPC 3.3.1 / Lazarus HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from htmlviewer.