mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-14 12:09:30 +02:00
parent
b13056fcf2
commit
638b81dcaa
@ -1730,7 +1730,7 @@ begin
|
|||||||
exit;
|
exit;
|
||||||
// only create objects when needed
|
// only create objects when needed
|
||||||
if FTextMappingList<>nil then
|
if FTextMappingList<>nil then
|
||||||
Exception.Create('TPDFFont.PrepareTextMapping already created');
|
EPDF.Create('TPDFFont.PrepareTextMapping already created');
|
||||||
FTextMappingList := TTextMappingList.Create;
|
FTextMappingList := TTextMappingList.Create;
|
||||||
FTrueTypeFile := TTFFileInfo.Create;
|
FTrueTypeFile := TTFFileInfo.Create;
|
||||||
if FFontStream<>nil then
|
if FFontStream<>nil then
|
||||||
@ -1832,9 +1832,9 @@ procedure TPDFFont.LoadFromStream(aStream: TStream);
|
|||||||
begin
|
begin
|
||||||
if FFontStream=aStream then Exit;
|
if FFontStream=aStream then Exit;
|
||||||
if FFontStream<>nil then
|
if FFontStream<>nil then
|
||||||
raise Exception.Create('TPDFFont.SetFontStream has already a stream');
|
raise EPDF.Create('TPDFFont.SetFontStream has already a stream');
|
||||||
if FFontFilename<>'' then
|
if FFontFilename<>'' then
|
||||||
raise Exception.Create('TPDFFont.SetFontStream has already a file');
|
raise EPDF.Create('TPDFFont.SetFontStream has already a file');
|
||||||
FFontStream:=TMemoryStream.Create;
|
FFontStream:=TMemoryStream.Create;
|
||||||
FFontStream.CopyFrom(aStream,aStream.Size-aStream.Position);
|
FFontStream.CopyFrom(aStream,aStream.Size-aStream.Position);
|
||||||
PrepareTextMapping;
|
PrepareTextMapping;
|
||||||
@ -3881,7 +3881,7 @@ var
|
|||||||
CompressedStream: TMemoryStream;
|
CompressedStream: TMemoryStream;
|
||||||
begin
|
begin
|
||||||
if ADocument.Fonts[AFontNum].SubsetFont = nil then
|
if ADocument.Fonts[AFontNum].SubsetFont = nil then
|
||||||
raise Exception.Create('WriteEmbeddedSubsetFont: SubsetFont stream was not initialised.');
|
raise EPDF.Create('WriteEmbeddedSubsetFont: SubsetFont stream was not initialised.');
|
||||||
WriteString(CRLF+'stream'+CRLF, AOutStream);
|
WriteString(CRLF+'stream'+CRLF, AOutStream);
|
||||||
PS := AOutStream.Position;
|
PS := AOutStream.Position;
|
||||||
if poCompressFonts in ADocument.Options then
|
if poCompressFonts in ADocument.Options then
|
||||||
|
Loading…
Reference in New Issue
Block a user