Mercurial > mplayer.hg
annotate gui/dialog/about.c @ 36672:e1e9f2ea17c9
Revise GUI help message texts.
Remove colons, ellipses and newlines from the end of the texts.
This reduces the amount of texts to be translated, enhances reusability
and harmonizes the visual appearance of the different GUI localizations.
Additionally, make the necessary code changes.
author | ib |
---|---|
date | Fri, 31 Jan 2014 16:37:52 +0000 |
parents | 7d250553d451 |
children | eed2fb870f43 |
rev | line source |
---|---|
26458 | 1 /* |
2 * This file is part of MPlayer. | |
3 * | |
4 * MPlayer is free software; you can redistribute it and/or modify | |
5 * it under the terms of the GNU General Public License as published by | |
6 * the Free Software Foundation; either version 2 of the License, or | |
7 * (at your option) any later version. | |
8 * | |
9 * MPlayer is distributed in the hope that it will be useful, | |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 * GNU General Public License for more details. | |
13 * | |
14 * You should have received a copy of the GNU General Public License along | |
15 * with MPlayer; if not, write to the Free Software Foundation, Inc., | |
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. | |
17 */ | |
18 | |
26203 | 19 #include "config.h" |
35525 | 20 #include "gui/app/app.h" |
36053 | 21 #include "gui/app/gui.h" |
23077 | 22 #include "help_mp.h" |
33963 | 23 #include "version.h" |
23077 | 24 |
35526 | 25 #include "pixmaps/emblem.xpm" |
35529 | 26 #include "dialog.h" |
23077 | 27 #include "about.h" |
33572 | 28 #include "tools.h" |
23077 | 29 |
30 GtkWidget * About = NULL; | |
31 | |
34466
a650895d50a5
Use correct data types and common variable names in GTK callback functions.
ib
parents:
33963
diff
changeset
|
32 static void abWidgetDestroy( GtkButton * button, gpointer user_data ) |
36010 | 33 { |
34 (void) button; | |
35 (void) user_data; | |
36 | |
37 gtk_widget_destroy( About ); | |
38 } | |
23077 | 39 |
35996 | 40 static GtkWidget * CreateAbout( void ) |
23077 | 41 { |
42 GtkWidget * vbox; | |
43 GtkWidget * pixmap1; | |
44 GtkWidget * scrolledwindow1; | |
45 GtkWidget * AboutText; | |
46 GtkWidget * Ok; | |
47 | |
27343 | 48 #ifdef CONFIG_GTK2 |
23077 | 49 GtkTextBuffer * AboutTextBuffer; |
50 GtkTextIter iter; | |
27343 | 51 #endif /* CONFIG_GTK2 */ |
23077 | 52 |
53 GtkStyle * pixmapstyle; | |
54 GdkPixmap * pixmapwid; | |
55 GdkBitmap * mask; | |
56 | |
57 GtkAccelGroup * accel_group; | |
58 | |
33963 | 59 char title[128]; |
60 | |
23077 | 61 accel_group=gtk_accel_group_new(); |
62 | |
63 About=gtk_window_new( GTK_WINDOW_TOPLEVEL ); | |
64 gtk_widget_set_usize( About,340,415 ); | |
36670 | 65 gtk_window_set_title( GTK_WINDOW( About ),MSGTR_MENU_AboutMPlayer ); |
23077 | 66 gtk_window_set_position( GTK_WINDOW( About ),GTK_WIN_POS_CENTER ); |
36059 | 67 gtk_window_set_policy( GTK_WINDOW( About ),FALSE,FALSE,TRUE ); |
36053 | 68 gtk_window_set_wmclass( GTK_WINDOW( About ),"About",MPlayer ); |
23077 | 69 |
70 gtk_widget_realize( About ); | |
71 gtkAddIcon( About ); | |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
72 |
36023
a04e8798227b
Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents:
36019
diff
changeset
|
73 vbox=gtkAddVBox( gtkAddDialogFrame( About ),0 ); |
23077 | 74 |
75 pixmapstyle=gtk_widget_get_style( About ); | |
33570 | 76 pixmapwid=gdk_pixmap_colormap_create_from_xpm_d( About->window,gdk_colormap_get_system(),&mask,&pixmapstyle->bg[GTK_STATE_NORMAL],(gchar **) emblem_xpm ); |
23077 | 77 pixmap1=gtk_pixmap_new( pixmapwid,mask ); |
78 | |
79 gtk_widget_show( pixmap1 ); | |
80 gtk_box_pack_start( GTK_BOX( vbox ),pixmap1,FALSE,FALSE,0 ); | |
81 gtk_widget_set_usize( pixmap1,-2,174 ); | |
82 | |
36023
a04e8798227b
Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents:
36019
diff
changeset
|
83 gtkAddHSeparator( vbox ); |
23077 | 84 |
85 scrolledwindow1=gtk_scrolled_window_new( NULL,NULL ); | |
86 gtk_widget_show( scrolledwindow1 ); | |
87 gtk_box_pack_start( GTK_BOX( vbox ),scrolledwindow1,TRUE,TRUE,0 ); | |
88 gtk_scrolled_window_set_policy( GTK_SCROLLED_WINDOW( scrolledwindow1 ),GTK_POLICY_AUTOMATIC,GTK_POLICY_AUTOMATIC ); | |
89 | |
27343 | 90 #ifdef CONFIG_GTK2 |
23077 | 91 AboutText = gtk_text_view_new(); |
92 gtk_text_view_set_editable(GTK_TEXT_VIEW(AboutText), FALSE); | |
93 gtk_text_view_set_cursor_visible(GTK_TEXT_VIEW(AboutText), FALSE); | |
94 AboutTextBuffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (AboutText)); | |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
95 gtk_text_buffer_get_iter_at_offset (AboutTextBuffer, &iter, 0); |
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
96 #else |
23077 | 97 AboutText=gtk_text_new( NULL,NULL ); |
98 gtk_text_set_editable(GTK_TEXT(AboutText), FALSE); | |
99 #endif | |
100 gtk_widget_show( AboutText ); | |
101 gtk_container_add( GTK_CONTAINER( scrolledwindow1 ),AboutText ); | |
36053 | 102 snprintf(title, sizeof(title), MP_TITLE, MPlayer); |
27343 | 103 #ifdef CONFIG_GTK2 |
33963 | 104 gtk_text_buffer_insert (AboutTextBuffer, &iter, title, -1); |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
105 gtk_text_buffer_insert (AboutTextBuffer, &iter, |
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
106 #else |
33963 | 107 gtk_text_insert( GTK_TEXT( AboutText ),NULL,NULL,NULL, title, -1 ); |
23077 | 108 gtk_text_insert( GTK_TEXT( AboutText ),NULL,NULL,NULL, |
109 #endif | |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
110 "\n" |
36672 | 111 MSGTR_ABOUT_UHU":\n" |
36670 | 112 " http://www.uhulinux.hu/\n" |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
113 "\n" |
36672 | 114 MSGTR_ABOUT_Contributors":\n" |
23077 | 115 "\n" |
33963 | 116 " * Andreas Ackermann\n" |
23077 | 117 " * adland\n" |
33963 | 118 " * Eric Anholt\n" |
119 " * Folke Ashberg\n" | |
120 " * Dénes Balatoni\n" | |
121 " * Zsolt Barat\n" | |
122 " * Luca Barbato\n" | |
123 " * Dmitry Baryshkov\n" | |
124 " * Bertrand Baudet\n" | |
125 " * Alban Bedel\n" | |
126 " * Michael Behrisch\n" | |
127 " * Luchezar Belev\n" | |
128 " * Gábor Bérczi\n" | |
129 " * Szabolcs Berecz\n" | |
130 " * Alex Beregszászi\n" | |
131 " * Tilmann Bitterberg\n" | |
132 " * Diego Biurrun\n" | |
133 " * Marcsu Blomenkamp\n" | |
134 " * Ingo Brückl\n" | |
135 " * Andrew Buehler\n" | |
136 " * Eviv Bulgroz\n" | |
137 " * Felix Bünemann\n" | |
138 " * Moritz Bunkus\n" | |
139 " * Dan Villiom Podlaski Christiansen\n" | |
140 " * Jeff Clagg\n" | |
141 " * compn\n" | |
142 " * Marcus Comstedt\n" | |
143 " * Kees Cook\n" | |
144 " * Stephen Davies\n" | |
145 " * Piero Di Vita\n" | |
146 " * Tobias Diedrich\n" | |
147 " * Florian Dietrich\n" | |
148 " * Jeroen Dobbelaere\n" | |
149 " * Reimar Döffinger\n" | |
150 " * Romain Dolbeau\n" | |
151 " * Ismail Dönmez\n" | |
152 " * Robert Edele\n" | |
153 " * Christoph Egger\n" | |
154 " * Paul Wilhelm Elsinghorst\n" | |
155 " * Bernd Ernesti\n" | |
156 " * Salvatore Falco\n" | |
157 " * Johannes Feigl\n" | |
158 " * D Richard III Felker\n" | |
159 " * Tim Ferguson\n" | |
160 " * Ross Finlayson\n" | |
161 " * Daniele Forghieri\n" | |
162 " * Kilian A. Foth\n" | |
163 " * Fabian Franz\n" | |
164 " * Martin Gansser\n" | |
165 " * Árpád Gereöffy\n" | |
166 " * Matteo Giani\n" | |
167 " * Sven Goethel\n" | |
168 " * German Gomez Garcia\n" | |
169 " * Alexander Gottwald\n" | |
170 " * Michael Graffam\n" | |
171 " * Andriy N. Gritsenko\n" | |
172 " * Rémi Guyomarch\n" | |
173 " * Jürgen Hammelmann\n" | |
174 " * Christopher R. Hertel\n" | |
175 " * Andreas Hess\n" | |
176 " * Corey Hickey\n" | |
177 " * Zoltán Hidvégi\n" | |
178 " * Jens Hoffmann\n" | |
179 " * David Holm\n" | |
180 " * Bohdan Horst\n" | |
181 " * Hampa Hug\n" | |
182 " * Tomas Hurka\n" | |
183 " * Sidik Isani\n" | |
184 " * Panagiotis Issaris\n" | |
185 " * Aurelien Jacobs\n" | |
186 " * Reza Jelveh\n" | |
187 " * Jonas Jermann\n" | |
188 " * Anders Johansson\n" | |
189 " * Nicholas Kain\n" | |
190 " * Filip Kalinski\n" | |
191 " * Ivan Kalvachev\n" | |
192 " * Wojtek Kaniewski\n" | |
193 " * Kim Minh Kaplan\n" | |
194 " * Samuli Kärkkäinen\n" | |
195 " * Jürgen Keil\n" | |
196 " * Robert Kesterson\n" | |
197 " * Attila Kinali\n" | |
198 " * Gregory Kovriga\n" | |
199 " * David Kühling\n" | |
200 " * Fredrik Kuivinen\n" | |
201 " * Nick Kurshev\n" | |
202 " * Brian Kuschak\n" | |
203 " * Vladimir Kushnir\n" | |
204 " * Dave Lambley\n" | |
205 " * Gyula László\n" | |
206 " * Nicolas Le Gaillart\n" | |
207 " * Gábor Lénárt\n" | |
208 " * Colin Leroy\n" | |
209 " * Oskar Liljeblad\n" | |
210 " * Sam Lin\n" | |
211 " * Pierre Lombard\n" | |
212 " * Puk Madick\n" | |
213 " * Jindrich Makovicka\n" | |
214 " * Rudolf Marek\n" | |
215 " * László Megyer\n" | |
216 " * Mike Melanson\n" | |
217 " * Arwed von Merkatz\n" | |
218 " * Loren Merritt\n" | |
219 " * Dominik Mierzejewski\n" | |
220 " * Mihail Milushev\n" | |
221 " * Nehal Mistry\n" | |
222 " * András Mohari\n" | |
223 " * Steven Mueller\n" | |
224 " * Alexander Neundorf\n" | |
225 " * Michael Niedermayer\n" | |
226 " * Fredrik Noring\n" | |
227 " * Christian Ohm\n" | |
228 " * Joey Parrish\n" | |
229 " * Dariusz Pietrzak\n" | |
230 " * Nicolas Plourde\n" | |
231 " * Lennart Poettering\n" | |
232 " * Guillaume Poirier\n" | |
233 " * Zoltán Ponekker\n" | |
234 " * Ivo van Poorten\n" | |
235 " * Lu Ran\n" | |
236 " * Uwe Reder\n" | |
23077 | 237 " * rgselk\n" |
238 " * Rune Petersen\n" | |
33963 | 239 " * Ville Saari\n" |
240 " * Nico Sabbi\n" | |
241 " * Björn Sandell\n" | |
242 " * Tilman Sauerbeck\n" | |
243 " * Frank Scherthan\n" | |
244 " * Florian Schneider\n" | |
245 " * Oliver Schoenbrunner\n" | |
246 " * Oded Shimon\n" | |
247 " * Peter Simon\n" | |
248 " * Rik Snel\n" | |
249 " * Sascha Sommer\n" | |
250 " * Alexander Strasser\n" | |
251 " * Kamil Strzelecki\n" | |
252 " * Jiri Svoboda\n" | |
253 " * Robert Swain\n" | |
254 " * Ville Syrjälä\n" | |
255 " * Gabor Szecsi\n" | |
256 " * Jason Tackaberry\n" | |
257 " * Howell Tam\n" | |
258 " * Adam Tlalka\n" | |
259 " * Gianluigi Tiesi\n" | |
260 " * Roberto Togni\n" | |
261 " * Salvador Eduardo Tropea\n" | |
262 " * Miklós Vajna\n" | |
263 " * Reynaldo H. Verdejo Pinochet\n" | |
264 " * Per Wigren\n" | |
265 " * Derek J Witt\n" | |
266 " * Alan Young\n" | |
267 " * Artur Zaprzala\n" | |
268 " * Mark Zealey\n" | |
269 " * Matan Ziv-Av\n" | |
270 " * Márk Vicián Zoltán\n" | |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
271 "\n" |
36672 | 272 MSGTR_ABOUT_Codecs_libs_contributions":\n" |
23077 | 273 "\n" |
33963 | 274 " * Fabrice Bellard\n" |
275 " * Vivien Chappelier\n" | |
276 " * Michael Hipp\n" | |
277 " * Aaron Holtzman\n" | |
278 " * Jake Janovetz\n" | |
279 " * Zdenek Kabelac\n" | |
280 " * Eugene Kuznetsov\n" | |
281 " * Michel Lespinasse\n" | |
282 " * Mark Podlipec\n" | |
283 " * Damien Vincent\n" | |
23077 | 284 "\n" |
36672 | 285 MSGTR_ABOUT_Translations":\n" |
23077 | 286 "\n" |
33963 | 287 " * Marcin Biernat\n" |
288 " * Marc Fargas\n" | |
289 " * Jiri Heryan\n" | |
290 " * Marek Jarycki\n" | |
291 " * Leszek Kaplita\n" | |
292 " * Sebastian Krämer\n" | |
293 " * Juan Martin López\n" | |
294 " * Piotr Michniewski\n" | |
295 " * Jakub Misiorny\n" | |
296 " * Gábor Mizda\n" | |
297 " * Maciej Paszta\n" | |
298 " * Łukasz Proszek\n" | |
299 " * Wacław Schiller\n" | |
300 " * Andoni Zubimendi\n" | |
23077 | 301 "\n" |
36672 | 302 MSGTR_ABOUT_Skins":\n" |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27343
diff
changeset
|
303 "\n" |
23077 | 304 " * Azrael\n" |
33963 | 305 " * Viktor Bekesi\n" |
306 " * Ingo Brückl\n" | |
307 " * Andrew Carpenter\n" | |
308 " * Charles Foucault\n" | |
309 " * Attila Gyimesi\n" | |
310 " * Alban Hertroys\n" | |
311 " * Balint Kiss\n" | |
312 " * Andre Kuehne\n" | |
313 " * Rüdiger Kuhlmann\n" | |
314 " * Dan Naumov\n" | |
315 " * Ryan Northam\n" | |
316 " * Juan Pablo Oyarzun Arroyo\n" | |
317 " * DongCheon Park\n" | |
318 " * Jurgen Pehrson\n" | |
319 " * Nikola Pizurica\n" | |
320 " * Oliwier Ptak\n" | |
321 " * Pasquale Riccio\n" | |
23077 | 322 " * Burt.S.\n" |
33963 | 323 " * Jesper Schultz\n" |
324 " * Marcin Szumiela\n" | |
325 " * Massimo Tisi\n" | |
326 " * Jiri jun. Tyr\n" | |
327 " * Ognian Vasilev\n" | |
328 " * Imre Veres\n" | |
329 " * Radic Vesko\n" | |
330 " * Balasz Vigvary\n" | |
331 " * Andrew Weber\n" | |
332 " * Gary Jr. Whitmore\n" | |
333 " * Franciszek Wilamowski\n" | |
334 " * Michael Zeising", -1 ); | |
23077 | 335 |
36023
a04e8798227b
Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents:
36019
diff
changeset
|
336 gtkAddHSeparator( vbox ); |
a04e8798227b
Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents:
36019
diff
changeset
|
337 Ok=gtkAddButton( MSGTR_Ok,gtkAddHButtonBox( vbox ) ); |
23077 | 338 |
36008 | 339 gtk_signal_connect( GTK_OBJECT( About ),"destroy",GTK_SIGNAL_FUNC( gtk_widget_destroyed ),&About ); |
23077 | 340 gtk_signal_connect_object( GTK_OBJECT( Ok ),"clicked",GTK_SIGNAL_FUNC( abWidgetDestroy ),NULL ); |
341 | |
342 gtk_widget_add_accelerator( Ok,"clicked",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE ); | |
343 gtk_widget_add_accelerator( Ok,"clicked",accel_group,GDK_Return,0,GTK_ACCEL_VISIBLE ); | |
344 gtk_window_add_accel_group( GTK_WINDOW( About ),accel_group ); | |
345 | |
346 return About; | |
347 } | |
35989 | 348 |
349 void ShowAbout( void ) | |
350 { | |
36019 | 351 if ( About ) gtkRaise( About ); |
35996 | 352 else About=CreateAbout(); |
35989 | 353 gtk_widget_show( About ); |
354 } |