reymond-group/smilesDrawer

Triple bonds are bent near rings

Opened this issue · 2 comments

There's a rendering inconsistency where triple bonds that appear before a ring in the input SMILES are drawn bent relative to the preceding bond, whereas triple bonds appearing after a ring are (correctly, I believe) shown as colinear. For example (the nitrogen doesn't affect things - it's simply to distinguish the branches):

C#Cc1ccccn1C#C
Screen Shot 2024-05-07 at 11 31 14 AM

Playing around with this a little further, I think the straightness check is off by one atom. Adding a couple more carbons to the previous example shows that the junction after the triple bond junction is drawn as straight when it shouldn't be:

CCC#Cc1ccccn1C#CCC
Screen Shot 2024-05-07 at 11 31 19 AM

The "lightning bolt" pattern after the triple bond in my second example appears to be a separate (but maybe related?) issue: #82.

And my report here is a duplicate of #39...