Ben Pfaff [Wed, 8 Feb 2012 06:08:41 +0000 (22:08 -0800)]
sys-file: Recode string fields in file header also.
Chris Muller <chris.muller@mullermedia.com> provided an example
EBCDIC-encoded mainframe system file from the 1980s. This commit
goes one step toward being able to read and write these files in
PSPP, by recoding most of the string fields in the file header.
John Darrington [Sat, 4 Feb 2012 07:44:05 +0000 (08:44 +0100)]
New abstract base class: PsppireWindowBase
Created a new abstract base class for windows/dialogs and moved the
psppire_conf manipulation to there. Should fix problems reported by bojo42
where the window geometry wasn't always correctly saved.
Ben Pfaff [Fri, 27 Jan 2012 06:06:02 +0000 (22:06 -0800)]
Move PSPP shared libraries from $(libdir) to $(libdir)/pspp.
The PSPP shared libraries do not have a stable ABI and so they
should not go in a public system library directory. This moves
them to a private library subdirectory.
Ben Pfaff [Fri, 27 Jan 2012 05:27:36 +0000 (21:27 -0800)]
Name the src/libpspp convenience library consistently.
src/libpspp.la and src/libpspp/libpspp.la have the same name,
although they are in different directories. This seems unduly
confusing. This commit renames the latter to liblibpspp.la, which
is at least different from libpspp.la and is also consistent with
the naming of the other libtool convenience libraries as
lib<directory>.la.
John Darrington [Thu, 12 Jan 2012 20:21:54 +0000 (21:21 +0100)]
Avoid deprecated Perl syntax.
Apparently new perl versions don't like qw(x y z) without outer parentheses. See
http://search.cpan.org/~flora/perl-5.14.2/pod/perl5140delta.pod#Use_of_qw%28...%29_as_parentheses
John Darrington [Wed, 11 Jan 2012 21:04:14 +0000 (22:04 +0100)]
Use idle callback to write to the local config directory
When the users config directory is on a filesystem with high latency,
moving a dialog box resulted in many writes and thus an unacceptable
delay. This change fixes that by consolidating the writes into a
low priority idle callback.
Ben Pfaff [Wed, 11 Jan 2012 04:52:11 +0000 (20:52 -0800)]
Fix PSPP link on OpenSUSE and possibly Ubuntu 11.10.
Reported-by: friedrich nietzsche <f_nietsje@hotmail.com>
at http://comments.gmane.org/gmane.comp.statistics.pspp.devel/4850 Reported-by: Luis Cebamanos <luiceur@gmail.com>
at http://comments.gmane.org/gmane.comp.statistics.pspp.devel/4869 Reported-by: Mindaugus <embar@super.lt> Tested-by: Mindaugus <embar@super.lt>
Ben Pfaff [Sat, 7 Jan 2012 21:14:02 +0000 (13:14 -0800)]
cairo: Only apply options to table items, to avoid crash.
Most of the members of struct xr_rendering, including the 'xr'
member, are used only for table items. In chart items, these
members are zeroed. But xr_rendering_apply_options() attempted to
use the 'xr' member even for chart items, which caused a crash.
This reverts and replaces the provisional fix already applied by
John Darrington in commit ee7b576822f (Avoid crash rendering charts
in the gui interface.), which also fixed the crash but added extra
unnecessary work.
Reported-by: Nick Macdonald <nick@nickmacdonald.net>
John Darrington [Thu, 22 Dec 2011 19:57:23 +0000 (20:57 +0100)]
Set the output driver parameters dynamically from the output window style.
This change allows the output driver options to be changed after the driver
has been created. This is necessary in the GUI to follow the style changes
(eg from theme engines etc)
John Darrington [Sat, 17 Dec 2011 07:31:03 +0000 (08:31 +0100)]
Output Viewer: Try to adapt to changes in style
Set the fg and bg of viewer's container and its children to the
text and base of the output window upon style change. This means that
the output viewer will respond to changes in style once even after the
program has been started.
We still need some way to set the foreground colours of the cairo output
after the driver has been created, but that doesn't seem to be currently
possible.
Ben Pfaff [Sun, 4 Dec 2011 18:44:07 +0000 (10:44 -0800)]
gui: Fix behavior of print preview in psppire-output-window.
Print preview only showed one page because the GtkPrintOperation emits
"paginate" again even after it returns TRUE once and our "paginate"
implementation was not prepared for that.
Also fixes a memory leak in paginate(): the driver used for pagination was
not being freed.
Reported-by: John Darrington <john@darrington.wattle.id.au>
John Darrington [Sat, 3 Dec 2011 12:06:32 +0000 (13:06 +0100)]
ONEWAY: Fixed crash when the dependent variable contained only missing values.
When forming a struct categoricals, there is no way in advance to know if the
given categorical variables will actually contain any values. If one or more
of them contains no non-missing values, then it's not meaningfull to talk
about categories.
Such cases were causing oneway to crash. Thanks to Dave Purdy
<David_Purdy@btinternet.com> for reporting this problem.
Ben Pfaff [Fri, 2 Dec 2011 06:06:48 +0000 (22:06 -0800)]
gui: Fix printing of tables split across pages in psppire-output-window.
xr_driver_output_item() expects the caller to call xr_driver_next_page()
as long as xr_driver_need_new_page() returns true, but the printing code
didn't do that, so tables split across pages in printouts caused an
assertion failure at the next call to xr_driver_output_item().
Reported-by: John Darrington <john@darrington.wattle.id.au>
John Darrington [Sat, 19 Nov 2011 18:33:03 +0000 (19:33 +0100)]
categoricals.c: Reimpliment the get_binary_by subscript function
Instead of making ad hoc encodings for interactions, use the product
of the encodings of the individual variables. This should not affect
the outcome of any current test cases, but makes the data flow easier
to follow and to debug.