mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-05 13:18:08 +02:00
LazReport: fix export justify from LazReport to LibreOffice Calc/MS Excel, issue #41167 by Aleksey
This commit is contained in:
parent
382516a4f2
commit
894c942697
@ -254,7 +254,10 @@ begin
|
|||||||
if Assigned(Cel.Font) and (Cel.Font.Size > 0) then
|
if Assigned(Cel.Font) and (Cel.Font.Size > 0) then
|
||||||
FWorksheet.WriteFont(Y, X, Cel.Font.Name, Cel.Font.Size, sftofs(Cel.Font), Cel.Font.Color, fpNormal);
|
FWorksheet.WriteFont(Y, X, Cel.Font.Name, Cel.Font.Size, sftofs(Cel.Font), Cel.Font.Color, fpNormal);
|
||||||
|
|
||||||
FWorksheet.WriteHorAlignment(Y, X, ssAligns[Cel.Alignment]);
|
if Cel.Justify then
|
||||||
|
FWorksheet.WriteHorAlignment(Y, X, haJustified)
|
||||||
|
else
|
||||||
|
FWorksheet.WriteHorAlignment(Y, X, ssAligns[Cel.Alignment]);
|
||||||
|
|
||||||
scFrm:=[];
|
scFrm:=[];
|
||||||
if frbLeft in Cel.Frames then
|
if frbLeft in Cel.Frames then
|
||||||
|
@ -74,6 +74,7 @@ type
|
|||||||
FName:string;
|
FName:string;
|
||||||
FAngle:byte;
|
FAngle:byte;
|
||||||
FWordWrap: boolean;
|
FWordWrap: boolean;
|
||||||
|
FJustify: boolean;
|
||||||
|
|
||||||
FPicture: TPicture;
|
FPicture: TPicture;
|
||||||
|
|
||||||
@ -106,6 +107,7 @@ type
|
|||||||
property WordWrap:boolean read FWordWrap;
|
property WordWrap:boolean read FWordWrap;
|
||||||
property URLInfo: string read FURLInfo write FURLInfo;
|
property URLInfo: string read FURLInfo write FURLInfo;
|
||||||
property Picture: TPicture read FPicture;
|
property Picture: TPicture read FPicture;
|
||||||
|
property Justify: boolean read FJustify write FJustify;
|
||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -291,6 +293,7 @@ begin
|
|||||||
FAngle:=TfrMemoView(AObj).Angle;
|
FAngle:=TfrMemoView(AObj).Angle;
|
||||||
FLayout:=TfrMemoView(AObj).Layout;
|
FLayout:=TfrMemoView(AObj).Layout;
|
||||||
FWordWrap:=TfrMemoView(AObj).WordWrap;
|
FWordWrap:=TfrMemoView(AObj).WordWrap;
|
||||||
|
FJustify:=TfrMemoView(AObj).Justify;
|
||||||
//http://www.lazarus-ide.org/
|
//http://www.lazarus-ide.org/
|
||||||
S:=TfrMemoView(AObj).URLInfo;
|
S:=TfrMemoView(AObj).URLInfo;
|
||||||
if LazStartsText('HTTP://', S) or LazStartsText('HTTPS://', S) then
|
if LazStartsText('HTTP://', S) or LazStartsText('HTTPS://', S) then
|
||||||
@ -659,9 +662,12 @@ begin
|
|||||||
{ Result:=nil;
|
{ Result:=nil;
|
||||||
if (AObj is TfrMemoView) or ((AObj is TfrPictureView) and FExportImages) then
|
if (AObj is TfrMemoView) or ((AObj is TfrPictureView) and FExportImages) then
|
||||||
begin}
|
begin}
|
||||||
|
if AObj.Height > 0 then
|
||||||
|
begin
|
||||||
R:=FindRow(AObj.Y);
|
R:=FindRow(AObj.Y);
|
||||||
Result:=R.ExportObject(AObj);
|
Result:=R.ExportObject(AObj);
|
||||||
Result.Top:=R.Top;
|
Result.Top:=R.Top;
|
||||||
|
end;
|
||||||
// end
|
// end
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user