Prevent point type changes when dragging splines

Issue #44 resolved
Georg Mayr-Duffner created an issue

This is currently being worked on in FF. It would be fine to have smed behave the same way.

See reports at https://github.com/fontforge/fontforge/issues/533 https://github.com/fontforge/fontforge/issues/688

Comments (12)

  1. Barry Schwartz

    I think what’s really wanted here is a Hobby’s algorithms interface, but that is a very long way off.

  2. Barry Schwartz

    Like Metafont, but hopefully with a graphical interface of some kind. A different way to represent cubic splines. Elements would include: on-curve points with directions or control points (on one or both sides), off-curve points without directions or control points (on one or both sides), and spline tensions.

    One thing I do not want to do is go with every behavioral change Dave or someone else suggests. These will upset any user used to the current behavior (usually me) and sometimes may also indicate that the user is not really thinking in terms of the underlying model. That’s one reason why I am also interested in an interface where you work with the control polygons of the splines, which are a mathematically convenient construct often used in computations. I think people should learn to think in terms of splines rather than ‘points’. The ‘point types’ do not actually exist in the font; they are there purely to fit one particular user interface that George happened to like.

    I am used to the interface. I may not like it entirely, but am used to it. That is one reason for the fork. We restored the old layers palette because we preferred it, for instance, and it was stable, reliable. Increasingly we are going to be the actual FontForge, when it comes to the basic graphical user interface (though we are very interesting in reimplementing that in GTK-2 or something).

  3. Barry Schwartz

    @georgd Actually, now that I think about it, I think dragging the curve at all is a bogus operation introduced to make up for the fact that only the on-curve points of the control polygons are being displayed. What’s really wanted is the ability to adjust the off-curve control points, while locking them to particular line of motion, and that sort of thing. It is bogus that off curve points are treated as appendages to on-curve points; they are full-fledged vertices of the control polygon, and the control polygon is what we should be dragging on.

    Still, this kind of playing around with interfaces isn’t a high priority until we get the code in better shape. Some of the ‘technical debt’ we inherited from FontForge is now equaled by my own screw-ups (i.e., valuable learning experiences), but contrary to the FontForge way I intend to fix them before proceeding.

    cc @khaledhosny

  4. Barry Schwartz

    @georgd The dashed line is the control polygon in the example diagram at top, and the gray lines in the animations: http://en.wikipedia.org/wiki/B%C3%A9zier_curve

    The ‘Adobe Illustrator’ example shows the way FF/Smed treat the problem, which you can see is not as natural; in the animations you can see that the entire polygon plays some role in the mathematical construction of the spline. Those polygon vertices and edges are what should be dragged on.

    Think about it. You should be able to select any number of control points, both on and off curve, and drag them around, rotate them as a group, etc. Much easier to do interesting things than with the ‘handles’ interface.

    I think if we are going to change the current interface it shouldn’t be whittling little things the way Dave suggests, to make the ‘handles’ interface less unpalatable, but changing it to a full-fledged control polygon interface.

    @khaledhosny

  5. Georg Mayr-Duffner reporter

    Thinking more of it, I have to confess that my problem with the dragging of splines lies somewhere else. I usually manipulate only control points and I think, I could count my dragging of splines themselves with the fingers of my hands (and there were cases where the suggested behaviour was needed). Usually I drag splines by accident when indeed I want to mark several points and aim badly (some tweaking there could be helpful, like visual feedback if one is about to touch a point or a spline, on the other hand it’s often difficult to click on an anchor mark or a point when one wants to). The requested behaviour would be nice to have as an alternative but without changing the default—and I’m sure I won’t need it soon.

    But your answers bring up other questions:

    All in all, I think, it would be great if the polygon was drawn and one could manipulate the points by dragging its edges.

  6. Khaled Hosny

    I defer the dicision here to @chemoelectric, he knows a lot better that me about all that spline stuff. Personally I’m used with the interface as it is now; I learned editing vector splines on FontForge, and find other applications (e.g. Inkscape) confusing to use.

  7. Barry Schwartz

    @georgd Dragging a spline should really probably just select its control polygon and move it as a whole, if you ask me. Currently you have to select the endpoints and move one of those. But I, personally, don’t want things changed through patch after patch. It should be revised as an integrated whole, after a lot of thought.

    I do think about these things a lot. I’m the kind who thinks about how to do a 5-minute activity for 5 years before doing it. ;)

  8. Barry Schwartz

    To be honest, I want the UI to be programmable at least partly in Guile before changing it much.

  9. Georg Mayr-Duffner reporter

    In the meantime I’ve come to think that the new behaviour of FF is more harmful than useful so I’d suggest to close this request.

    However, the other ideas sketched here to improve spline manipulation are interesting and could be worth some thought, when the program is consolidated enough to allow for such changes.

  10. Log in to comment