partridgejiang / Kekule.js

A Javascript cheminformatics toolkit.
http://partridgejiang.github.io/Kekule.js
MIT License
250 stars 61 forks source link

ElectronPushingArrow Aesthetics - Feature Request #142

Open cleblond opened 5 years ago

cleblond commented 5 years ago

I'm wondering if it's easily possible to make the electronpushingarrows prettier?

1) The default color of a ElectronPushingArrow could be different from the other arrows. Of course I could probably achieve this with renderconfigs.

2) Smarter arrows with another inflection in them so they look more like they are hand drawn "curly" arrows (maybe bezier curves instead of an arc).

Here are the arrows from another popular editor cd_screenshot

Here are the Kekule arrows. Notice how its difficult to see that the arrow starts at the cyanide C atom. k_screenshot

partridgejiang commented 5 years ago

Hi @cleblond, thanks for the suggestion. Bezier curve may be implemented in the future, but perhaps not recently, since it requires some additional mechanisms of current editor:

To avoid the overlap of arrow and C atom as shown in your figure2, a workaround can be used currently. Just select the arrow first, then a control point can be seen at the middle of the arc as shown in the first figure below. Move the control point to a suitable position, the starting point of the arrow should be clear as shown in the second figure below.

image image

cleblond commented 4 years ago

Thanks for your comments. Yes I realized the arrows could be reshaped. I'm not to worried about being able to reshape with control points, was hoping they would just look a little more "clean" and freehand like.