Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(703)

Side by Side Diff: ppapi/c/dev/pp_print_settings_dev.h

Issue 10544085: Added PPB function to return default print settings (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 /* Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 * Use of this source code is governed by a BSD-style license that can be
3 * found in the LICENSE file.
4 */
5
6 /* From dev/pp_print_settings_dev.idl modified Fri Jun 8 15:56:05 2012. */
7
8 #ifndef PPAPI_C_DEV_PP_PRINT_SETTINGS_DEV_H_
9 #define PPAPI_C_DEV_PP_PRINT_SETTINGS_DEV_H_
10
11 #include "ppapi/c/pp_bool.h"
12 #include "ppapi/c/pp_macros.h"
13 #include "ppapi/c/pp_point.h"
14 #include "ppapi/c/pp_rect.h"
15 #include "ppapi/c/pp_size.h"
16 #include "ppapi/c/pp_stdint.h"
17
18 /**
19 * @file
20 * This file defines the struct for PrintSettings.
21 */
22
23
24 /**
25 * @addtogroup Enums
26 * @{
27 */
28 typedef enum {
29 PP_PRINTORIENTATION_NORMAL = 0,
30 PP_PRINTORIENTATION_ROTATED_90_CW = 1,
31 PP_PRINTORIENTATION_ROTATED_180 = 2,
32 PP_PRINTORIENTATION_ROTATED_90_CCW = 3
33 } PP_PrintOrientation_Dev;
34 PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_PrintOrientation_Dev, 4);
35
36 typedef enum {
37 PP_PRINTOUTPUTFORMAT_RASTER = 1u << 0,
38 PP_PRINTOUTPUTFORMAT_PDF = 1u << 1,
39 PP_PRINTOUTPUTFORMAT_POSTSCRIPT = 1u << 2,
40 PP_PRINTOUTPUTFORMAT_EMF = 1u << 3
41 } PP_PrintOutputFormat_Dev;
42 PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_PrintOutputFormat_Dev, 4);
43
44 typedef enum {
45 PP_PRINTSCALINGOPTION_NONE = 0,
46 PP_PRINTSCALINGOPTION_FIT_TO_PRINTABLE_AREA = 1,
47 PP_PRINTSCALINGOPTION_SOURCE_SIZE = 2
48 } PP_PrintScalingOption_Dev;
49 PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_PrintScalingOption_Dev, 4);
50 /**
51 * @}
52 */
53
54 /**
55 * @addtogroup Structs
56 * @{
57 */
58 struct PP_PrintSettings_Dev {
59 /** This is the size of the printable area in points (1/72 of an inch) */
60 struct PP_Rect printable_area;
61 struct PP_Rect content_area;
62 struct PP_Size paper_size;
63 int32_t dpi;
64 PP_PrintOrientation_Dev orientation;
65 PP_PrintScalingOption_Dev print_scaling_option;
66 PP_Bool grayscale;
67 /** Note that Chrome currently only supports PDF printing. */
68 PP_PrintOutputFormat_Dev format;
69 };
70 PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_PrintSettings_Dev, 60);
71 /**
72 * @}
73 */
74
75 #endif /* PPAPI_C_DEV_PP_PRINT_SETTINGS_DEV_H_ */
76
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698