GRASS GIS 8 Programmer's Manual  8.5.0dev(2024)-d6dec75dd4
htmldriver/driver.c
Go to the documentation of this file.
1 /****************************************************************************
2  *
3  * MODULE: HTMLMAP
4  * AUTHOR(S): Glynn Clements <glynn gclements.plus.com> (original
5  * contributor)
6  *
7  * PURPOSE: driver to allow HTML image maps
8  * COPYRIGHT: (C) 2007-2007 by the GRASS Development Team
9  *
10  * This program is free software under the GNU General Public
11  * License (>=v2). Read the file COPYING that comes with GRASS
12  * for details.
13  *
14  *****************************************************************************/
15 
16 #include <stdio.h>
17 #include "driver.h"
18 #include "htmlmap.h"
19 
20 const struct driver *HTML_Driver(void)
21 {
22  static struct driver drv;
23  static int initialized;
24 
25  if (initialized)
26  return &drv;
27 
28  drv.name = "html";
29  drv.Box = HTML_Box;
30  drv.Erase = NULL;
33  drv.Graph_get_file = NULL;
34  drv.Line_width = NULL;
35  drv.Set_window = NULL;
36  drv.Begin_raster = NULL;
37  drv.Raster = NULL;
38  drv.End_raster = NULL;
39  drv.Begin = HTML_Begin;
40  drv.Move = HTML_Move;
41  drv.Cont = HTML_Cont;
42  drv.Close = HTML_Close;
43  drv.Stroke = HTML_Stroke;
44  drv.Fill = HTML_Fill;
45  drv.Point = NULL;
46  drv.Color = NULL;
47  drv.Bitmap = NULL;
48  drv.Text = HTML_Text;
49  drv.Text_box = NULL;
50  drv.Set_font = NULL;
51  drv.Font_list = NULL;
52  drv.Font_info = NULL;
53 
54  initialized = 1;
55 
56  return &drv;
57 }
#define NULL
Definition: ccmath.h:32
void HTML_Graph_close(void)
Definition: graph_clse.c:28
void HTML_Box(double x1, double y1, double x2, double y2)
Definition: htmldriver/box.c:3
void HTML_Close(void)
void HTML_Begin(void)
void HTML_Stroke(void)
void HTML_Move(double x, double y)
void HTML_Cont(double x, double y)
void HTML_Fill(void)
const struct driver * HTML_Driver(void)
int HTML_Graph_set(void)
void HTML_Text(const char *)
Definition: driver.h:21
void(* Graph_close)(void)
Definition: driver.h:27
void(* Line_width)(double)
Definition: driver.h:29
void(* Font_info)(char ***, int *)
Definition: driver.h:49
void(* Text_box)(const char *, double *, double *, double *, double *)
Definition: driver.h:46
void(* Point)(double, double)
Definition: driver.h:41
void(* Fill)(void)
Definition: driver.h:40
void(* Erase)(void)
Definition: driver.h:25
int(* Raster)(int, int, const unsigned char *, const unsigned char *, const unsigned char *, const unsigned char *)
Definition: driver.h:32
void(* Stroke)(void)
Definition: driver.h:39
void(* Begin)(void)
Definition: driver.h:35
void(* Font_list)(char ***, int *)
Definition: driver.h:48
void(* End_raster)(void)
Definition: driver.h:34
const char *(* Graph_get_file)(void)
Definition: driver.h:28
void(* Box)(double, double, double, double)
Definition: driver.h:24
void(* Move)(double, double)
Definition: driver.h:36
void(* Begin_raster)(int, int[2][2], double[2][2])
Definition: driver.h:31
char * name
Definition: driver.h:22
void(* Close)(void)
Definition: driver.h:38
void(* Set_window)(double, double, double, double)
Definition: driver.h:30
int(* Graph_set)(void)
Definition: driver.h:26
void(* Set_font)(const char *)
Definition: driver.h:47
void(* Text)(const char *)
Definition: driver.h:45
void(* Cont)(double, double)
Definition: driver.h:37
void(* Color)(int, int, int)
Definition: driver.h:43
void(* Bitmap)(int, int, int, const unsigned char *)
Definition: driver.h:44