Commit f837a50ec3a4f240d73f018f237f9f58631e2ba5

Werner Lemberg 2017-01-09T10:49:03

[pcf] Introduce a driver structure. To be filled later on with something useful. * src/pcf/pcf.h (PCF_Driver): New structure. * src/pcf/pcfdrivr.c (pcf_driver_init, pcf_driver_done): New dummy functions. (pcf_driver_class): Updated.

diff --git a/ChangeLog b/ChangeLog
index d9811d9..276b49d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2017-01-09  Werner Lemberg  <wl@gnu.org>
+
+	[pcf] Introduce a driver structure.
+
+	To be filled later on with something useful.
+
+	* src/pcf/pcf.h (PCF_Driver): New structure.
+
+	* src/pcf/pcfdrivr.c (pcf_driver_init, pcf_driver_done): New dummy
+	functions.
+	(pcf_driver_class): Updated.
+
 2017-01-08  Werner Lemberg  <wl@gnu.org>
 
 	[truetype] Again some GX code shuffling.
diff --git a/src/pcf/pcf.h b/src/pcf/pcf.h
index c726e5e..830cabe 100644
--- a/src/pcf/pcf.h
+++ b/src/pcf/pcf.h
@@ -163,6 +163,13 @@ FT_BEGIN_HEADER
   } PCF_FaceRec, *PCF_Face;
 
 
+  typedef struct  PCF_DriverRec_
+  {
+    FT_DriverRec  root;
+
+  } PCF_DriverRec, *PCF_Driver;
+
+
   /* macros for pcf font format */
 
 #define LSBFirst  0
diff --git a/src/pcf/pcfdrivr.c b/src/pcf/pcfdrivr.c
index 10d5c20..8f4a90d 100644
--- a/src/pcf/pcfdrivr.c
+++ b/src/pcf/pcfdrivr.c
@@ -691,22 +691,38 @@ THE SOFTWARE.
   }
 
 
+  FT_CALLBACK_DEF( FT_Error )
+  pcf_driver_init( FT_Module  module )      /* PCF_Driver */
+  {
+    FT_UNUSED( module );
+
+    return FT_Err_Ok;
+  }
+
+
+  FT_CALLBACK_DEF( void )
+  pcf_driver_done( FT_Module  module )      /* PCF_Driver */
+  {
+    FT_UNUSED( module );
+  }
+
+
   FT_CALLBACK_TABLE_DEF
   const FT_Driver_ClassRec  pcf_driver_class =
   {
     {
       FT_MODULE_FONT_DRIVER        |
       FT_MODULE_DRIVER_NO_OUTLINES,
-      sizeof ( FT_DriverRec ),
 
+      sizeof ( PCF_DriverRec ),
       "pcf",
       0x10000L,
       0x20000L,
 
-      NULL,    /* module-specific interface */
+      NULL,   /* module-specific interface */
 
-      NULL,                     /* FT_Module_Constructor  module_init   */
-      NULL,                     /* FT_Module_Destructor   module_done   */
+      pcf_driver_init,          /* FT_Module_Constructor  module_init   */
+      pcf_driver_done,          /* FT_Module_Destructor   module_done   */
       pcf_driver_requester      /* FT_Module_Requester    get_interface */
     },