On 09/09/2013 11:28 AM, Tavmjong Bah wrote:
On Sun, 2013-09-08 at 22:47 +0200, Sebastian Götte wrote:
Hi,
I made the code more useable and fixed some selection issues. Also, points can now be in groups. A point is added to a group by selecting the group (and nothing else) and shift-clicking to create the point. I am working on a UI to add one or more existing points to a group. Undo/redo does not yet work properly together with the connector context, I had one crash and the point handles do not yet get updated when undoing/redoing. I am working on this.
Looks good! It is fun to move groups around and have the connectors update.
You should try rotating groups containing points...
I am slightly concerned about the performance of this "live updating" approach, especially in more complex scenarios including libavoid routing. The old code just updated the connectors after all changes have been made, but the live update looks so nice... Fortunately, I am the proud owner of a very slow laptop, so I can test this rather well.
We are getting close to the end of GSOC so we need to decide what needs to be done in the time remaining. The things I think are most important are:
- The code should at least be able to do everything the previous code
did (except direct connecting to objects).
With respect to this, next on are libavoid attributes and refs on random objects.
The UI needs to be documented.
Bugs squashed.
I think (1) is almost there. For (2), I realize the UI is a work-in-progress but it needs to be documented so people can test it. Also the Status Bar messages need to be update.
I started adding some status bar messages. If I am not entirely mistaken, the proper place for UI documentation should be the "inkscape-docs" repository on launchpad [0].
Here are some specific problems:
- With connector-tool, changing selection doesn't change which points
are highlighted. If I select an object, the object (group's) points should be highlighted; if I select a connector, the connector's endpoints should be highlighted.
Ok, I now coupled object and point selection. Points/items can still be selected individually, but when the selection of an item is changed, the selection of all contained points is changed as well. When the selection of a connector is changed, the selection of the connector's endpoints is changed. The only quirk of this approac is that when two connectors share an endpoint and one is selected and [Delete] is pressed, the other connector is deleted as well since at the point [Delete] is pressed the selection contains both the one connector and both of its endpoints, including the shared one and when the shared endpoint is deleted, the other connector is deleted. I think that's not too much of a problem, though.
- Cursor image isn't updated correctly
Fixed. I forgot to chain the ConnectorContext's setup function with the EventContext's, where the cursor is set.
On 09/09/2013 11:41 AM, Tavmjong Bah wrote:> On Sun, 2013-09-08 at 22:47 +0200, Sebastian Götte wrote:
Hi,
I made the code more useable and fixed some selection issues. Also, points can now be in groups. A point is added to a group by selecting the group (and nothing else) and shift-clicking to create the point. I am working on a UI to add one or more existing points to a group. Undo/redo does not yet work properly together with the connector context, I had one crash and the point handles do not yet get updated when undoing/redoing. I am working on this.
Hit the Send button too quick...
Here are two files:
- Patch file for Connector Toolbar icons (modifies icons.svg,
connectors-toolbar.cpp).
Thanks, I just merged it and fixed the toolbar code.
- Test file for a connector connecting grouped points.
I just tried to open this file and play around with it a bit, to me it seems to work now.
I still have one spurious segfault left that sometimes occurs when deleting an SPPoint. The next time I trigger it I will look into this one. The current code can be found on launchpad [1].
Sebastian
[0] https://launchpad.net/inkscape-docs [1] https://code.launchpad.net/~h-e-6/inkscape/connector-wip