Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 79079
Collapse All | Expand All

(-)inkblot-0.99.6.orig/configure.in (-1 / +1 lines)
Lines 35-41 Link Here
35
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [GetText Package])
35
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [GetText Package])
36
36
37
dnl Add the languages which your application supports here.
37
dnl Add the languages which your application supports here.
38
ALL_LINGUAS="en_GB"
38
ALL_LINGUAS="en_GB de_DE"
39
AM_GLIB_GNU_GETTEXT
39
AM_GLIB_GNU_GETTEXT
40
40
41
AC_OUTPUT([
41
AC_OUTPUT([
(-)inkblot-0.99.6.orig/po/de_DE.po (+195 lines)
Line 0 Link Here
1
# translation of de_DE.po to german
2
# German translation of the inkblot.
3
# Copyright (C) 2007
4
# This file is distributed under the same license as the inkblot package.
5
#
6
# Christoph Brill <egore911@egore911.de>, 2007.
7
msgid ""
8
msgstr ""
9
"Project-Id-Version: de_DE\n"
10
"Report-Msgid-Bugs-To: \n"
11
"POT-Creation-Date: 2007-01-07 14:58+0100\n"
12
"PO-Revision-Date: 2007-01-07 15:02+0100\n"
13
"Last-Translator: Christoph Brill <egore911@egore911.de>\n"
14
"Language-Team: german <de@li.org>\n"
15
"MIME-Version: 1.0\n"
16
"Content-Type: text/plain; charset=UTF-8\n"
17
"Content-Transfer-Encoding: 8bit\n"
18
19
#: src/eggtrayicon.c:118
20
msgid "Orientation"
21
msgstr "Ausrichtung"
22
23
#: src/eggtrayicon.c:119
24
msgid "The orientation of the tray."
25
msgstr "Ausrichtung im Benachrichtigungsfeld."
26
27
#: src/main.c:104
28
msgid "Ink level: high"
29
msgstr "Tintenfüllstand: hoch"
30
31
#: src/main.c:107
32
msgid "Ink level: medium"
33
msgstr "Tintenfüllstand: mittel"
34
35
#: src/main.c:110
36
msgid "Ink level: low"
37
msgstr "Tintenfüllstand: gering"
38
39
#: src/main.c:113
40
msgid "Printer off or ink empty"
41
msgstr "Drucker ist aus oder Tinte ist alle"
42
43
#: src/main.c:116
44
msgid "Error: problem with printer"
45
msgstr "Fehler: Druckerproblem"
46
47
#: src/main.c:304
48
msgid ""
49
"No supported printers found.\n"
50
"\n"
51
"Please check your printer and cables and restart Inkblot."
52
msgstr ""
53
"Keine unterstützten Drucker gefunden\n"
54
"\n"
55
"Bitte prüfen sie ihren Drucker und ihre Kabel und starten sie anschließend "
56
"Inkblot neu."
57
58
#: src/main.c:311
59
msgid ""
60
"No supported printers found.\n"
61
"\n"
62
"Please check your printer and cables and scan for printers again."
63
msgstr ""
64
"Keine unterstützten Drucker gefunden\n"
65
"\n"
66
"Bitte prüfen sie ihren Drucker und ihre Kabel und suchen anschließend erneut "
67
"nach Druckern."
68
69
#: src/main.c:318
70
msgid ""
71
"Inkblot was not installed correctly\n"
72
"and the inkblot.glade file could not be found."
73
msgstr ""
74
"Inkblot wurde nicht ordnungsgemäß installiert.\n"
75
" Es konnte die Datei inkblot.glade nicht finden."
76
77
#: src/main.c:324
78
msgid ""
79
"Inkblot got an invalid response from the printer.\n"
80
"\n"
81
"Please check your printer and check the libinklevel homepage if your printer "
82
"is supported."
83
msgstr ""
84
"Inkblot erhielt eine ungültige Anwort vom Drucker.\n"
85
"\n"
86
"Bitte prüfen sie ihren Drucker und überprüfen sie auf der Internetseite von "
87
"libinklevel ob ihr Drucker unterstützt wird."
88
89
#: src/main.c:332
90
msgid "An unexpected error occurred."
91
msgstr "Ein unerwarteter Fehler ist aufgetreten."
92
93
#: src/main.c:339
94
msgid "Inkblot Error"
95
msgstr "Inkblot Fehler"
96
97
#: src/detect.c:72
98
msgid "Choose Printer Not Implemented"
99
msgstr "Drucker wählen ist nocht nicht implementiert."
100
101
#: src/detect.c:81
102
msgid "parallel port"
103
msgstr "Paralleler Port"
104
105
#: src/detect.c:83
106
msgid "USB"
107
msgstr "USB"
108
109
#: src/detect.c:86
110
#, c-format
111
msgid ""
112
"Found <i>%s</i> %s printer on %s\n"
113
"\n"
114
"Inkblot will report the ink level on this device."
115
msgstr ""
116
"Drucker <i>%s</i> %s wurde an %s gefunden.\n"
117
"\n"
118
"Inkblot wird den Tintenfüllstand für diesen Drucker melden."
119
120
#: src/detect.c:96
121
msgid "Printer Detection Complete"
122
msgstr "Druckersuche abgeschlossen"
123
124
#: src/detect.c:99
125
msgid "Inkblot Setup"
126
msgstr "Inkblot einrichten"
127
128
#: src/menu.c:46
129
msgid "Reports on your printer ink levels.\n"
130
msgstr "Prüft den Tintenfüllstand ihres Druckers.\n"
131
132
#: src/menu.c:70
133
msgid "Rescan Printer Devices"
134
msgstr "Druckersuche durchführen"
135
136
#: src/menu.c:79
137
msgid "About Inkblot"
138
msgstr "Über Inkblot"
139
140
#: src/menu.c:87
141
msgid "Exit Inkblot"
142
msgstr "Inkblot beenden"
143
144
#: inkblot.schemas.in.h:1
145
msgid "1 = Parallel Port, 2 = USB"
146
msgstr "1 = Paralleler Port, 2 = USB"
147
148
#: inkblot.schemas.in.h:2
149
msgid ""
150
"If this key is set, inkblot will try to find new devices and will set up the "
151
"other keys."
152
msgstr ""
153
"Wenn dieser Schlüssel gesetzt ist, versucht inkblot neue Geräte zu finden "
154
"und wird andere Schlüssel setzen."
155
156
#: inkblot.schemas.in.h:3
157
msgid "libinklevel bus type"
158
msgstr "libinklevel Bus-Typ"
159
160
#: inkblot.schemas.in.h:4
161
msgid "libinklevel config indicator"
162
msgstr "libinklevel Konfigurationsindikator"
163
164
#: inkblot.schemas.in.h:5
165
msgid "libinklevel port number"
166
msgstr "libinklevel Portnummer"
167
168
#: inkblot.schemas.in.h:6
169
msgid "the number of the lp port - ie. 0 = lp0"
170
msgstr "Die Nummer des Druckersports - z.B. 0 = lp0"
171
172
#: inkblot.desktop.in.h:1
173
msgid "Check your printer ink cartridge levels"
174
msgstr "Prüft den Füllstand ihrer Druckertinte"
175
176
#: inkblot.desktop.in.h:2
177
msgid "Inkblot"
178
msgstr "Inkblot"
179
180
#: inkblot.desktop.in.h:3
181
msgid "Printer Ink Level Monitor"
182
msgstr "Tintenfüllstands-Monitor"
183
184
#: glade/inkblot.glade.h:2
185
#, no-c-format
186
msgid "10%"
187
msgstr "10%"
188
189
#: glade/inkblot.glade.h:3
190
msgid "Colour Details"
191
msgstr "Farbdetails"
192
193
#: glade/inkblot.glade.h:4
194
msgid "Inkblot Printer Monitor"
195
msgstr "Inkblot Druckermonitor"
(-)inkblot-0.99.6.orig/po/en_GB.po (-42 / +75 lines)
Lines 1-20 Link Here
1
# SOME DESCRIPTIVE TITLE.
1
# translation of en_GB.po to german
2
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
2
# English translation of the inkblot.
3
# This file is distributed under the same license as the PACKAGE package.
3
# Copyright (C) 2004-2007
4
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
4
# This file is distributed under the same license as the inkblot package.
5
#
5
#
6
#, fuzzy
6
# Mike Newman <mikegtn@gnome.org>, 2004.
7
# Christoph Brill <egore911@egore911.de>, 2007.
7
msgid ""
8
msgid ""
8
msgstr ""
9
msgstr ""
9
"Project-Id-Version: 0.99.4\n"
10
"Project-Id-Version: en_GB\n"
10
"Report-Msgid-Bugs-To: \n"
11
"Report-Msgid-Bugs-To: \n"
11
"POT-Creation-Date: 2004-07-04 14:50+0100\n"
12
"POT-Creation-Date: 2007-01-07 14:58+0100\n"
12
"PO-Revision-Date: 2004-07-03 09:16+0100\n"
13
"PO-Revision-Date: 2007-01-07 15:04+0100\n"
13
"Last-Translator: Mike Newman <mikegtn@gnome.org>\n"
14
"Last-Translator: Christoph Brill <egore911@egore911.de>\n"
14
"Language-Team: English <en@li.org>\n"
15
"Language-Team: german <de@li.org>\n"
15
"MIME-Version: 1.0\n"
16
"MIME-Version: 1.0\n"
16
"Content-Type: text/plain; charset=UTF-8\n"
17
"Content-Type: text/plain; charset=UTF-8\n"
17
"Content-Transfer-Encoding: 8bit\n"
18
"Content-Transfer-Encoding: 8bit\n"
19
"X-Generator: KBabel 1.11.4\n"
18
20
19
#: src/eggtrayicon.c:118
21
#: src/eggtrayicon.c:118
20
msgid "Orientation"
22
msgid "Orientation"
Lines 26-125 Link Here
26
28
27
#: src/main.c:104
29
#: src/main.c:104
28
msgid "Ink level: high"
30
msgid "Ink level: high"
29
msgstr ""
31
msgstr "Ink level: high"
30
32
31
#: src/main.c:107
33
#: src/main.c:107
32
msgid "Ink level: medium"
34
msgid "Ink level: medium"
33
msgstr ""
35
msgstr "Ink level: medium"
34
36
35
#: src/main.c:110
37
#: src/main.c:110
36
msgid "Ink level: low"
38
msgid "Ink level: low"
37
msgstr ""
39
msgstr "Ink level: low"
38
40
39
#: src/main.c:113
41
#: src/main.c:113
40
msgid "Printer off or ink empty"
42
msgid "Printer off or ink empty"
41
msgstr ""
43
msgstr "Printer off or ink empty"
42
44
43
#: src/main.c:116
45
#: src/main.c:116
44
msgid "Error: problem with printer"
46
msgid "Error: problem with printer"
45
msgstr ""
47
msgstr "Error: problem with printer"
46
48
47
#: src/main.c:300
49
#: src/main.c:304
48
msgid ""
50
msgid ""
49
"No supported printers found.\n"
51
"No supported printers found.\n"
50
"\n"
52
"\n"
51
"Please check your printer and cables and restart Inkblot."
53
"Please check your printer and cables and restart Inkblot."
52
msgstr ""
54
msgstr ""
55
"No supported printers found.\n"
56
"\n"
57
"Please check your printer and cables and restart Inkblot."
53
58
54
#: src/main.c:307
59
#: src/main.c:311
55
msgid ""
60
msgid ""
56
"No supported printers found.\n"
61
"No supported printers found.\n"
57
"\n"
62
"\n"
58
"Please check your printer and cables and scan for printers again."
63
"Please check your printer and cables and scan for printers again."
59
msgstr ""
64
msgstr ""
65
"No supported printers found.\n"
66
"\n"
67
"Please check your printer and cables and scan for printers again."
60
68
61
#: src/main.c:314
69
#: src/main.c:318
62
msgid ""
70
msgid ""
63
"Inkblot was not installed correctly\n"
71
"Inkblot was not installed correctly\n"
64
"and the inkblot.glade file could not be found."
72
"and the inkblot.glade file could not be found."
65
msgstr ""
73
msgstr ""
74
"Inkblot was not installed correctly\n"
75
"and the inkblot.glade file could not be found."
66
76
67
#: src/main.c:320
77
#: src/main.c:324
68
msgid "An unexpected error occurred."
78
msgid ""
79
"Inkblot got an invalid response from the printer.\n"
80
"\n"
81
"Please check your printer and check the libinklevel homepage if your printer "
82
"is supported."
69
msgstr ""
83
msgstr ""
84
"Inkblot got an invalid response from the printer.\n"
85
"\n"
86
"Please check your printer and check the libinklevel homepage if your printer "
87
"is supported."
70
88
71
#: src/main.c:327
89
#: src/main.c:332
72
#, fuzzy
90
msgid "An unexpected error occurred."
91
msgstr "An unexpected error occurred."
92
93
#: src/main.c:339
73
msgid "Inkblot Error"
94
msgid "Inkblot Error"
74
msgstr "Inkblot"
95
msgstr "Inkblot Error"
75
96
76
#: src/detect.c:71
97
#: src/detect.c:72
77
msgid "Choose Printer Not Implemented"
98
msgid "Choose Printer Not Implemented"
78
msgstr ""
99
msgstr "Choose Printer Not Implemented"
79
100
80
#: src/detect.c:80
101
#: src/detect.c:81
81
msgid "parallel port"
102
msgid "parallel port"
82
msgstr ""
103
msgstr "parallel port"
83
104
84
#: src/detect.c:82
105
#: src/detect.c:83
85
msgid "USB"
106
msgid "USB"
86
msgstr ""
107
msgstr "USB"
87
108
88
#: src/detect.c:85
109
#: src/detect.c:86
89
#, c-format
110
#, c-format
90
msgid ""
111
msgid ""
91
"Found <i>%s</i> %s printer on %s\n"
112
"Found <i>%s</i> %s printer on %s\n"
92
"\n"
113
"\n"
93
"Inkblot will report the ink level on this device."
114
"Inkblot will report the ink level on this device."
94
msgstr ""
115
msgstr ""
116
"Found <i>%s</i> %s printer on %s\n"
117
"\n"
118
"Inkblot will report the ink level on this device."
95
119
96
#: src/detect.c:95
120
#: src/detect.c:96
97
msgid "Printer Detection Complete"
121
msgid "Printer Detection Complete"
98
msgstr ""
122
msgstr "Printer Detection Complete"
99
123
100
#: src/detect.c:98
124
#: src/detect.c:99
101
#, fuzzy
102
msgid "Inkblot Setup"
125
msgid "Inkblot Setup"
103
msgstr "Inkblot"
126
msgstr "Inkblot Setup"
104
127
105
#: src/menu.c:46
128
#: src/menu.c:46
106
#, fuzzy
107
msgid "Reports on your printer ink levels.\n"
129
msgid "Reports on your printer ink levels.\n"
108
msgstr "Check your printer ink cartridge levels"
130
msgstr "Check your printer ink cartridge levels\n"
109
131
110
#: src/menu.c:70
132
#: src/menu.c:70
111
msgid "Rescan Printer Devices"
133
msgid "Rescan Printer Devices"
112
msgstr ""
134
msgstr "Rescan Printer Devices"
113
135
114
#: src/menu.c:79
136
#: src/menu.c:79
115
#, fuzzy
116
msgid "About Inkblot"
137
msgid "About Inkblot"
117
msgstr "Inkblot"
138
msgstr "About Inkblot"
118
139
119
#: src/menu.c:87
140
#: src/menu.c:87
120
#, fuzzy
121
msgid "Exit Inkblot"
141
msgid "Exit Inkblot"
122
msgstr "Inkblot"
142
msgstr "Exit Inkblot"
123
143
124
#: inkblot.schemas.in.h:1
144
#: inkblot.schemas.in.h:1
125
msgid "1 = Parallel Port, 2 = USB"
145
msgid "1 = Parallel Port, 2 = USB"
Lines 160-162 Link Here
160
#: inkblot.desktop.in.h:3
180
#: inkblot.desktop.in.h:3
161
msgid "Printer Ink Level Monitor"
181
msgid "Printer Ink Level Monitor"
162
msgstr "Printer Ink Level Monitor"
182
msgstr "Printer Ink Level Monitor"
183
184
#: glade/inkblot.glade.h:2
185
#, no-c-format
186
msgid "10%"
187
msgstr "10%"
188
189
#: glade/inkblot.glade.h:3
190
msgid "Colour Details"
191
msgstr "Color Details"
192
193
#: glade/inkblot.glade.h:4
194
msgid "Inkblot Printer Monitor"
195
msgstr "Inkblot Printer Monitor"
(-)inkblot-0.99.6.orig/po/inkblot.pot (-12 / +33 lines)
Lines 8-14 Link Here
8
msgstr ""
8
msgstr ""
9
"Project-Id-Version: PACKAGE VERSION\n"
9
"Project-Id-Version: PACKAGE VERSION\n"
10
"Report-Msgid-Bugs-To: \n"
10
"Report-Msgid-Bugs-To: \n"
11
"POT-Creation-Date: 2004-07-04 14:50+0100\n"
11
"POT-Creation-Date: 2007-01-07 14:58+0100\n"
12
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
12
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14
"Language-Team: LANGUAGE <LL@li.org>\n"
14
"Language-Team: LANGUAGE <LL@li.org>\n"
Lines 44-90 Link Here
44
msgid "Error: problem with printer"
44
msgid "Error: problem with printer"
45
msgstr ""
45
msgstr ""
46
46
47
#: src/main.c:300
47
#: src/main.c:304
48
msgid ""
48
msgid ""
49
"No supported printers found.\n"
49
"No supported printers found.\n"
50
"\n"
50
"\n"
51
"Please check your printer and cables and restart Inkblot."
51
"Please check your printer and cables and restart Inkblot."
52
msgstr ""
52
msgstr ""
53
53
54
#: src/main.c:307
54
#: src/main.c:311
55
msgid ""
55
msgid ""
56
"No supported printers found.\n"
56
"No supported printers found.\n"
57
"\n"
57
"\n"
58
"Please check your printer and cables and scan for printers again."
58
"Please check your printer and cables and scan for printers again."
59
msgstr ""
59
msgstr ""
60
60
61
#: src/main.c:314
61
#: src/main.c:318
62
msgid ""
62
msgid ""
63
"Inkblot was not installed correctly\n"
63
"Inkblot was not installed correctly\n"
64
"and the inkblot.glade file could not be found."
64
"and the inkblot.glade file could not be found."
65
msgstr ""
65
msgstr ""
66
66
67
#: src/main.c:320
67
#: src/main.c:324
68
msgid ""
69
"Inkblot got an invalid response from the printer.\n"
70
"\n"
71
"Please check your printer and check the libinklevel homepage if your printer "
72
"is supported."
73
msgstr ""
74
75
#: src/main.c:332
68
msgid "An unexpected error occurred."
76
msgid "An unexpected error occurred."
69
msgstr ""
77
msgstr ""
70
78
71
#: src/main.c:327
79
#: src/main.c:339
72
msgid "Inkblot Error"
80
msgid "Inkblot Error"
73
msgstr ""
81
msgstr ""
74
82
75
#: src/detect.c:71
83
#: src/detect.c:72
76
msgid "Choose Printer Not Implemented"
84
msgid "Choose Printer Not Implemented"
77
msgstr ""
85
msgstr ""
78
86
79
#: src/detect.c:80
87
#: src/detect.c:81
80
msgid "parallel port"
88
msgid "parallel port"
81
msgstr ""
89
msgstr ""
82
90
83
#: src/detect.c:82
91
#: src/detect.c:83
84
msgid "USB"
92
msgid "USB"
85
msgstr ""
93
msgstr ""
86
94
87
#: src/detect.c:85
95
#: src/detect.c:86
88
#, c-format
96
#, c-format
89
msgid ""
97
msgid ""
90
"Found <i>%s</i> %s printer on %s\n"
98
"Found <i>%s</i> %s printer on %s\n"
Lines 92-102 Link Here
92
"Inkblot will report the ink level on this device."
100
"Inkblot will report the ink level on this device."
93
msgstr ""
101
msgstr ""
94
102
95
#: src/detect.c:95
103
#: src/detect.c:96
96
msgid "Printer Detection Complete"
104
msgid "Printer Detection Complete"
97
msgstr ""
105
msgstr ""
98
106
99
#: src/detect.c:98
107
#: src/detect.c:99
100
msgid "Inkblot Setup"
108
msgid "Inkblot Setup"
101
msgstr ""
109
msgstr ""
102
110
Lines 153-155 Link Here
153
#: inkblot.desktop.in.h:3
161
#: inkblot.desktop.in.h:3
154
msgid "Printer Ink Level Monitor"
162
msgid "Printer Ink Level Monitor"
155
msgstr ""
163
msgstr ""
164
165
#: glade/inkblot.glade.h:2
166
#, no-c-format
167
msgid "10%"
168
msgstr ""
169
170
#: glade/inkblot.glade.h:3
171
msgid "Colour Details"
172
msgstr ""
173
174
#: glade/inkblot.glade.h:4
175
msgid "Inkblot Printer Monitor"
176
msgstr ""
(-)inkblot-0.99.6.orig/po/missing (+3 lines)
Line 0 Link Here
1
glade/inkblot.glade
2
inkblot.desktop.in.h
3
inkblot.schemas.in.h
(-)inkblot-0.99.6.orig/po/POTFILES.in (-8 / +11 lines)
Lines 1-8 Link Here
1
./src/eggtrayicon.h
1
src/eggtrayicon.h
2
./src/eggtrayicon.c
2
src/eggtrayicon.c
3
./src/main.c
3
src/main.c
4
./src/detect.c
4
src/detect.c
5
./src/menu.c
5
src/menu.c
6
./src/inkblot.h
6
src/inkblot.h
7
./inkblot.schemas.in
7
inkblot.schemas.in
8
./inkblot.desktop.in
8
inkblot.desktop.in
9
glade/inkblot.glade
10
inkblot.desktop.in.h
11
inkblot.schemas.in.h
(-)inkblot-0.99.6.orig/src/detect.c (-2 / +3 lines)
Lines 44-57 Link Here
44
	for (bus=0; bus <3; bus++) {
44
	for (bus=0; bus <3; bus++) {
45
		for (port=0; port<17; port++) {
45
		for (port=0; port<17; port++) {
46
			result = get_ink_level (bus, port, &device);
46
			result = get_ink_level (bus, port, &device);
47
			if (result == 0) {
47
			if (result == OK) {
48
				InkblotPrinter *dev = g_new0(InkblotPrinter,1);
48
				InkblotPrinter *dev = g_new0(InkblotPrinter,1);
49
				dev->model = g_strdup(device.model);
49
				dev->model = g_strdup(device.model);
50
				dev->bus = bus;
50
				dev->bus = bus;
51
				dev->port = port;
51
				dev->port = port;
52
				dev->type = device.type;
53
				printers = g_list_prepend (printers, dev);
52
				printers = g_list_prepend (printers, dev);
54
				num_printers++;
53
				num_printers++;
54
			} else {
55
				printf("Result was %d\n", result);
55
			}
56
			}
56
		}
57
		}
57
	}
58
	}
(-)inkblot-0.99.6.orig/src/inkblot.h (-1 / +1 lines)
Lines 36-41 Link Here
36
	INKBLOT_ERROR_GLADE,
36
	INKBLOT_ERROR_GLADE,
37
	INKBLOT_ERROR_NO_CONFIG,
37
	INKBLOT_ERROR_NO_CONFIG,
38
	INKBLOT_ERROR_NO_PRINTER,
38
	INKBLOT_ERROR_NO_PRINTER,
39
	INKBLOT_ERROR_INVALID_RESPONSE,
39
	INKBLOT_ERROR_UNKNOWN
40
	INKBLOT_ERROR_UNKNOWN
40
} InkblotError;
41
} InkblotError;
41
42
Lines 52-58 Link Here
52
	gchar *model;
53
	gchar *model;
53
	gint bus;
54
	gint bus;
54
	gint port;
55
	gint port;
55
	gint type;
56
} InkblotPrinter;
56
} InkblotPrinter;
57
57
58
/* Inkblot - Function Definitions */
58
/* Inkblot - Function Definitions */
(-)inkblot-0.99.6.orig/src/main.c (-19 / +31 lines)
Lines 211-238 Link Here
211
	mg_prog = glade_xml_get_widget (glade,"mg_prog");
