poppler 3.1.8-x86-mingw32 → 3.1.9-x86-mingw32

Sign up to get free protection for your applications and to get access to all the features.
Files changed (108) hide show
  1. checksums.yaml +4 -4
  2. data/dependency-check/Rakefile +44 -0
  3. data/lib/poppler.rb +21 -107
  4. data/lib/poppler/annot-callout-line.rb +57 -0
  5. data/lib/poppler/cairo.rb +23 -0
  6. data/lib/poppler/color.rb +36 -0
  7. data/lib/poppler/deprecated.rb +67 -0
  8. data/lib/poppler/document.rb +108 -0
  9. data/lib/poppler/image-mapping.rb +25 -0
  10. data/lib/poppler/index-iter.rb +30 -0
  11. data/lib/poppler/loader.rb +139 -0
  12. data/lib/poppler/page.rb +61 -0
  13. data/lib/poppler/rectangle.rb +40 -0
  14. data/lib/poppler/version.rb +35 -0
  15. data/sample/number-pdf.rb +21 -2
  16. data/sample/pdf2.rb +0 -4
  17. data/sample/pdf2svg.rb +1 -1
  18. data/sample/pdf2text.rb +1 -1
  19. data/sample/pdfcrop.rb +1 -1
  20. data/sample/pdfdiv.rb +1 -1
  21. data/test/fixtures/image.odt +0 -0
  22. data/test/fixtures/image.pdf +0 -0
  23. data/test/fixtures/multiple-pages.odt +0 -0
  24. data/test/fixtures/multiple-pages.pdf +0 -0
  25. data/test/fixtures/text-field.odt +0 -0
  26. data/test/fixtures/text-field.pdf +0 -0
  27. data/test/poppler-test-utils.rb +24 -16
  28. data/test/run-test.rb +26 -4
  29. data/test/test-annotation.rb +76 -0
  30. data/test/{test_color.rb → test-color.rb} +0 -3
  31. data/test/test-constants.rb +16 -0
  32. data/test/{test_document.rb → test-document.rb} +26 -10
  33. data/test/test-page.rb +101 -0
  34. data/vendor/local/bin/cjpeg.exe +0 -0
  35. data/vendor/local/bin/djpeg.exe +0 -0
  36. data/vendor/local/bin/jpegtran.exe +0 -0
  37. data/vendor/local/bin/libjpeg-9.dll +0 -0
  38. data/vendor/local/bin/libopenjp2.dll +0 -0
  39. data/vendor/local/bin/libpoppler-59.dll +0 -0
  40. data/vendor/local/bin/libpoppler-cpp-0.dll +0 -0
  41. data/vendor/local/bin/libpoppler-glib-8.dll +0 -0
  42. data/vendor/local/bin/libsqlite3-0.dll +0 -0
  43. data/vendor/local/bin/opj_compress.exe +0 -0
  44. data/vendor/local/bin/opj_decompress.exe +0 -0
  45. data/vendor/local/bin/opj_dump.exe +0 -0
  46. data/vendor/local/bin/pdfdetach.exe +0 -0
  47. data/vendor/local/bin/pdffonts.exe +0 -0
  48. data/vendor/local/bin/pdfimages.exe +0 -0
  49. data/vendor/local/bin/pdfinfo.exe +0 -0
  50. data/vendor/local/bin/pdfseparate.exe +0 -0
  51. data/vendor/local/bin/pdftocairo.exe +0 -0
  52. data/vendor/local/bin/pdftohtml.exe +0 -0
  53. data/vendor/local/bin/pdftoppm.exe +0 -0
  54. data/vendor/local/bin/pdftops.exe +0 -0
  55. data/vendor/local/bin/pdftotext.exe +0 -0
  56. data/vendor/local/bin/pdfunite.exe +0 -0
  57. data/vendor/local/bin/rdjpgcom.exe +0 -0
  58. data/vendor/local/bin/sqlite3.exe +0 -0
  59. data/vendor/local/bin/wrjpgcom.exe +0 -0
  60. data/vendor/local/lib/libjpeg.dll.a +0 -0
  61. data/vendor/local/lib/libopenjp2.dll.a +0 -0
  62. data/vendor/local/lib/libpoppler-cpp.dll.a +0 -0
  63. data/vendor/local/lib/libpoppler-glib.a +0 -0
  64. data/vendor/local/lib/libpoppler-glib.dll.a +0 -0
  65. data/vendor/local/lib/libpoppler.a +0 -0
  66. data/vendor/local/lib/libpoppler.dll.a +0 -0
  67. data/vendor/local/lib/libsqlite3.dll.a +0 -0
  68. metadata +26 -46
  69. data/README +0 -35
  70. data/ext/poppler/depend +0 -6
  71. data/ext/poppler/extconf.rb +0 -73
  72. data/ext/poppler/poppler.def +0 -2
  73. data/ext/poppler/rbpoppler-action.c +0 -402
  74. data/ext/poppler/rbpoppler-annotation-callout-line.c +0 -127
  75. data/ext/poppler/rbpoppler-annotation-free-text.c +0 -46
  76. data/ext/poppler/rbpoppler-annotation-mapping.c +0 -72
  77. data/ext/poppler/rbpoppler-annotation-markup.c +0 -98
  78. data/ext/poppler/rbpoppler-annotation-text.c +0 -53
  79. data/ext/poppler/rbpoppler-annotation.c +0 -74
  80. data/ext/poppler/rbpoppler-attachment.c +0 -124
  81. data/ext/poppler/rbpoppler-button-field.c +0 -56
  82. data/ext/poppler/rbpoppler-choice-field.c +0 -131
  83. data/ext/poppler/rbpoppler-color.c +0 -107
  84. data/ext/poppler/rbpoppler-document.c +0 -224
  85. data/ext/poppler/rbpoppler-font-info.c +0 -59
  86. data/ext/poppler/rbpoppler-fonts-iter.c +0 -127
  87. data/ext/poppler/rbpoppler-form-field-mapping.c +0 -44
  88. data/ext/poppler/rbpoppler-form-field.c +0 -98
  89. data/ext/poppler/rbpoppler-image-mapping.c +0 -48
  90. data/ext/poppler/rbpoppler-index-iter.c +0 -130
  91. data/ext/poppler/rbpoppler-link-mapping.c +0 -47
  92. data/ext/poppler/rbpoppler-page-transition.c +0 -59
  93. data/ext/poppler/rbpoppler-page.c +0 -322
  94. data/ext/poppler/rbpoppler-private.h +0 -77
  95. data/ext/poppler/rbpoppler-ps-file.c +0 -66
  96. data/ext/poppler/rbpoppler-rectangle.c +0 -92
  97. data/ext/poppler/rbpoppler-text-field.c +0 -91
  98. data/ext/poppler/rbpoppler.c +0 -110
  99. data/ext/poppler/rbpoppler.h +0 -61
  100. data/ext/poppler/rbpopplerconversions.h +0 -105
  101. data/extconf.rb +0 -49
  102. data/lib/2.2/poppler.so +0 -0
  103. data/lib/2.3/poppler.so +0 -0
  104. data/lib/2.4/poppler.so +0 -0
  105. data/test/fixtures/image.png +0 -0
  106. data/test/test_annotation.rb +0 -86
  107. data/test/test_constants.rb +0 -30
  108. data/test/test_page.rb +0 -51
