X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fui%2Fgui%2Fpsppire.c;h=a7b22037b868e7d523726c8f80faab41ebe1acc8;hb=4d70434db549461d1391db27a165f36be5a39378;hp=239d153e4b0d5ca3454f2080f7c21946181cb2af;hpb=1dabf6c48c0f5827a933af82c01a26bdf55488bd;p=pspp-builds.git diff --git a/src/ui/gui/psppire.c b/src/ui/gui/psppire.c index 239d153e..a7b22037 100644 --- a/src/ui/gui/psppire.c +++ b/src/ui/gui/psppire.c @@ -1,5 +1,5 @@ /* PSPPIRE - a graphical user interface for PSPP. - Copyright (C) 2004, 2005, 2006 Free Software Foundation + Copyright (C) 2004, 2005, 2006, 2009 Free Software Foundation This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -79,7 +79,7 @@ initialize (void) So unset the bits we want to control ourselves */ setlocale (LC_NUMERIC, "C"); - bindtextdomain (PACKAGE, locale_dir); + bindtextdomain (PACKAGE, relocate (locale_dir)); glade_init (); @@ -111,13 +111,25 @@ initialize (void) create_icon_factory (); - outp_configure_driver_line ( - ss_cstr ("gui:ascii:screen:squeeze=on headers=off top-margin=0 " - "bottom-margin=0 paginate=off length=auto width=auto " - "emphasis=none " - "output-file=\"" OUTPUT_FILE_NAME "\" append=yes")); + { + const char *filename = output_file_name (); + + struct string config_string; + + ds_init_empty (&config_string); + + ds_put_format (&config_string, + "gui:ascii:screen:squeeze=on headers=off top-margin=0 " + "bottom-margin=0 paginate=off length=auto width=auto " + "emphasis=none " + "output-file=\"%s\" append=yes", filename); - unlink (OUTPUT_FILE_NAME); + outp_configure_driver_line (ds_ss (&config_string)); + + unlink (filename); + + ds_destroy (&config_string); + } journal_enable (); textdomain (PACKAGE);