211
	mg_prog = glade_xml_get_widget (glade,"mg_prog");
212
	yl_prog = glade_xml_get_widget (glade,"yl_prog");
212
	yl_prog = glade_xml_get_widget (glade,"yl_prog");
213
        get_ink_level (pref_bus, pref_port, &level);
213
        get_ink_level (pref_bus, pref_port, &level);
214
	if (level.status != RESPONSE_VALID) {
215
		inkblot_error_dialog ( INKBLOT_ERROR_INVALID_RESPONSE );
216
		exit(1);
217
	}
214
	/* if no colour level reported, but individual reservoirs
218
	/* if no colour level reported, but individual reservoirs
215
         * available, report an average */
219
         * available, report an average (emulates cartridge with 3 inks) */
216
        if (level.color == 0 && (level.cyan || level.magenta || level.yellow)) {
220
        if (level.levels[CARTRIDGE_COLOR][INDEX_LEVEL] == 0 && (level.levels[CARTRIDGE_CYAN][INDEX_LEVEL] || level.levels[CARTRIDGE_MAGENTA][INDEX_LEVEL] || level.levels[CARTRIDGE_YELLOW][INDEX_LEVEL])) {
217
                level.color = ( level.cyan + level.magenta + level.yellow ) / 3;
221
                level.levels[CARTRIDGE_COLOR][INDEX_LEVEL] = ( level.levels[CARTRIDGE_CYAN][INDEX_LEVEL] + level.levels[CARTRIDGE_MAGENTA][INDEX_LEVEL] + level.levels[CARTRIDGE_YELLOW][INDEX_LEVEL] ) / 3;
218
        }
222
        }
