Browse Source

fcl-report: Fix AV for rendering TFPReportGroupHeaderBand and use LiberationSans font as default for Windows

git-svn-id: trunk@38631 -
maciej-izak 7 years ago
parent
commit
c392e3804e
1 changed files with 4 additions and 1 deletions
  1. 4 1
      packages/fcl-report/src/fpreport.pp

+ 4 - 1
packages/fcl-report/src/fpreport.pp

@@ -2238,7 +2238,7 @@ Function ReportExportManager : TFPReportExportManager;
 { this should probably be more configurable or flexible per platform }
 
 Const
-{$IFDEF UNIX}
+{$IF Defined(UNIX) or Defined(WINDOWS)}
   cDefaultFont = 'LiberationSans';
 {$ELSE}
   cDefaultFont = 'Helvetica';
@@ -11613,6 +11613,9 @@ begin
   //  write(': ',TFPReportCustomGroupFooterBand(aBand).GroupHeader.GroupCondition);
   //writeln(': Space = ', FormatFloat('#,##0.0', FSpaceLeft));
   Result := False;
+  if not Assigned(aBand) then
+    Exit;
+
   lHandledBands := TBandList.Create;
   try
     lBand := aBand;