commit 212685a1d3eb78d3d2dc6b3d67371b5e981d1bdc
Author: oconrad <olaf.conrad@uni-hamburg.de>
Date:   Mon Aug 22 12:03:52 2022 +0200

    docs_pdf, libHaru: fixes typo related changes in current libharu interface, relates to bug reported with "[saga-gis:bugs] #296 8.3.1 fails to compile in arch linux with doc_pdf.cpp.o"

diff --git a/saga-gis/src/tools/docs/docs_pdf/MLB_Interface.cpp b/saga-gis/src/tools/docs/docs_pdf/MLB_Interface.cpp
index 119dc7e18..352964029 100644
--- a/saga-gis/src/tools/docs/docs_pdf/MLB_Interface.cpp
+++ b/saga-gis/src/tools/docs/docs_pdf/MLB_Interface.cpp
@@ -1,6 +1,3 @@
-/**********************************************************
- * Version $Id: TLB_Interface.cpp 1921 2014-01-09 10:24:11Z oconrad $
- *********************************************************/
 
 ///////////////////////////////////////////////////////////
 //                                                       //
@@ -49,16 +46,9 @@
 ///////////////////////////////////////////////////////////
 
 //---------------------------------------------------------
+#include <saga_api/saga_api.h>
 
-
-///////////////////////////////////////////////////////////
-//														 //
-//           The Tool Link Library Interface             //
-//														 //
-///////////////////////////////////////////////////////////
-
-//---------------------------------------------------------
-#include "MLB_Interface.h"
+#include <hpdf_version.h>
 
 
 //---------------------------------------------------------
@@ -66,23 +56,25 @@ CSG_String Get_Info(int i)
 {
 	switch( i )
 	{
-	case TLB_INFO_Name:	default:
+	case TLB_INFO_Name: default:
 		return( _TL("PDF") );
 
 	case TLB_INFO_Category:
 		return( _TL("Reports") );
 
 	case TLB_INFO_Author:
-		return( SG_T("SAGA User Group (c) 2010") );
+		return( "SAGA User Group (c) 2010" );
 
 	case TLB_INFO_Description:
 		return( _TW(
-			"Reports in Portable Document Format (PDF). PDF export is based on "
-			"<a target=\"_blank\" href=\"libharu.org\">libharu</a>."
-		));
+			"Create reports in the Portable Document Format (PDF). "
+			"The export tools are using the free open source library "
+			"<a target=\"_blank\" href=\"libharu.org\">libHaru</a> "
+			"version ") + CSG_String(HPDF_VERSION_TEXT)
+		);
 
 	case TLB_INFO_Version:
-		return( SG_T("1.0") );
+		return( "1.0" );
 
 	case TLB_INFO_Menu_Path:
 		return( _TL("File|Reports") );
