From 0d0bd0c9669427f7cd43c3d34886bf22a146c451 Mon Sep 17 00:00:00 2001 From: John Darrington Date: Wed, 3 Apr 2013 09:20:13 +0200 Subject: [PATCH] Fixed bug displaying unicode box characters. Also added a test for this. Closes bug #38647 --- src/output/ascii.c | 1 + tests/output/ascii.at | 26 ++++++++++++++++++++++++++ 2 files changed, 27 insertions(+) diff --git a/src/output/ascii.c b/src/output/ascii.c index 756235c5cb..bc1b225a40 100644 --- a/src/output/ascii.c +++ b/src/output/ascii.c @@ -120,6 +120,7 @@ static const ucs4_t unicode_box_chars[N_BOX] = 0x2564, 0x256a, 0x256c, 0x2564, 0x256a, 0x256c, 0x2554, 0x2560, 0x2560, + 0x2560, 0x256c, 0x256c, 0x2566, 0x256c, 0x256c, }; diff --git a/tests/output/ascii.at b/tests/output/ascii.at index a3f66b933b..b4de68808e 100644 --- a/tests/output/ascii.at +++ b/tests/output/ascii.at @@ -627,3 +627,29 @@ included in the variable list. ]) AT_CLEANUP + +AT_SETUP([ASCII unicode box chars]) + +AT_DATA([uc.sps], [dnl +SET FORMAT=F8.4. +DATA LIST NOTABLE LIST /x * . +BEGIN DATA. +1 +2 +3 +END DATA. + +DESCRIPTIVES X. +]) + + +AT_CHECK([pspp -O box=unicode uc.sps], [0], [dnl +Valid cases = 3; cases with missing value(s) = 0. +╭────────╥─┬──────┬───────┬───────┬───────╮ +│Variable║N│ Mean │Std Dev│Minimum│Maximum│ +╞════════╬═╪══════╪═══════╪═══════╪═══════╡ +│x ║3│2.0000│ 1.0000│ 1.0000│ 3.0000│ +╰────────╨─┴──────┴───────┴───────┴───────╯ +]) + +AT_CLEANUP -- 2.30.2