219
	black = g_strdup_printf("%d%%",level.black);
223
	black = g_strdup_printf("%d%%",level.levels[CARTRIDGE_BLACK][INDEX_LEVEL]);
220
        color = g_strdup_printf("%d%%",level.color);
224
        color = g_strdup_printf("%d%%",level.levels[CARTRIDGE_COLOR][INDEX_LEVEL]);
221
	cyan = g_strdup_printf("%d%%",level.cyan);
225
	cyan = g_strdup_printf("%d%%",level.levels[CARTRIDGE_CYAN][INDEX_LEVEL]);
222
	magenta = g_strdup_printf("%d%%",level.magenta);
226
	magenta = g_strdup_printf("%d%%",level.levels[CARTRIDGE_MAGENTA][INDEX_LEVEL]);
223
	yellow = g_strdup_printf("%d%%",level.yellow);
227
	yellow = g_strdup_printf("%d%%",level.levels[CARTRIDGE_YELLOW][INDEX_LEVEL]);
224
        gtk_label_set_text(GTK_LABEL(b_label),black);
228
        gtk_label_set_text(GTK_LABEL(b_label),black);
225
        gtk_label_set_text(GTK_LABEL(c_label),color);
229
        gtk_label_set_text(GTK_LABEL(c_label),color);
