Skip to content

Commit c2e9860

Browse files
author
Johan Sarge
committed
Making a few requested changes to the PR.
Signed-off-by: Johan Sarge <rabiteman_2000@yahoo.com>
1 parent 51b83d0 commit c2e9860

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

ChangeLog

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
master/HEAD
2-
- Extended Unicode support in Composite, character display width now taken
3-
into account
2+
- #117 Extended Unicode support in Composite, character display width now taken into account
43
(thanks to Johan Sarge)
54
- #111 Duration: support negative durations by prefixing a '-' before the P in ISO format
65
(thanks to Andrew Poelstra)

src/Composite.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@
2525
////////////////////////////////////////////////////////////////////////////////
2626

2727
#include <Composite.h>
28+
#include <format.h>
2829
#include <limits>
2930
#include <sstream>
30-
//#include <stack>
3131
#include <utf8.h>
3232

3333

@@ -240,8 +240,7 @@ std::string Composite::str () const
240240
column_count += 2;
241241
break;
242242
default: // Should not happen.
243-
// ISSUE: Report character width error?
244-
return std::string (); // Fail.
243+
throw format ("Unexpected character width {1} of code point 0x{2}.", ch_width, formatHex (character));
245244
}
246245

247246
// Remember byte offset of first UTF-8 byte of next character in the layer text.

0 commit comments

Comments
 (0)