[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Pspp-cvs] pspp/src data/ChangeLog data/settings.c data/se...
From: |
Ben Pfaff |
Subject: |
[Pspp-cvs] pspp/src data/ChangeLog data/settings.c data/se... |
Date: |
Tue, 25 Sep 2007 04:26:25 +0000 |
CVSROOT: /cvsroot/pspp
Module name: pspp
Changes by: Ben Pfaff <blp> 07/09/25 04:26:25
Modified files:
src/data : ChangeLog settings.c settings.h
src/ui/terminal: ChangeLog command-line.c msg-ui.c
Log message:
Patch #6210. Reviewed by John Darrington.
* command-line.c (parse_command_line): Don't call force_long_view,
as that function is no longer necessary.
* msg-ui.c (handle_msg): Only wrap message output to the message
file to the width of the terminal if the message file is a tty.
* settings.c: Drop "long view", which is not needed any longer.
(static var long_view): Removed.
(force_long_view): Removed.
(get_viewwidth): Removed.
(init_viewport): Removed long_view reference.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/pspp/src/data/ChangeLog?cvsroot=pspp&r1=1.160&r2=1.161
http://cvs.savannah.gnu.org/viewcvs/pspp/src/data/settings.c?cvsroot=pspp&r1=1.12&r2=1.13
http://cvs.savannah.gnu.org/viewcvs/pspp/src/data/settings.h?cvsroot=pspp&r1=1.7&r2=1.8
http://cvs.savannah.gnu.org/viewcvs/pspp/src/ui/terminal/ChangeLog?cvsroot=pspp&r1=1.30&r2=1.31
http://cvs.savannah.gnu.org/viewcvs/pspp/src/ui/terminal/command-line.c?cvsroot=pspp&r1=1.16&r2=1.17
http://cvs.savannah.gnu.org/viewcvs/pspp/src/ui/terminal/msg-ui.c?cvsroot=pspp&r1=1.16&r2=1.17
Patches:
Index: data/ChangeLog
===================================================================
RCS file: /cvsroot/pspp/pspp/src/data/ChangeLog,v
retrieving revision 1.160
retrieving revision 1.161
diff -u -b -r1.160 -r1.161
--- data/ChangeLog 25 Sep 2007 04:16:19 -0000 1.160
+++ data/ChangeLog 25 Sep 2007 04:26:25 -0000 1.161
@@ -1,3 +1,12 @@
+2007-09-24 Ben Pfaff <address@hidden>
+
+ Patch #6210. Reviewed by John Darrington.
+ * settings.c: Drop "long view", which is not needed any longer.
+ (static var long_view): Removed.
+ (force_long_view): Removed.
+ (get_viewwidth): Removed.
+ (init_viewport): Removed long_view reference.
+
2007-09-19 John Darrington <address@hidden>
* settings.c settings.h: Changed viewport's length and width to be
Index: data/settings.c
===================================================================
RCS file: /cvsroot/pspp/pspp/src/data/settings.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -b -r1.12 -r1.13
--- data/settings.c 25 Sep 2007 04:16:19 -0000 1.12
+++ data/settings.c 25 Sep 2007 04:26:25 -0000 1.13
@@ -31,7 +31,6 @@
static int *viewlength = NULL;
static int *viewwidth = NULL;
-static bool long_view = false;
static bool safer_mode = false;
@@ -103,21 +102,10 @@
*viewlength = viewlength_;
}
-/* Set view width to a very long value, and prevent it from ever
- changing. */
-void
-force_long_view (void)
-{
- long_view = true;
-}
-
/* Screen width. */
int
get_viewwidth(void)
{
- if (long_view)
- return 9999;
-
return *viewwidth;
}
@@ -133,10 +121,6 @@
{
viewwidth = width;
viewlength = length;
-
- if (long_view)
- return;
-
}
/* Whether PSPP can erase and overwrite files. */
Index: data/settings.h
===================================================================
RCS file: /cvsroot/pspp/pspp/src/data/settings.h,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- data/settings.h 25 Sep 2007 04:16:19 -0000 1.7
+++ data/settings.h 25 Sep 2007 04:26:25 -0000 1.8
@@ -23,7 +23,6 @@
void settings_init (int *, int *);
void settings_done (void);
-void force_long_view (void);
int get_viewlength (void);
void set_viewlength (int);
Index: ui/terminal/ChangeLog
===================================================================
RCS file: /cvsroot/pspp/pspp/src/ui/terminal/ChangeLog,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -b -r1.30 -r1.31
--- ui/terminal/ChangeLog 25 Sep 2007 04:19:11 -0000 1.30
+++ ui/terminal/ChangeLog 25 Sep 2007 04:26:25 -0000 1.31
@@ -1,8 +1,14 @@
2007-09-24 Ben Pfaff <address@hidden>
+ Patch #6210. Reviewed by John Darrington.
* main.c (set_fallback_viewport): Make code easier to understand.
(get_termcap_viewport): Ditto.
- Reviewed by John Darrington.
+
+ * command-line.c (parse_command_line): Don't call force_long_view,
+ as that function is no longer necessary.
+
+ * msg-ui.c (handle_msg): Only wrap message output to the message
+ file to the width of the terminal if the message file is a tty.
2007-09-19 John Darrington <address@hidden>
Index: ui/terminal/command-line.c
===================================================================
RCS file: /cvsroot/pspp/pspp/src/ui/terminal/command-line.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- ui/terminal/command-line.c 5 Sep 2007 06:23:04 -0000 1.16
+++ ui/terminal/command-line.c 25 Sep 2007 04:26:25 -0000 1.17
@@ -171,7 +171,6 @@
puts (legal);
return false;
case 'T':
- force_long_view ();
set_testing_mode (true);
break;
case '?':
Index: ui/terminal/msg-ui.c
===================================================================
RCS file: /cvsroot/pspp/pspp/src/ui/terminal/msg-ui.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- ui/terminal/msg-ui.c 13 Sep 2007 10:06:00 -0000 1.16
+++ ui/terminal/msg-ui.c 25 Sep 2007 04:26:25 -0000 1.17
@@ -32,6 +32,7 @@
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
+#include <unistd.h>
#include "gettext.h"
#define _(msgid) gettext (msgid)
@@ -175,7 +176,8 @@
ds_put_cstr (&string, m->text);
if (msg_file != stdout || get_error_routing_to_terminal ())
- dump_message (ds_cstr (&string), get_viewwidth (), 8,
+ dump_message (ds_cstr (&string),
+ isatty (fileno (msg_file)) ? get_viewwidth () : INT_MAX, 8,
write_stream, msg_file);
dump_message (ds_cstr (&string), 78, 0, write_journal, NULL);