Follow-up to engraving punctuation
Skip the terminal period only if there is true punctuation at the end of the engraving, not degraded text. This feels a bit janky because the way engravings are malloced and structured uses this manual offset to access the space allocated for text. I used a macro to unify all those accesses so that it will be harder to screw it up if something changes in that respect, since repeating (ep + 1) as a magic number across engrave.c seems quite brittle.
This commit is contained in:
@@ -13,6 +13,8 @@ enum engraving_texts {
|
||||
text_states
|
||||
};
|
||||
|
||||
#define engr_text_space(ep) ((char *) ((ep) + 1))
|
||||
|
||||
struct engr {
|
||||
struct engr *nxt_engr;
|
||||
char *engr_txt[text_states];
|
||||
|
||||
Reference in New Issue
Block a user