annotate src/web.hh @ 982:d04d960da3f4

remove bg_color dillorc option To set a custom background color add a line like: body {background-color: white} to your ~/.dillo/style.css file. This also works for plain text display and image viewing.
author Johannes Hofmann <Johannes.Hofmann@gmx.de>
date Fri, 06 Mar 2009 10:09:38 +0100
parents 6ee11bf9e3ea
children 2650456b8199
rev   line source
0
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
1 #ifndef __WEB_H__
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
2 #define __WEB_H__
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
3
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
4 #include <stdio.h> /* for FILE */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
5 #include "bw.h" /* for BrowserWindow */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
6 #include "cache.h" /* for CA_Callback_t */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
7 #include "image.hh" /* for DilloImage */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
8
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
9 #ifdef __cplusplus
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
10 extern "C" {
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
11 #endif /* __cplusplus */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
12
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
13 /*
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
14 * Flag defines
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
15 */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
16 #define WEB_RootUrl 1
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
17 #define WEB_Image 2
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
18 #define WEB_Download 4 /* Half implemented... */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
19
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
20
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
21 typedef struct _DilloWeb DilloWeb;
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
22
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
23 struct _DilloWeb {
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
24 DilloUrl *url; /* Requested URL */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
25 BrowserWindow *bw; /* The requesting browser window [reference] */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
26 int flags; /* Additional info */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
27
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
28 DilloImage *Image; /* For image urls [reference] */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
29
982
d04d960da3f4 remove bg_color dillorc option
Johannes Hofmann <Johannes.Hofmann@gmx.de>
parents: 0
diff changeset
30 int32_t bgColor; /* for image backgrounds */
0
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
31 char *filename; /* Variables for Local saving */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
32 FILE *stream;
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
33 int SavedBytes;
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
34 };
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
35
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
36 void a_Web_init(void);
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
37 DilloWeb* a_Web_new (const DilloUrl* url);
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
38 int a_Web_valid(DilloWeb *web);
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
39 void a_Web_free (DilloWeb*);
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
40 int a_Web_dispatch_by_type (const char *Type, DilloWeb *web,
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
41 CA_Callback_t *Call, void **Data);
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
42
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
43 #ifdef __cplusplus
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
44 }
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
45 #endif /* __cplusplus */
6ee11bf9e3ea Initial revision
jcid
parents:
diff changeset
46 #endif /* __WEB_H__ */