226
	gtk_label_set_text(GTK_LABEL(cy_label),cyan);
230
	gtk_label_set_text(GTK_LABEL(cy_label),cyan);
227
	gtk_label_set_text(GTK_LABEL(mg_label),magenta);
231
	gtk_label_set_text(GTK_LABEL(mg_label),magenta);
228
	gtk_label_set_text(GTK_LABEL(yl_label),yellow);
232
	gtk_label_set_text(GTK_LABEL(yl_label),yellow);
229
        gtk_progress_set_value(GTK_PROGRESS(b_prog),level.black);
233
        gtk_progress_set_value(GTK_PROGRESS(b_prog),level.levels[CARTRIDGE_BLACK][INDEX_LEVEL]);
230
        gtk_progress_set_value(GTK_PROGRESS(c_prog),level.color);
234
        gtk_progress_set_value(GTK_PROGRESS(c_prog),level.levels[CARTRIDGE_COLOR][INDEX_LEVEL]);
231
	gtk_progress_set_value(GTK_PROGRESS(cy_prog),level.cyan);
235
	gtk_progress_set_value(GTK_PROGRESS(cy_prog),level.levels[CARTRIDGE_CYAN][INDEX_LEVEL]);
232
	gtk_progress_set_value(GTK_PROGRESS(mg_prog),level.magenta);
