This is another special case. It seems like the sliding connectors have many special cases. I thought that there were three but now, with this one, there are four.
The good news is that I have the two more normal cases working. They are the cases where there is one sliding connector and it becomes fixed in its position and the connected link needs to move or it is free to move and its connected link is fixed in position. The code for these cases is not as simple as I hoped but I have lots of library code to handle circle-line intersections, offset and rotation of links in a single operations, etc….
This special case will require the detection of the two fixed links. This is very different from the other remaining case where two sliding connectors are not fixed but still have a similar effect. I need to start rethinking all of this to see if there is a way to handle these things without the special cases. At a minimum, I should try to combine the code for regular connectors and sliding connectors in cases where the code is mostly the same.
I’ll make the program available when there is need for it or when I get all of the remaining special cases handled. Did I mention that there is also a special case for non-sliding connectors that is also not handled? It’s the case where more than one but less than all connectors for a link get moved into new locations that are valid. Two links connected to each other with more than one connector is just not handled now.
At least I’ve made progress but it seems more like a project of finding special cases and handling all of them. Just wait until I add gears!