@@ -1,127 +0,0 @@
1
- /* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
2
- /*
3
- * Copyright (C) 2008-2013 Ruby-GNOME2 Project Team
4
- *
5
- * This library is free software; you can redistribute it and/or
6
- * modify it under the terms of the GNU Lesser General Public
7
- * License as published by the Free Software Foundation; either
8
- * version 2.1 of the License, or (at your option) any later version.
9
- *
10
- * This library is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Lesser General Public
16
- * License along with this library; if not, write to the Free Software
17
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
18
- * MA 02110-1301 USA
19
- */
20
-
21
- #include "rbpoppler-private.h"
22
-
23
- #define RG_TARGET_NAMESPACE cAnnotation
24
-
25
- static VALUE
26
- rg_initialize(VALUE self, VALUE multiline, VALUE x1, VALUE y1,
27
- VALUE x2, VALUE y2, VALUE x3, VALUE y3)
28
- {
29
- PopplerAnnotCalloutLine *line;
30
-
31
- line = poppler_annot_callout_line_new();
32
- line->multiline = RVAL2CBOOL(multiline);
33
- line->x1 = NUM2DBL(x1);
34
- line->y1 = NUM2DBL(y1);
35
- line->x2 = NUM2DBL(x2);
36
- line->y2 = NUM2DBL(y2);
37
- line->x3 = NUM2DBL(x3);
38
- line->y3 = NUM2DBL(y3);
39
-
40
- G_INITIALIZE(self, line);
41
- return Qnil;
42
- }
43
-
44
- DEF_ACCESSOR(annot_callout_line, multiline, RVAL2POPPLERANNOTCALLOUTLINE, CBOOL2RVAL, RVAL2CBOOL)
45
- DEF_ACCESSOR(annot_callout_line, x1, RVAL2POPPLERANNOTCALLOUTLINE, rb_float_new, NUM2DBL)
46
- DEF_ACCESSOR(annot_callout_line, y1, RVAL2POPPLERANNOTCALLOUTLINE, rb_float_new, NUM2DBL)
47
- DEF_ACCESSOR(annot_callout_line, x2, RVAL2POPPLERANNOTCALLOUTLINE, rb_float_new, NUM2DBL)
48
- DEF_ACCESSOR(annot_callout_line, y2, RVAL2POPPLERANNOTCALLOUTLINE, rb_float_new, NUM2DBL)
49
- DEF_ACCESSOR(annot_callout_line, x3, RVAL2POPPLERANNOTCALLOUTLINE, rb_float_new, NUM2DBL)
50
- DEF_ACCESSOR(annot_callout_line, y3, RVAL2POPPLERANNOTCALLOUTLINE, rb_float_new, NUM2DBL)
51
-
52
- static VALUE
53
- rg_to_a(VALUE self)
54
- {
55
- PopplerAnnotCalloutLine *line;
56
-
57
- line = RVAL2POPPLERANNOTCALLOUTLINE(self);
58
- return rb_ary_new3(7,
59
- CBOOL2RVAL(line->multiline),
60
- rb_float_new(line->x1),
61
- rb_float_new(line->y1),
62
- rb_float_new(line->x2),
63
- rb_float_new(line->y2),
64
- rb_float_new(line->x3),
65
- rb_float_new(line->y3));
66
- }
67
-
68
- static VALUE
69
- rg_inspect(VALUE self)
70
- {
71
- VALUE inspected;
72
- gchar *info;
73
- PopplerAnnotCalloutLine *line;
74
-
75
- line = RVAL2POPPLERANNOTCALLOUTLINE(self);
76
- inspected = rb_call_super(0, NULL);
77
- rb_str_resize(inspected, RSTRING_LEN(inspected) - 1);
78
- info = g_strdup_printf(": [%s, %g, %g, %g, %g, %g, %g]>",
79
- line->multiline ? "true" : "false",
80
- line->x1, line->y1,
81
- line->x2, line->y2,
82
- line->x3, line->y3);
83
- rb_str_cat2(inspected, info);
84
- g_free(info);
85
- return inspected;
86
- }
87
-
88
- void
89
- Init_poppler_annotation_callout_line(VALUE mPoppler)
90
- {
91
- VALUE RG_TARGET_NAMESPACE = G_DEF_CLASS(POPPLER_TYPE_ANNOT_CALLOUT_LINE,
92
- "AnnotationCalloutLine", mPoppler);
93
-
94
- RG_DEF_METHOD(initialize, 7);
95
-
96
- rbg_define_method(RG_TARGET_NAMESPACE, "multiline?",
97
- annot_callout_line_get_multiline, 0);
98
- rbg_define_method(RG_TARGET_NAMESPACE, "set_multiline",
99
- annot_callout_line_set_multiline, 1);
100
- rbg_define_method(RG_TARGET_NAMESPACE, "x1",
101
- annot_callout_line_get_x1, 0);
102
- rbg_define_method(RG_TARGET_NAMESPACE, "set_x1",
103
- annot_callout_line_set_x1, 1);
104
- rbg_define_method(RG_TARGET_NAMESPACE, "y1",
105
- annot_callout_line_get_y1, 0);
106
- rbg_define_method(RG_TARGET_NAMESPACE, "set_y1",
107
- annot_callout_line_set_y1, 1);
108
- rbg_define_method(RG_TARGET_NAMESPACE, "x2",
109
- annot_callout_line_get_x2, 0);
110
- rbg_define_method(RG_TARGET_NAMESPACE, "set_x2",
111
- annot_callout_line_set_x2, 2);
112
- rbg_define_method(RG_TARGET_NAMESPACE, "y2",
113
- annot_callout_line_get_y2, 0);
114
- rbg_define_method(RG_TARGET_NAMESPACE, "set_y2",
115
- annot_callout_line_set_y2, 2);
116
- rbg_define_method(RG_TARGET_NAMESPACE, "x3",
117
- annot_callout_line_get_x3, 0);
118
- rbg_define_method(RG_TARGET_NAMESPACE, "set_x3",
119
- annot_callout_line_set_x3, 3);
120
- rbg_define_method(RG_TARGET_NAMESPACE, "y3",
121
- annot_callout_line_get_y3, 0);
122
- rbg_define_method(RG_TARGET_NAMESPACE, "set_y3",
123
- annot_callout_line_set_y3, 3);
124
-
125
- RG_DEF_METHOD(to_a, 0);
126
- RG_DEF_METHOD(inspect, 0);
127
- }
@@ -1,46 +0,0 @@
1
- /* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
2
- /*
3
- * Copyright (C) 2008-2013 Ruby-GNOME2 Project Team
4
- *
5
- * This library is free software; you can redistribute it and/or
6
- * modify it under the terms of the GNU Lesser General Public
7
- * License as published by the Free Software Foundation; either
8
- * version 2.1 of the License, or (at your option) any later version.
9
- *
10
- * This library is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Lesser General Public
16
- * License along with this library; if not, write to the Free Software
17
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
18
- * MA 02110-1301 USA
19
- */
20
-
21
- #include "rbpoppler-private.h"
22
-
23
- #define RG_TARGET_NAMESPACE cAnnotationFreeText
24
- #define SELF(self) (RVAL2POPPLERANNOTFREETEXT(self))
25
-
26
- static VALUE
27
- rg_quadding(VALUE self)
28
- {
29
- return POPPLERANNOTFREETEXTQUADDING2RVAL(poppler_annot_free_text_get_quadding(SELF(self)));
30
- }
31
-
32
- static VALUE
33
- rg_callout_line(VALUE self)
34
- {
35
- return POPPLERANNOTCALLOUTLINE2RVAL(poppler_annot_free_text_get_callout_line(SELF(self)));
36
- }
37
-
38
- void
39
- Init_poppler_annotation_free_text(VALUE mPoppler)
40
- {
41
- VALUE RG_TARGET_NAMESPACE = G_DEF_CLASS(POPPLER_TYPE_ANNOT_FREE_TEXT,
42
- "AnnotationFreeText", mPoppler);
43
-
44
- RG_DEF_METHOD(quadding, 0);
45
- RG_DEF_METHOD(callout_line, 0);
46
- }
@@ -1,72 +0,0 @@
1
- /* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
2
- /*
3
- * Copyright (C) 2006-2013 Ruby-GNOME2 Project Team
4
- *
5
- * This library is free software; you can redistribute it and/or
6
- * modify it under the terms of the GNU Lesser General Public
7
- * License as published by the Free Software Foundation; either
8
- * version 2.1 of the License, or (at your option) any later version.
9
- *
10
- * This library is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Lesser General Public
16
- * License along with this library; if not, write to the Free Software
17
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
18
- * MA 02110-1301 USA
19
- */
20
-
21
- #include "rbpoppler-private.h"
22
-
23
- #define RG_TARGET_NAMESPACE cAnnotationMapping
24
-
25
- static VALUE
26
- rg_initialize(int argc, VALUE *argv, VALUE self)
27
- {
28
- VALUE area, annotation;
29
- PopplerAnnotMapping *mapping;
30
-
31
- rb_scan_args(argc, argv, "02", &area, &annotation);
32
-
33
- mapping = poppler_annot_mapping_new();
34
- mapping->area = *RVAL2POPPLERRECTANGLE(area);
35
- mapping->annot = RVAL2POPPLERANNOT(annotation);
36
- G_INITIALIZE(self, mapping);
37
-
38
- return Qnil;
39
- }
40
-
41
- DEF_ACCESSOR_WITH_SETTER(annot_mapping, area,
42
- RVAL2POPPLERANNOTMAPPING, RECT_ENTITY2RVAL, RECT_ENTITY_SET)
43
- DEF_READER(annot_mapping, annotation, annot, RVAL2POPPLERANNOTMAPPING, POPPLERANNOT2RVAL)
44
-
45
- static VALUE
46
- rg_set_annotation(VALUE self, VALUE annotation)
47
- {
48
- PopplerAnnotMapping *mapping;
49
-
50
- mapping = RVAL2POPPLERANNOTMAPPING(self);
51
- if (mapping->annot)
52
- g_object_unref(mapping->annot);
53
-
54
- mapping->annot = RVAL2POPPLERANNOT(annotation);
55
- return Qnil;
56
- }
57
-
58
- void
59
- Init_poppler_annotation_mapping(VALUE mPoppler)
60
- {
61
- VALUE RG_TARGET_NAMESPACE = G_DEF_CLASS(POPPLER_TYPE_ANNOT_MAPPING,
62
- "AnnotationMapping", mPoppler);
63
-
64
- RG_DEF_METHOD(initialize, -1);
65
-
66
- rbg_define_method(RG_TARGET_NAMESPACE, "area", annot_mapping_get_area, 0);
67
- rbg_define_method(RG_TARGET_NAMESPACE, "annotation",
68
- annot_mapping_get_annotation, 0);
69
-
70
- rbg_define_method(RG_TARGET_NAMESPACE, "set_area", annot_mapping_set_area, 1);
71
- RG_DEF_METHOD(set_annotation, 1);
72
- }
@@ -1,98 +0,0 @@
1
- /* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
2
- /*
3
- * Copyright (C) 2008-2013 Ruby-GNOME2 Project Team
4
- *
5
- * This library is free software; you can redistribute it and/or
6
- * modify it under the terms of the GNU Lesser General Public
7
- * License as published by the Free Software Foundation; either
8
- * version 2.1 of the License, or (at your option) any later version.
9
- *
10
- * This library is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Lesser General Public
16
- * License along with this library; if not, write to the Free Software
17
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
18
- * MA 02110-1301 USA
19
- */
20
-
21
- #include "rbpoppler-private.h"
22
-
23
- #define RG_TARGET_NAMESPACE cAnnotationMarkup
24
- #define SELF(self) (RVAL2POPPLERANNOTMARKUP(self))
25
-
26
- static ID id_new;
27
- static VALUE rb_cDate;
28
-
29
- static VALUE
30
- rg_label(VALUE self)
31
- {
32
- return CSTR2RVAL_FREE(poppler_annot_markup_get_label(SELF(self)));
33
- }
34
-
35
- static VALUE
36
- rg_popup_is_open_p(VALUE self)
37
- {
38
- return CBOOL2RVAL(poppler_annot_markup_get_popup_is_open(SELF(self)));
39
- }
40
-
41
- static VALUE
42
- rg_opacity(VALUE self)
43
- {
44
- return rb_float_new(poppler_annot_markup_get_opacity(SELF(self)));
45
- }
46
-
47
- static VALUE
48
- rg_date(VALUE self)
49
- {
50
- GDate *date;
51
- VALUE rb_date;
52
-
53
- date = poppler_annot_markup_get_date(SELF(self));
54
- rb_date = rb_funcall(rb_cDate, id_new, 3,
55
- UINT2NUM(g_date_get_year(date)),
56
- UINT2NUM(g_date_get_month(date)),
57
- UINT2NUM(g_date_get_day(date)));
58
- g_date_free(date);
59
- return rb_date;
60
- }
61
-
62
- static VALUE
63
- rg_subject(VALUE self)
64
- {
65
- return CSTR2RVAL_FREE(poppler_annot_markup_get_subject(SELF(self)));
66
- }
67
-
68
- static VALUE
69
- rg_reply_to(VALUE self)
70
- {
71
- return POPPLERANNOTMARKUPREPLYTYPE2RVAL(poppler_annot_markup_get_reply_to(SELF(self)));
72
- }
73
-
74
- static VALUE
75
- rg_external_data(VALUE self)
76
- {
77
- return POPPLERANNOTEXTERNALDATATYPE2RVAL(poppler_annot_markup_get_external_data(SELF(self)));
78
- }
79
-
80
- void
81
- Init_poppler_annotation_markup(VALUE mPoppler)
82
- {
83
- VALUE RG_TARGET_NAMESPACE;
84
-
85
- id_new = rb_intern("new");
86
- rb_cDate = rb_const_get(rb_cObject, rb_intern("Date"));
87
-
88
- RG_TARGET_NAMESPACE= G_DEF_CLASS(POPPLER_TYPE_ANNOT_MARKUP,
89
- "AnnotationMarkup", mPoppler);
90
-
91
- RG_DEF_METHOD(label, 0);
92
- RG_DEF_METHOD_P(popup_is_open, 0);
93
- RG_DEF_METHOD(opacity, 0);
94
- RG_DEF_METHOD(date, 0);
95
- RG_DEF_METHOD(subject, 0);
96
- RG_DEF_METHOD(reply_to, 0);
97
- RG_DEF_METHOD(external_data, 0);
98
- }
@@ -1,53 +0,0 @@
1
- /* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
2
- /*
3
- * Copyright (C) 2008-2013 Ruby-GNOME2 Project Team
4
- *
5
- * This library is free software; you can redistribute it and/or
6
- * modify it under the terms of the GNU Lesser General Public
7
- * License as published by the Free Software Foundation; either
8
- * version 2.1 of the License, or (at your option) any later version.
9
- *
10
- * This library is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Lesser General Public
16
- * License along with this library; if not, write to the Free Software
17
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
18
- * MA 02110-1301 USA
19
- */
20
-
21
- #include "rbpoppler-private.h"
22
-
23
- #define RG_TARGET_NAMESPACE cAnnotationText
24
- #define SELF(self) (RVAL2POPPLERANNOTTEXT(self))
25
-
26
- static VALUE
27
- rg_open_p(VALUE self)
28
- {
29
- return CBOOL2RVAL(poppler_annot_text_get_is_open(SELF(self)));
30
- }
31
-
32
- static VALUE
33
- rg_icon(VALUE self)
34
- {
35
- return CSTR2RVAL_FREE(poppler_annot_text_get_icon(SELF(self)));
36
- }
37
-
38
- static VALUE
39
- rg_state(VALUE self)
40
- {
41
- return POPPLERANNOTTEXTSTATE2RVAL(poppler_annot_text_get_state(SELF(self)));
42
- }
43
-
44
- void
45
- Init_poppler_annotation_text(VALUE mPoppler)
46
- {
47
- VALUE RG_TARGET_NAMESPACE = G_DEF_CLASS(POPPLER_TYPE_ANNOT_TEXT,
48
- "AnnotationText", mPoppler);
49
-
50
- RG_DEF_METHOD_P(open, 0);
51
- RG_DEF_METHOD(icon, 0);
52
- RG_DEF_METHOD(state, 0);
53
- }
@@ -1,74 +0,0 @@
1
- /* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
2
- /*
3
- * Copyright (C) 2011 Ruby-GNOME2 Project Team
4
- * Copyright (C) 2008 Ruby-GNOME2 Project Team
5
- *
6
- * This library is free software; you can redistribute it and/or
7
- * modify it under the terms of the GNU Lesser General Public
8
- * License as published by the Free Software Foundation; either
9
- * version 2.1 of the License, or (at your option) any later version.
10
- *
11
- * This library 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 GNU
14
- * Lesser General Public License for more details.
15
- *
16
- * You should have received a copy of the GNU Lesser General Public
17
- * License along with this library; if not, write to the Free Software
18
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
19
- * MA 02110-1301 USA
20
- */
21
-
22
- #include "rbpoppler-private.h"
23
-
24
- #define RG_TARGET_NAMESPACE cAnnotation
25
- #define SELF(self) (RVAL2POPPLERANNOT(self))
26
-
27
- static VALUE
28
- rg_type(VALUE self)
29
- {
30
- return POPPLERANNOTTYPE2RVAL(poppler_annot_get_annot_type(SELF(self)));
31
- }
32
-
33
- static VALUE
34
- rg_contents(VALUE self)
35
- {
36
- return CSTR2RVAL_FREE(poppler_annot_get_contents(SELF(self)));
37
- }
38
-
39
- static VALUE
40
- rg_name(VALUE self)
41
- {
42
- return CSTR2RVAL_FREE(poppler_annot_get_name(SELF(self)));
43
- }
44
-
45
- static VALUE
46
- rg_modified(VALUE self)
47
- {
48
- return CSTR2RVAL_FREE(poppler_annot_get_modified(SELF(self)));
49
- }
50
-
51
- static VALUE
52
- rg_flags(VALUE self)
53
- {
54
- return POPPLERANNOTFLAG2RVAL(poppler_annot_get_flags(SELF(self)));
55
- }
56
-
57
- static VALUE
58
- rg_color(VALUE self)
59
- {
60
- return POPPLERCOLOR2RVAL_FREE(poppler_annot_get_color(SELF(self)));
61
- }
62
-
63
- void
64
- Init_poppler_annotation(VALUE mPoppler)
65
- {
66
- VALUE RG_TARGET_NAMESPACE = G_DEF_CLASS(POPPLER_TYPE_ANNOT, "Annotation", mPoppler);
67
-
68
- RG_DEF_METHOD(type, 0);
69
- RG_DEF_METHOD(contents, 0);
70
- RG_DEF_METHOD(name, 0);
71
- RG_DEF_METHOD(modified, 0);
72
- RG_DEF_METHOD(flags, 0);
73
- RG_DEF_METHOD(color, 0);
74
- }