Skip to content

Commit ad31a76

Browse files
committed
Implement ­ support (Issue #361)
1 parent d2ce0f3 commit ad31a76

File tree

6 files changed

+22
-2
lines changed

6 files changed

+22
-2
lines changed

CHANGES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
- Optimized the loading of font widths (Issue #354)
1515
- Optimized PDF page resources (Issue #356)
1616
- Optimized the base memory used for font widths (Issue #357)
17+
- Added proper `­` support (Issue #361)
1718
- Title files can now be markdown.
1819

1920

htmldoc/html.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*
22
* HTML parsing definitions for HTMLDOC, a HTML document processing program.
33
*
4-
* Copyright 2011 by Michael R Sweet.
4+
* Copyright 2011-2019 by Michael R Sweet.
55
* Copyright 1997-2010 by Easy Software Products. All rights reserved.
66
*
77
* This program is free software. Distribution and use rights are outlined in

htmldoc/htmllib.cxx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -868,6 +868,9 @@ htmlReadFile(tree_t *parent, // I - Parent tree entry
868868
*ptr++ = (uchar)ch;
869869
}
870870

871+
if ((_htmlUTF8 && ch == _htmlCharacters[173]) || (!_htmlUTF8 && ch == 173))
872+
break;
873+
871874
ch = getc(fp);
872875
}
873876

htmldoc/ps-pdf.cxx

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4957,7 +4957,19 @@ parse_paragraph(tree_t *t, /* I - Tree to parse */
49574957

49584958
if ((temp_width >= format_width && prev->markup == MARKUP_IMG) ||
49594959
prev->markup == MARKUP_BR)
4960+
{
49604961
break;
4962+
}
4963+
else if (prev->markup == MARKUP_NONE)
4964+
{
4965+
int ch = prev->data[strlen((char *)prev->data) - 1];
4966+
4967+
if (_htmlUTF8)
4968+
ch = _htmlUnicode[ch];
4969+
4970+
if (ch == 173)
4971+
break;
4972+
}
49614973
}
49624974

49634975
if ((width + temp_width) <= format_width)

htmldoc/testhtml.cxx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,8 @@ main(int argc, /* I - Number of command-line arguments */
122122
printf("MARKUP_WBR=%d\n", MARKUP_WBR);
123123
#endif /* DEBUG */
124124

125+
_htmlData = "..";
126+
125127
if (argc < 2)
126128
{
127129
fputs("Usage: testhtml [--tree] filename.html\n", stderr);

xcode/htmldoc.xcodeproj/project.pbxproj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -948,7 +948,7 @@
948948
08FB7793FE84155DC02AAC07 /* Project object */ = {
949949
isa = PBXProject;
950950
attributes = {
951-
LastUpgradeCheck = 1020;
951+
LastUpgradeCheck = 1100;
952952
TargetAttributes = {
953953
8DD76F620486A84900D96B5E = {
954954
DevelopmentTeam = RU58A2256H;
@@ -1120,6 +1120,7 @@
11201120
CODE_SIGN_IDENTITY = "Mac Developer";
11211121
COPY_PHASE_STRIP = NO;
11221122
DEVELOPMENT_TEAM = RU58A2256H;
1123+
ENABLE_HARDENED_RUNTIME = YES;
11231124
GCC_DYNAMIC_NO_PIC = NO;
11241125
GCC_MODEL_TUNING = G5;
11251126
GCC_OPTIMIZATION_LEVEL = 0;
@@ -1138,6 +1139,7 @@
11381139
CODE_SIGN_IDENTITY = "Mac Developer";
11391140
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
11401141
DEVELOPMENT_TEAM = RU58A2256H;
1142+
ENABLE_HARDENED_RUNTIME = YES;
11411143
GCC_MODEL_TUNING = G5;
11421144
INSTALL_PATH = /usr/local/bin;
11431145
PRODUCT_NAME = htmldoc;

0 commit comments

Comments
 (0)