~ubuntu-branches/ubuntu/vivid/emscripten/vivid

« back to all changes in this revision

Viewing changes to tests/poppler/glib/poppler-form-field.h

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2013-05-02 13:11:51 UTC
  • Revision ID: package-import@ubuntu.com-20130502131151-q8dvteqr1ef2x7xz
Tags: upstream-1.4.1~20130504~adb56cb
ImportĀ upstreamĀ versionĀ 1.4.1~20130504~adb56cb

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* poppler-form-field.h: glib interface to poppler
 
2
 *
 
3
 * Copyright (C) 2007 Carlos Garcia Campos <carlosgc@gnome.org>
 
4
 *
 
5
 * This program is free software; you can redistribute it and/or modify
 
6
 * it under the terms of the GNU General Public License as published by
 
7
 * the Free Software Foundation; either version 2, or (at your option)
 
8
 * any later version.
 
9
 *
 
10
 * This program 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
 
13
 * GNU General Public License for more details.
 
14
 *
 
15
 * You should have received a copy of the GNU General Public License
 
16
 * along with this program; if not, write to the Free Software
 
17
 * Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
 
18
 */
 
19
 
 
20
#ifndef __POPPLER_FORM_FIELD_H__
 
21
#define __POPPLER_FORM_FIELD_H__
 
22
 
 
23
#include <glib-object.h>
 
24
#include "poppler.h"
 
25
 
 
26
G_BEGIN_DECLS
 
27
 
 
28
#define POPPLER_TYPE_FORM_FIELD             (poppler_form_field_get_type ())
 
29
#define POPPLER_FORM_FIELD(obj)             (G_TYPE_CHECK_INSTANCE_CAST ((obj), POPPLER_TYPE_FORM_FIELD, PopplerFormField))
 
30
#define POPPLER_IS_FORM_FIELD(obj)          (G_TYPE_CHECK_INSTANCE_TYPE ((obj), POPPLER_TYPE_FORM_FIELD))
 
31
 
 
32
typedef enum
 
33
{
 
34
  POPPLER_FORM_FIELD_UNKNOWN,
 
35
  POPPLER_FORM_FIELD_BUTTON,
 
36
  POPPLER_FORM_FIELD_TEXT,
 
37
  POPPLER_FORM_FIELD_CHOICE,
 
38
  POPPLER_FORM_FIELD_SIGNATURE
 
39
} PopplerFormFieldType;
 
40
 
 
41
typedef enum
 
42
{
 
43
  POPPLER_FORM_BUTTON_PUSH,
 
44
  POPPLER_FORM_BUTTON_CHECK,
 
45
  POPPLER_FORM_BUTTON_RADIO
 
46
} PopplerFormButtonType;
 
47
 
 
48
typedef enum
 
49
{
 
50
  POPPLER_FORM_TEXT_NORMAL,
 
51
  POPPLER_FORM_TEXT_MULTILINE,
 
52
  POPPLER_FORM_TEXT_FILE_SELECT
 
53
} PopplerFormTextType;
 
54
 
 
55
typedef enum
 
56
{
 
57
  POPPLER_FORM_CHOICE_COMBO,
 
58
  POPPLER_FORM_CHOICE_LIST
 
59
} PopplerFormChoiceType;
 
60
 
 
61
GType                 poppler_form_field_get_type                (void) G_GNUC_CONST;
 
62
 
 
63
PopplerFormFieldType  poppler_form_field_get_field_type          (PopplerFormField *field);
 
64
gint                  poppler_form_field_get_id                  (PopplerFormField *field);
 
65
gdouble               poppler_form_field_get_font_size           (PopplerFormField *field);
 
66
gboolean              poppler_form_field_is_read_only            (PopplerFormField *field);
 
67
gchar                *poppler_form_field_get_partial_name        (PopplerFormField *field);
 
68
gchar                *poppler_form_field_get_mapping_name        (PopplerFormField *field);
 
69
gchar                *poppler_form_field_get_name                (PopplerFormField *field);
 
70
 
 
71
/* Button Field */
 
72
PopplerFormButtonType poppler_form_field_button_get_button_type  (PopplerFormField *field);
 
73
gboolean              poppler_form_field_button_get_state        (PopplerFormField *field);
 
74
void                  poppler_form_field_button_set_state        (PopplerFormField *field,
 
75
                                                                  gboolean          state);
 
76
 
 
77
/* Text Field */
 
78
PopplerFormTextType   poppler_form_field_text_get_text_type      (PopplerFormField *field);
 
79
gchar                *poppler_form_field_text_get_text           (PopplerFormField *field);
 
80
void                  poppler_form_field_text_set_text           (PopplerFormField *field,
 
81
                                                                  const gchar      *text);
 
82
gint                  poppler_form_field_text_get_max_len        (PopplerFormField *field);
 
83
gboolean              poppler_form_field_text_do_spell_check     (PopplerFormField *field);
 
84
gboolean              poppler_form_field_text_do_scroll          (PopplerFormField *field);
 
85
gboolean              poppler_form_field_text_is_rich_text       (PopplerFormField *field);
 
86
gboolean              poppler_form_field_text_is_password        (PopplerFormField *field);
 
87
 
 
88
/* Choice Field */
 
89
PopplerFormChoiceType poppler_form_field_choice_get_choice_type  (PopplerFormField *field);
 
90
gboolean              poppler_form_field_choice_is_editable      (PopplerFormField *field);
 
91
gboolean           poppler_form_field_choice_can_select_multiple (PopplerFormField *field);
 
92
gboolean              poppler_form_field_choice_do_spell_check   (PopplerFormField *field);
 
93
gboolean              poppler_form_field_choice_commit_on_change (PopplerFormField *field);
 
94
gint                  poppler_form_field_choice_get_n_items      (PopplerFormField *field);
 
95
gchar                *poppler_form_field_choice_get_item         (PopplerFormField *field,
 
96
                                                                  gint              index);
 
97
gboolean              poppler_form_field_choice_is_item_selected (PopplerFormField *field,
 
98
                                                                  gint              index);
 
99
void                  poppler_form_field_choice_select_item      (PopplerFormField *field,
 
100
                                                                  gint              index);
 
101
void                  poppler_form_field_choice_unselect_all     (PopplerFormField *field);
 
102
void                  poppler_form_field_choice_toggle_item      (PopplerFormField *field,
 
103
                                                                  gint              index);
 
104
void                  poppler_form_field_choice_set_text         (PopplerFormField *field,
 
105
                                                                  const gchar      *text);
 
106
gchar                *poppler_form_field_choice_get_text         (PopplerFormField *field);
 
107
 
 
108
G_END_DECLS
 
109
 
 
110
#endif /* __POPPLER_FORM_FIELD_H__ */