When charts are copied to the clipboard, then also text formats
were advertised. This patch restricts the advertised clipboard
formats such that applications choose the correct format.
See: https://savannah.gnu.org/bugs/?65288
The preferred format for charts/images is svg or some image format
For tables no image format is advertised such that John can paste
html as editable table in libreoffice.
The previous commit to fix the "make install" problem in shells which
have a locale setting different from "US" did not work for Bernd on
archlinux. Thanks for reporting the problem!
Ben Pfaff [Sun, 7 Jan 2024 19:09:07 +0000 (11:09 -0800)]
tests: Remove two tests that proved problematic cross-OS and cross-arch.
The test "journal enabled by default interactively" failed in Debian
testing on s390x, powerpc, and ppc64. I can't reproduce the problem on
x86_64. This commit removes it.
The test "interactive output appears immediately" failed in Debian testing
on s390x, hppa, powerpc, and ppc64. It also previously failed on Mac OS.
I can reproduce the problem on x86_64 if readline isn't available, but not
if it is. (I think it would always be available for Debian). This commit
removes it.
Thanks to Friedrich Beckmann for reporting the Debian build problems.
The build process fails if the shell has set a different language
setting the us. This patch sets the language during the generation
of the documentation images.
Ben Pfaff [Sun, 5 Nov 2023 19:12:18 +0000 (11:12 -0800)]
Revert "Revert "MacOS: skip test "convert invalid UTF-8 to ISO-8859-1"""
This reverts commit bcc19d9457129559b836a0cc6cd81e2c71d42bb5.
Just letting Mac OS crash on invalid conversions seems like the
most reasonable path for now. Maybe Apple will fix their buggy
iconv.
Ben Pfaff [Sun, 5 Nov 2023 19:11:41 +0000 (11:11 -0800)]
Revert "i18n.c: added EOPNOTSUPP error code for MacOS"
This reverts commit 1799abc8539bd1a49c72c5723d1fa89ff4463e3f.
Handling EOPNOTSUPP like EILSEQ produced a hang rather than
the expected results, so this was a failed experiment.
With MacOS 14 the iconv library was changed by Apple. pspp uses
the native iconv library. There is a different error code
returned when an illegal 0xc0 UTF-8 code is converted. This
results in a failed "convert invalid UTF-8 to ISO-8859-1" test in
the regression. This patch now handles also EOPNOTSUPP.
MacOS: skip test "convert invalid UTF-8 to ISO-8859-1"
Starting with MacOS 14 Sonoma Apple has changed the behaviour
of the iconv library. The test tests the behaviour for invalid
UTF-8 sequence 0xC0. The native Apple iconv library responds with
a different error number than expected. This patch skips the
test on MacOS until this is hopefully fixed on MacOS.
Ben Pfaff [Thu, 2 Nov 2023 01:41:57 +0000 (18:41 -0700)]
tests: Try another strategy to check for immediate output.
The previous strategy hung on some machines and failed on others. The
failures are sometimes sensitive to whether libreadline is available. I
hope that this avoids the problem.
Ben Pfaff [Wed, 1 Nov 2023 16:40:02 +0000 (09:40 -0700)]
tests: Stop using squish-pty.
squish-pty seems to break easily, so switch to using another way to
simulate interactive behavior. This way requires a small source code
change to PSPP itself but it should be more portable.
Thanks to Friedrich Beckmann for reporting the problem. The problem that
Friedrich reported was a hang in the "interactive output appears
immediately" test on Debian sid. I couldn't reproduce that problem on
Fedora or Debian testing, but I did get failures on Debian testing. I
guess it's best to just avoid ptys at all.
Ben Pfaff [Sat, 30 Sep 2023 20:19:21 +0000 (13:19 -0700)]
MATCH FILES: Fix crash in string variable resizing.
Commmit 638bf380e550 ("combine-files: Allow matching string
variables to have different widths.") introduced a bug in the
case where the variables in data files being combined didn't
have the same variable order. This is kind of an
embarrassing bug since the input files having the same order
of variables is an exceptional case anyhow. This commit
should fix the problem.
The test as updated will crash if the bug regresses.
Ben Pfaff [Sat, 24 Jun 2023 17:04:48 +0000 (10:04 -0700)]
html: Include generic font-family name "sans-serif" as a fallback.
https://developer.mozilla.org/en-US/docs/Web/CSS/font-family recommends
that a font-family specification should always include one of the generic
font-family names to serve as a fallback. For PSPP, sans-serif is a
reasonable fixed fallback.
This addresses bug #63020, which asks for "Sans Serif" to mean sans-serif.
It obviously doesn't generalize to other font name translations, but it
does address the case that the bug filer complained about. If we need a
more general mechanism, we can invent it later.
Thanks to Frans Houweling for reporting this issue.
John Darrington [Fri, 23 Jun 2023 12:22:51 +0000 (14:22 +0200)]
Remove Find and Close from the list of default button box buttons
Commit e1a2cf577fac791c79cd531e688a48efab9b7c0c inappropiratly added the FIND
and CLOSE buttons to the default list of buttons to be shown. This change
fixes that error.
John Darrington [Tue, 20 Jun 2023 20:11:51 +0000 (22:11 +0200)]
Change TAB characters to spaces
Most of our code is indented with four spaces. However some files had been
using tabs. Some code used both tabs and spaces in the same file!. This
change replaces all tabs with eight spaces.
John Darrington [Tue, 20 Jun 2023 16:42:24 +0000 (18:42 +0200)]
Added a new dialog to generate CTABLES
This dialog provides just a small subset of what ought to be available. In
particular, nested tables cannot be specified and only the default summary
functions work. Other caveats are also present, but it generally provides
a start and proof of concept.
John Darrington [Mon, 19 Jun 2023 18:25:59 +0000 (20:25 +0200)]
Add a callback from PsppireDialog on GtkDrawingArea draw signals.
If a PsppireDialog contains a GtkDrawingArea, potentially any change
to the drawn surface could indicate a change in state. Therefore,
we need to notify interested parties of this change.
John Darrington [Sun, 18 Jun 2023 11:07:45 +0000 (13:07 +0200)]
Revert recent changes to configure.ac
Commit e1a2cf577fac791c79cd531e688a48efab9b7c0c recented gtksourceview to
version 4.8 - However this turned out to be unnecessary, so this change
reverts that detail.
John Darrington [Fri, 16 Jun 2023 15:14:41 +0000 (17:14 +0200)]
Re-implemented the search dialog for the syntax editor
This new dialog offers a lot more features, such as case insensitivity,
backward searching etc. This change also removes the option to build
against gtksourceview-3 - gtksourceview-4 is now required.
Ben Pfaff [Sun, 4 Jun 2023 14:52:11 +0000 (07:52 -0700)]
lexer: New function for other kind of half-open range.
The existing function lex_force_num_range_halfopen() handled ranges of the
form [low,high). There is a new need for (low,high] ranges. This commit
adds that new function and renames the existing one so that it's obvious
which kind it handles.
John Darrington [Sat, 3 Jun 2023 20:01:12 +0000 (22:01 +0200)]
MEANS: Allow string variables to be selected as the categorical variable.
The gui did not allow string variables to be the subject of any MEANS command.
However it is entirely appropriate for them to be the independent (categorical)
variable.