@@ -101,9 +93,12 @@ CSG_Tool *		Create_Tool(int i)
 {
 	switch( i )
 	{
-	case  0:	return( new CShapes_Report );
-	case  1:	return( new CShapes_Summary );
-	case  2:	return( new CProfile_Cross_Sections );
+	case  0: return( new CShapes_Report );
+	case  1: return( new CShapes_Summary );
+	case  2: return( new CProfile_Cross_Sections );
+
+	case  3: return( NULL );
+	default: return( TLB_INTERFACE_SKIP_TOOL );
 	}
 
 	return( NULL );
diff --git a/saga-gis/src/tools/docs/docs_pdf/Profile_Cross_Sections.h b/saga-gis/src/tools/docs/docs_pdf/Profile_Cross_Sections.h
index 15f812679..a9e25882c 100644
--- a/saga-gis/src/tools/docs/docs_pdf/Profile_Cross_Sections.h
+++ b/saga-gis/src/tools/docs/docs_pdf/Profile_Cross_Sections.h
@@ -1,6 +1,3 @@
-/**********************************************************
- * Version $Id: Profile_Cross_Sections.h 911 2011-02-14 16:38:15Z reklov_w $
- *********************************************************/
 /*******************************************************************************
     CrossSections.h
     Copyright (C) Victor Olaya
diff --git a/saga-gis/src/tools/docs/docs_pdf/Shapes_Report.h b/saga-gis/src/tools/docs/docs_pdf/Shapes_Report.h
index fa349574d..2bab96d85 100644
--- a/saga-gis/src/tools/docs/docs_pdf/Shapes_Report.h
+++ b/saga-gis/src/tools/docs/docs_pdf/Shapes_Report.h
@@ -1,6 +1,3 @@
-/**********************************************************
- * Version $Id: Shapes_Report.h 1922 2014-01-09 10:28:46Z oconrad $
- *********************************************************/
 
 ///////////////////////////////////////////////////////////
 //                                                       //
@@ -51,6 +48,8 @@
 ///////////////////////////////////////////////////////////
 
 //---------------------------------------------------------
+#ifndef HEADER_INCLUDED__Shapes_Report_H
+#define HEADER_INCLUDED__Shapes_Report_H
 
 
 ///////////////////////////////////////////////////////////
@@ -60,11 +59,7 @@
 ///////////////////////////////////////////////////////////
 
 //---------------------------------------------------------
-#ifndef HEADER_INCLUDED__Shapes_Report_H
-#define HEADER_INCLUDED__Shapes_Report_H
-
-//---------------------------------------------------------
-#include "MLB_Interface.h"
+#include <saga_api/saga_api.h>
 
 
 ///////////////////////////////////////////////////////////
@@ -94,7 +89,7 @@ private:
 
 	CSG_Rect				m_rTitle, m_rShape, m_rTable;
 
-	CSG_Shapes					*m_pShapes;
+	CSG_Shapes				*m_pShapes;
 
 	class CSG_Doc_PDF		*m_pPDF;
 
diff --git a/saga-gis/src/tools/docs/docs_pdf/Shapes_Summary.h b/saga-gis/src/tools/docs/docs_pdf/Shapes_Summary.h
index f87441aeb..97610cbd3 100644
--- a/saga-gis/src/tools/docs/docs_pdf/Shapes_Summary.h
+++ b/saga-gis/src/tools/docs/docs_pdf/Shapes_Summary.h
@@ -1,6 +1,3 @@
-/**********************************************************
- * Version $Id: Shapes_Summary.h 911 2011-02-14 16:38:15Z reklov_w $
- *********************************************************/
 /*******************************************************************************
     Summarize.h
     Copyright (C) Victor Olaya
@@ -89,6 +86,7 @@ private:
 
 };
 
+
 ///////////////////////////////////////////////////////////
 //														 //
 //														 //
diff --git a/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp b/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp
index f08f17bca..e5c5d538e 100644
--- a/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp
+++ b/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp
@@ -1,6 +1,3 @@
-/**********************************************************
- * Version $Id: doc_pdf.cpp 1921 2014-01-09 10:24:11Z oconrad $
- *********************************************************/
 
 ///////////////////////////////////////////////////////////
 //                                                       //
@@ -53,15 +50,6 @@
 //                                                       //
 ///////////////////////////////////////////////////////////
 
-//---------------------------------------------------------
-
-
-///////////////////////////////////////////////////////////
-//														 //
-//														 //
-//														 //
-///////////////////////////////////////////////////////////
-
 //---------------------------------------------------------
 #ifndef _SAGA_DONOTUSE_HARU
 
@@ -101,6 +89,11 @@
 #define PDF_GET_G(c)			(float)(SG_GET_G(c) / 255.0)
 #define PDF_GET_B(c)			(float)(SG_GET_B(c) / 255.0)
 
+//---------------------------------------------------------
+// libHaru version compatibility (fixed typos in hpdf_types.h)!
+#define HPDF_PROJECTING_SQUARE_END HPDF_PROJECTING_SCUARE_END // SCUARE -> SQUARE
+#define HPDF_BYTE_TYPE_TRAIL       HPDF_BYTE_TYPE_TRIAL       // TRIAL  -> TRAIL
+
 
 ///////////////////////////////////////////////////////////
 //														 //
diff --git a/saga-gis/src/tools/docs/docs_pdf/doc_pdf.h b/saga-gis/src/tools/docs/docs_pdf/doc_pdf.h
index 57d6a79ae..b4d4c04ed 100644
--- a/saga-gis/src/tools/docs/docs_pdf/doc_pdf.h
+++ b/saga-gis/src/tools/docs/docs_pdf/doc_pdf.h
@@ -1,6 +1,3 @@
-/**********************************************************
- * Version $Id: doc_pdf.h 1921 2014-01-09 10:24:11Z oconrad $
- *********************************************************/
 
 ///////////////////////////////////////////////////////////
 //                                                       //
@@ -53,15 +50,6 @@
 //                                                       //
 ///////////////////////////////////////////////////////////
 
-//---------------------------------------------------------
-
-
-///////////////////////////////////////////////////////////
-//														 //
-//														 //
-//														 //
-///////////////////////////////////////////////////////////
-
 //---------------------------------------------------------
 #ifndef HEADER_INCLUDED__doc_pdf_H
 #define HEADER_INCLUDED__doc_pdf_H
@@ -74,7 +62,7 @@
 ///////////////////////////////////////////////////////////
 
 //---------------------------------------------------------
-#include "MLB_Interface.h"
+#include <saga_api/saga_api.h>
 
 
 ///////////////////////////////////////////////////////////
@@ -178,7 +166,7 @@ TSG_PDF_Title_Level;
 ///////////////////////////////////////////////////////////
 
 //---------------------------------------------------------
-class docs_pdf_EXPORT CSG_Doc_PDF
+class CSG_Doc_PDF
 {
 public:
 	CSG_Doc_PDF(void);
commit c1decfde9c9dcaec7304642552ec1494dfec66d2
Author: oconrad <olaf.conrad@uni-hamburg.de>
Date:   Mon Aug 22 12:14:33 2022 +0200

    docs_pdf, libHaru: fixes typo related changes in current libharu interface, relates to bug reported with "[saga-gis:bugs] #296 8.3.1 fails to compile in arch linux with doc_pdf.cpp.o"

diff --git a/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp b/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp
index e5c5d538e..ff8ff955f 100644
--- a/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp
+++ b/saga-gis/src/tools/docs/docs_pdf/doc_pdf.cpp
@@ -91,8 +91,10 @@
 
 //---------------------------------------------------------
 // libHaru version compatibility (fixed typos in hpdf_types.h)!
+#if HPDF_MAJOR_VERSION == 2 && HPDF_MINOR_VERSION < 4
 #define HPDF_PROJECTING_SQUARE_END HPDF_PROJECTING_SCUARE_END // SCUARE -> SQUARE
 #define HPDF_BYTE_TYPE_TRAIL       HPDF_BYTE_TYPE_TRIAL       // TRIAL  -> TRAIL
+#endif
 
 
 ///////////////////////////////////////////////////////////
@@ -699,7 +701,7 @@ bool CSG_Doc_PDF::_Set_Style_FillStroke(int Style, int Fill_Color, int Line_Colo
 			}
 			else if( Style & PDF_STYLE_LINE_END_SQUARE )
 			{
-				HPDF_Page_SetLineCap(m_pPage, HPDF_PROJECTING_SCUARE_END);
+				HPDF_Page_SetLineCap(m_pPage, HPDF_PROJECTING_SQUARE_END);
 			}
 			else // if( Style & PDF_STYLE_LINE_END_BUTT )
 			{