236
	gtk_progress_set_value(GTK_PROGRESS(mg_prog),level.levels[CARTRIDGE_MAGENTA][INDEX_LEVEL]);
233
	gtk_progress_set_value(GTK_PROGRESS(yl_prog),level.yellow);
237
	gtk_progress_set_value(GTK_PROGRESS(yl_prog),level.levels[CARTRIDGE_YELLOW][INDEX_LEVEL]);
234
	gtk_window_set_title(GTK_WINDOW(dialog),level.model);
238
	gtk_window_set_title(GTK_WINDOW(dialog),level.model);
235
	if (level.cyan || level.magenta || level.yellow) {
239
	if (level.levels[CARTRIDGE_CYAN][INDEX_LEVEL] || level.levels[CARTRIDGE_MAGENTA][INDEX_LEVEL] || level.levels[CARTRIDGE_YELLOW][INDEX_LEVEL]) {
236
		gtk_widget_set_sensitive(expander,TRUE);
240
		gtk_widget_set_sensitive(expander,TRUE);
237
	} else {
241
	} else {
238
		gtk_widget_set_sensitive(expander,FALSE);
242
		gtk_widget_set_sensitive(expander,FALSE);
Lines 258-270 Link Here
258
	gint result;
262
	gint result;
259
	result = get_ink_level (pref_bus, pref_port, &level);
263
	result = get_ink_level (pref_bus, pref_port, &level);
260
	if (result < 0) return INKBLOT_ERROR;
264
	if (result < 0) return INKBLOT_ERROR;
261
	color = level.color;
265
	color = level.levels[CARTRIDGE_COLOR][INDEX_LEVEL];
262
	/* if no colour level reported, but individual reservoirs
266
	/* if no colour level reported, but individual reservoirs
263
	 * available, report an average */
267
	 * available, report an average */
264
	if (color == 0 && (level.cyan || level.magenta || level.yellow)) {
268
	if (color == 0 && (level.levels[CARTRIDGE_CYAN][INDEX_LEVEL] || level.levels[CARTRIDGE_MAGENTA][INDEX_LEVEL] || level.levels[CARTRIDGE_YELLOW][INDEX_LEVEL])) {
265
		color = ( level.cyan + level.magenta + level.yellow ) / 3;
269
		color = ( level.levels[CARTRIDGE_CYAN][INDEX_LEVEL] + level.levels[CARTRIDGE_MAGENTA][INDEX_LEVEL] + level.levels[CARTRIDGE_YELLOW][INDEX_LEVEL] ) / 3;
266
	}
270
	}
267
	black = level.black;
271
	black = level.levels[CARTRIDGE_BLACK][INDEX_LEVEL];
268
	total = color+black/2;
272
	total = color+black/2;
269
	if (total>66) return INKBLOT_OK;
273
	if (total>66) return INKBLOT_OK;
270
	if (total>33) return INKBLOT_WARN;
274
	if (total>33) return INKBLOT_WARN;
Lines 310-321 Link Here
310
                buttons = GTK_BUTTONS_CLOSE;
314
                buttons = GTK_BUTTONS_CLOSE;
311
                type = GTK_MESSAGE_WARNING;
315
                type = GTK_MESSAGE_WARNING;
312
                break;
316
                break;
313
	  case INKBLOT_ERROR_GLADE:
317
	case INKBLOT_ERROR_GLADE:
314
		message = g_strdup (_("Inkblot was not installed correctly\n"
318
		message = g_strdup (_("Inkblot was not installed correctly\n"
315
				      "and the inkblot.glade file could not "
319
				      "and the inkblot.glade file could not "
316
				      "be found."));
320
				      "be found."));
317
		type = GTK_MESSAGE_ERROR;
321
		type = GTK_MESSAGE_ERROR;
318
		buttons = GTK_BUTTONS_CLOSE;
322
		buttons = GTK_BUTTONS_CLOSE;
323
	case INKBLOT_ERROR_INVALID_RESPONSE:
324
		message = g_strdup (_("Inkblot got an invalid response from "
325
		                      "the printer.\n\n"
326
		                      "Please check your printer and check the "
327
				      "libinklevel homepage if your printer is "
328
				      "supported."));
329
		type = GTK_MESSAGE_ERROR;
330
		buttons = GTK_BUTTONS_CLOSE;
319
	  default:
331
	  default:
320
		message = g_strdup (_("An unexpected error occurred."));
332
		message = g_strdup (_("An unexpected error occurred."));
321
                buttons = GTK_BUTTONS_CLOSE;
333
                buttons = GTK_BUTTONS_CLOSE;

Return to bug 79079