2 . "${srcdir=.}/init.sh"; path_prepend_ . ../src
4 # Test of Glade 2 support.
6 cat <<EOF > xg-gl-3-empty.glade
11 : ${XGETTEXT=xgettext}
12 ${XGETTEXT} -o xg-gl-3.pot xg-gl-3-empty.glade 2>/dev/null
14 echo "Skipping test: xgettext was built without Glade support"
18 cat <<EOF > xg-gl-3-asciitable.glade2
19 <?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
20 <!DOCTYPE glade-interface SYSTEM "glade-2.0.dtd" >
23 <widget class="GtkDialog" id="dialog">
24 <property name="visible">no</property>
25 <property name="title" translatable="yes">gedit: ASCII table</property>
26 <property name="type">GTK_WINDOW_TOPLEVEL</property>
27 <property name="modal">no</property>
28 <property name="allow_shrink">yes</property>
29 <property name="allow_grow">yes</property>
30 <property name="window-position">GTK_WIN_POS_NONE</property>
32 <child internal-child="vbox">
33 <widget class="GtkVBox" id="dialog-vbox1">
34 <property name="homogeneous">no</property>
35 <property name="spacing">8</property>
36 <property name="visible">yes</property>
38 <child internal-child="action_area">
39 <widget class="GtkHButtonBox" id="dialog-action_area1">
40 <property name="layout_style">GTK_BUTTONBOX_END</property>
41 <property name="spacing">8</property>
42 <property name="visible">yes</property>
45 <widget class="GtkButton" id="insert_char_button">
46 <property name="can_default">yes</property>
47 <property name="can_focus">yes</property>
48 <property name="label" translatable="yes">Insert char</property>
49 <property name="visible">yes</property>
54 <widget class="GtkButton" id="close_button">
55 <property name="can_default">yes</property>
56 <property name="can_focus">yes</property>
57 <property name="visible">yes</property>
58 <property name="label">gtk-close</property>
59 <property name="use_stock">yes</property>
60 <property name="use_underline">yes</property>
65 <widget class="GtkButton" id="help_button">
66 <property name="can_default">yes</property>
67 <property name="can_focus">yes</property>
68 <property name="visible">yes</property>
69 <property name="label">gtk-help</property>
70 <property name="use_stock">yes</property>
71 <property name="use_underline">yes</property>
76 <property name="padding">0</property>
77 <property name="expand">no</property>
78 <property name="fill">yes</property>
79 <property name="pack_type">GTK_PACK_END</property>
84 <widget class="GtkVBox" id="asciitable_dialog_content">
85 <property name="border_width">6</property>
86 <property name="homogeneous">no</property>
87 <property name="spacing">8</property>
88 <property name="visible">yes</property>
91 <widget class="GtkLabel" id="label1">
92 <property name="label" translatable="yes">If you wish to insert any of the characters in to the active
93 document, select the character and click the "Insert Char"
94 button or double click the character in the table.</property>
95 <property name="justify">GTK_JUSTIFY_LEFT</property>
96 <property name="wrap">no</property>
97 <property name="xalign">0.0</property>
98 <property name="yalign">0.5</property>
99 <property name="xpad">0</property>
100 <property name="ypad">0</property>
101 <property name="visible">yes</property>
104 <property name="padding">0</property>
105 <property name="expand">no</property>
106 <property name="fill">no</property>
111 <widget class="GtkScrolledWindow" id="scrolledwindow1">
112 <property name="hscrollbar_policy">GTK_POLICY_NEVER</property>
113 <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
114 <property name="shadow_type">GTK_SHADOW_IN</property>
115 <property name="height-request">350</property>
116 <property name="visible">yes</property>
119 <widget class="GtkTreeView" id="ascii_table">
120 <property name="can_focus">yes</property>
121 <property name="headers-visible">yes</property>
122 <property name="visible">yes</property>
126 <child internal-child="hscrollbar">
127 <widget class="GtkHScrollbar" id="convertwidget1">
128 <property name="update_policy">GTK_UPDATE_CONTINUOUS</property>
129 <property name="visible">yes</property>
133 <child internal-child="vscrollbar">
134 <widget class="GtkVScrollbar" id="convertwidget2">
135 <property name="update_policy">GTK_UPDATE_CONTINUOUS</property>
136 <property name="visible">yes</property>
141 <property name="padding">0</property>
142 <property name="expand">yes</property>
143 <property name="fill">yes</property>
148 <property name="padding">0</property>
149 <property name="expand">yes</property>
150 <property name="fill">yes</property>
155 <property name="padding">4</property>
156 <property name="expand">yes</property>
157 <property name="fill">yes</property>
164 : ${XGETTEXT=xgettext}
165 ${XGETTEXT} -o xg-gl-3.tmp xg-gl-3-asciitable.glade2 || exit 1
166 # Don't simplify this to "grep ... < xg-gl-3.tmp", otherwise OpenBSD 4.0 grep
167 # only outputs "Binary file (standard input) matches".
168 cat xg-gl-3.tmp | grep -v 'POT-Creation-Date' > xg-gl-3.pot
170 cat <<\EOF > xg-gl-3.ok
171 # SOME DESCRIPTIVE TITLE.
172 # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
173 # This file is distributed under the same license as the PACKAGE package.
174 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
179 "Project-Id-Version: PACKAGE VERSION\n"
180 "Report-Msgid-Bugs-To: \n"
181 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
182 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
183 "Language-Team: LANGUAGE <LL@li.org>\n"
185 "MIME-Version: 1.0\n"
186 "Content-Type: text/plain; charset=CHARSET\n"
187 "Content-Transfer-Encoding: 8bit\n"
189 #: xg-gl-3-asciitable.glade2:7
190 msgid "gedit: ASCII table"
193 #: xg-gl-3-asciitable.glade2:30
197 #: xg-gl-3-asciitable.glade2:74
199 "If you wish to insert any of the characters in to the active \n"
200 "document, select the character and click the \"Insert Char\" \n"
201 "button or double click the character in the table."
206 ${DIFF} xg-gl-3.ok xg-gl-3.pot