1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
|
Description: Add a -t apptitle argument to fenix-fxi.
Forwarded: no
Author: Miriam Ruiz <little_miry@yahoo.es>
Last-Update: 2007-08-02
Index: fenix-0.92a.dfsg1/fxi/src/main.c
===================================================================
--- fenix-0.92a.dfsg1.orig/fxi/src/main.c 2007-08-28 14:41:00.000000000 +0200
+++ fenix-0.92a.dfsg1/fxi/src/main.c 2007-08-28 14:41:06.000000000 +0200
@@ -260,6 +260,19 @@
//if (argv[i][j] == 'b') double_buffer = 1 ;
if (argv[i][j] == 'f') enable_filtering = 1 ;
+ if (argv[i][j] == 't')
+ {
+ if (argv[i][j+1] == 0)
+ {
+ if (i == argc-1)
+ gr_error (_("You must provide a title")) ;
+ if (apptitle) free(apptitle);
+ apptitle = strdup(argv[i+1]);
+ i++ ;
+ break ;
+ }
+ }
+
if (argv[i][j] == 'i')
{
if (argv[i][j+1] == 0)
@@ -317,7 +330,13 @@
/* Init application title for windowed modes */
strcpy (dcbname, filename) ;
- apptitle = strdup(filename) ;
+ if (!apptitle)
+ {
+ if (strcmp(filename, "-") != 0)
+ apptitle = strdup(filename) ;
+ else
+ apptitle = strdup("Fenix") ;
+ }
#ifdef TARGET_MAC
strcpy (files[current_file], filename);
|