types.h 1.67 KB
Newer Older
Moritz Lipp's avatar
Moritz Lipp committed
1
2
/* See LICENSE file for license and copyright information */

3
4
#ifndef LIBZATHURA_TYPES_H
#define LIBZATHURA_TYPES_H
Moritz Lipp's avatar
Moritz Lipp committed
5

Moritz Lipp's avatar
Moritz Lipp committed
6
7
8
9
#ifdef __cplusplus
extern "C" {
#endif

Moritz Lipp's avatar
Moritz Lipp committed
10
11
12
#include "list.h"
#include "node.h"

13
14
15
16
17
typedef struct zathura_point_s {
  float x;
  float y;
} zathura_point_t;

Moritz Lipp's avatar
Moritz Lipp committed
18
typedef struct zathura_rectangle_s {
19
20
  zathura_point_t p1;
  zathura_point_t p2;
Moritz Lipp's avatar
Moritz Lipp committed
21
22
} zathura_rectangle_t;

23
24
25
26
27
28
typedef struct zathura_quad_point_s {
  zathura_point_t p1;
  zathura_point_t p2;
  zathura_point_t p3;
  zathura_point_t p4;
} zathura_quad_point_t;
Moritz Lipp's avatar
Moritz Lipp committed
29

30
31
32
33
34
35
typedef enum zathura_search_flag_e {
  ZATHURA_SEARCH_DEFAULT           = 0,
  ZATHURA_SEARCH_CASE_SENSITIVE    = 1 << 0,
  ZATHURA_SEARCH_WHOLE_WORDS_ONLY = 1 << 1
} zathura_search_flag_t;

Moritz Lipp's avatar
Moritz Lipp committed
36
37
38
typedef struct zathura_path_s {
  zathura_list_t* points;
} zathura_path_t;
Moritz Lipp's avatar
Moritz Lipp committed
39

40
41
#include "action.h"

Moritz Lipp's avatar
Moritz Lipp committed
42
43
44
45
46
typedef struct zathura_link_mapping_s {
  zathura_rectangle_t position;
  zathura_action_t* action;
} zathura_link_mapping_t;

47
48
#include "form-fields.h"

Moritz Lipp's avatar
Moritz Lipp committed
49
50
typedef struct zathura_form_field_s zathura_form_field_t;

Moritz Lipp's avatar
Moritz Lipp committed
51
52
53
54
55
typedef struct zathura_form_field_mapping_s {
  zathura_rectangle_t position;
  zathura_form_field_t* form_field;
} zathura_form_field_mapping_t;

56
57
typedef void (*zathura_free_function_t)(void* data);

58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
typedef enum zathura_blend_mode_e {
  ZATHURA_BLEND_MODE_NORMAL,
  ZATHURA_BLEND_MODE_MULTIPLY,
  ZATHURA_BLEND_MODE_SCREEN,
  ZATHURA_BLEND_MODE_OVERLAY,
  ZATHURA_BLEND_MODE_DARKEN,
  ZATHURA_BLEND_MODE_LIGHTEN,
  ZATHURA_BLEND_MODE_COLOR_DODGE,
  ZATHURA_BLEND_MODE_COLOR_BURN,
  ZATHURA_BLEND_MODE_HARD_LIGHT,
  ZATHURA_BLEND_MODE_SOFT_LIGHT,
  ZATHURA_BLEND_MODE_DIFFERENCE,
  ZATHURA_BLEND_MODE_EXCLUSION
} zathura_blend_mode_t;

Moritz Lipp's avatar
Moritz Lipp committed
73
74
75
76
#ifdef __cplusplus
}
#endif

Moritz Lipp's avatar
Moritz Lipp committed
77
#endif /* TYPES_H */