1 /*
2  * This file is part of EvinceD.
3  * EvinceD is based on GtkD.
4  *
5  * EvinceD is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU Lesser General Public License
7  * as published by the Free Software Foundation; either version 3
8  * of the License, or (at your option) any later version, with
9  * some exceptions, please read the COPYING file.
10  *
11  * EvinceD is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with EvinceD; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
19  */
20 
21 // generated automatically - do not change
22 // find conversion definition on APILookup.txt
23 
24 
25 module evince.view.c.types;
26 
27 public import cairo.c.types;
28 public import evince.document.c.types;
29 public import gdk.c.types;
30 public import gio.c.types;
31 public import glib.c.types;
32 public import gobject.c.types;
33 public import gtk.c.types;
34 
35 
36 public enum EvJobPageDataFlags
37 {
38 	NONE = 0,
39 	LINKS = 1,
40 	TEXT = 2,
41 	TEXT_MAPPING = 4,
42 	TEXT_LAYOUT = 8,
43 	TEXT_ATTRS = 16,
44 	TEXT_LOG_ATTRS = 32,
45 	IMAGES = 64,
46 	FORMS = 128,
47 	ANNOTS = 256,
48 	MEDIA = 512,
49 	ALL = 1023,
50 }
51 alias EvJobPageDataFlags JobPageDataFlags;
52 
53 public enum EvJobPriority
54 {
55 	PRIORITY_URGENT = 0,
56 	PRIORITY_HIGH = 1,
57 	PRIORITY_LOW = 2,
58 	PRIORITY_NONE = 3,
59 	N_PRIORITIES = 4,
60 }
61 alias EvJobPriority JobPriority;
62 
63 public enum EvJobRunMode
64 {
65 	THREAD = 0,
66 	MAIN_LOOP = 1,
67 }
68 alias EvJobRunMode JobRunMode;
69 
70 public enum EvJobThumbnailFormat
71 {
72 	PIXBUF = 0,
73 	SURFACE = 1,
74 }
75 alias EvJobThumbnailFormat JobThumbnailFormat;
76 
77 public enum EvPageLayout
78 {
79 	SINGLE = 0,
80 	DUAL = 1,
81 	AUTOMATIC = 2,
82 }
83 alias EvPageLayout PageLayout;
84 
85 public enum EvSizingMode
86 {
87 	/**
88 	 * Since: 3.8
89 	 */
90 	FIT_PAGE = 0,
91 	/**
92 	 * Same as %EV_SIZING_FIT_PAGE. Deprecated:
93 	 */
94 	BEST_FIT = 0,
95 	FIT_WIDTH = 1,
96 	FREE = 2,
97 	/**
98 	 * Since: 3.8
99 	 */
100 	AUTOMATIC = 3,
101 }
102 alias EvSizingMode SizingMode;
103 
104 struct EvDocumentModel;
105 
106 struct EvDocumentModelClass
107 {
108 	GObjectClass parentClass;
109 }
110 
111 struct EvJob
112 {
113 	GObject parent;
114 	EvDocument* document;
115 	EvJobRunMode runMode;
116 	import std.bitmanip: bitfields;
117 	mixin(bitfields!(
118 		uint, "cancelled", 1,
119 		uint, "finished", 1,
120 		uint, "failed", 1,
121 		uint, "", 29
122 	));
123 	GError* error;
124 	GCancellable* cancellable;
125 	uint idleFinishedId;
126 	uint idleCancelledId;
127 }
128 
129 struct EvJobAnnots
130 {
131 	EvJob parent;
132 	GList* annots;
133 }
134 
135 struct EvJobAnnotsClass
136 {
137 	EvJobClass parentClass;
138 }
139 
140 struct EvJobAttachments
141 {
142 	EvJob parent;
143 	GList* attachments;
144 }
145 
146 struct EvJobAttachmentsClass
147 {
148 	EvJobClass parentClass;
149 }
150 
151 struct EvJobClass
152 {
153 	GObjectClass parentClass;
154 	/** */
155 	extern(C) int function(EvJob* job) run;
156 	/** */
157 	extern(C) void function(EvJob* job) cancelled;
158 	/** */
159 	extern(C) void function(EvJob* job) finished;
160 }
161 
162 struct EvJobExport
163 {
164 	EvJob parent;
165 	int page;
166 	EvRenderContext* rc;
167 }
168 
169 struct EvJobExportClass
170 {
171 	EvJobClass parentClass;
172 }
173 
174 struct EvJobFind
175 {
176 	EvJob parent;
177 	int startPage;
178 	int currentPage;
179 	int nPages;
180 	GList** pages;
181 	char* text;
182 	bool caseSensitive;
183 	bool hasResults;
184 	EvFindOptions options;
185 }
186 
187 struct EvJobFindClass
188 {
189 	EvJobClass parentClass;
190 	/** */
191 	extern(C) void function(EvJobFind* job, int page) updated;
192 }
193 
194 struct EvJobFonts
195 {
196 	EvJob parent;
197 	bool scanCompleted;
198 }
199 
200 struct EvJobFontsClass
201 {
202 	EvJobClass parentClass;
203 	/** */
204 	extern(C) void function(EvJobFonts* job, double progress) updated;
205 }
206 
207 struct EvJobLayers
208 {
209 	EvJob parent;
210 	GtkTreeModel* model;
211 }
212 
213 struct EvJobLayersClass
214 {
215 	EvJobClass parentClass;
216 }
217 
218 struct EvJobLinks
219 {
220 	EvJob parent;
221 	GtkTreeModel* model;
222 }
223 
224 struct EvJobLinksClass
225 {
226 	EvJobClass parentClass;
227 }
228 
229 struct EvJobLoad
230 {
231 	EvJob parent;
232 	char* uri;
233 	char* password;
234 }
235 
236 struct EvJobLoadClass
237 {
238 	EvJobClass parentClass;
239 }
240 
241 struct EvJobLoadGFile
242 {
243 	EvJob parent;
244 	char* password;
245 	GFile* gfile;
246 	EvDocumentLoadFlags flags;
247 }
248 
249 struct EvJobLoadGFileClass
250 {
251 	EvJobClass parentClass;
252 }
253 
254 struct EvJobLoadStream
255 {
256 	EvJob parent;
257 	char* password;
258 	GInputStream* stream;
259 	EvDocumentLoadFlags flags;
260 }
261 
262 struct EvJobLoadStreamClass
263 {
264 	EvJobClass parentClass;
265 }
266 
267 struct EvJobPageData
268 {
269 	EvJob parent;
270 	int page;
271 	EvJobPageDataFlags flags;
272 	EvMappingList* linkMapping;
273 	EvMappingList* imageMapping;
274 	EvMappingList* formFieldMapping;
275 	EvMappingList* annotMapping;
276 	EvMappingList* mediaMapping;
277 	cairo_region_t* textMapping;
278 	char* text;
279 	EvRectangle* textLayout;
280 	uint textLayoutLength;
281 	PangoAttrList* textAttrs;
282 	PangoLogAttr* textLogAttrs;
283 	gulong textLogAttrsLength;
284 }
285 
286 struct EvJobPageDataClass
287 {
288 	EvJobClass parentClass;
289 }
290 
291 struct EvJobPrint
292 {
293 	EvJob parent;
294 	int page;
295 	cairo_t* cr;
296 }
297 
298 struct EvJobPrintClass
299 {
300 	EvJobClass parentClass;
301 }
302 
303 struct EvJobRender
304 {
305 	EvJob parent;
306 	int page;
307 	int rotation;
308 	double scale;
309 	bool pageReady;
310 	int targetWidth;
311 	int targetHeight;
312 	cairo_surface_t* surface;
313 	bool includeSelection;
314 	cairo_surface_t* selection;
315 	cairo_region_t* selectionRegion;
316 	EvRectangle selectionPoints;
317 	EvSelectionStyle selectionStyle;
318 	GdkColor base;
319 	GdkColor text;
320 }
321 
322 struct EvJobRenderClass
323 {
324 	EvJobClass parentClass;
325 }
326 
327 struct EvJobSave
328 {
329 	EvJob parent;
330 	char* uri;
331 	char* documentUri;
332 }
333 
334 struct EvJobSaveClass
335 {
336 	EvJobClass parentClass;
337 }
338 
339 struct EvJobThumbnail
340 {
341 	EvJob parent;
342 	int page;
343 	int rotation;
344 	double scale;
345 	int targetWidth;
346 	int targetHeight;
347 	GdkPixbuf* thumbnail;
348 	bool hasFrame;
349 	EvJobThumbnailFormat format;
350 	cairo_surface_t* thumbnailSurface;
351 }
352 
353 struct EvJobThumbnailClass
354 {
355 	EvJobClass parentClass;
356 }
357 
358 struct EvPrintOperation;
359 
360 struct EvPrintOperationClass;
361 
362 struct EvView;
363 
364 struct EvViewClass;
365 
366 struct EvViewPresentation;
367 
368 struct EvViewPresentationClass;
369 
370 /**
371  * StockIds
372  */
373 public enum StockID
374 {
375 	ANNOT_SQUIGGLY = "annotations-squiggly-symbolic",
376 	ANNOT_TEXT = "annotations-text-symbolic",
377 	ATTACHMENT = "mail-attachment",
378 	CLOSE = "close",
379 	FIND_UNSUPPORTED = "find-unsupported-symbolic",
380 	INVERTED_COLORS = "inverted",
381 	OUTLINE = "outline-symbolic",
382 	RESIZE_SE = "resize-se",
383 	RESIZE_SW = "resize-sw",
384 	ROTATE_LEFT = "object-rotate-left",
385 	ROTATE_RIGHT = "object-rotate-right",
386 	RUN_PRESENTATION = "x-office-presentation",
387 	SEND_TO = "document-send",
388 	VIEW_CONTINUOUS = "view-page-continuous",
389 	VIEW_DUAL = "view-page-facing",
390 	VIEW_SIDEBAR = "view-sidebar-symbolic",
391 	VISIBLE = "visible-symbolic",
392 	ZOOM = "zoom",
393 	ZOOM_PAGE = "zoom-fit-height",
394 	ZOOM_WIDTH = "zoom-fit-width",
395 }