fontforge/fontforge — pull request #124 by monkeyiq (2012-09-24 13:57:52+00:00)
Title: v2: Lets make the point info window not a modal one.

This is a rebased version of https://github.com/fontforge/fontforge/pull/35

I have some little updates too for handling close by window decoration and a fix for a subtle bug in dlist_erase(). Did some testing again using 3-4 dialogs, close some, close charview to close all others. Also moving the base point around and seeing it reflected in the corresponding dialog.

If you have many of these open they track their respective point in
the charview if that point is moved. If the charview is closed then
all the point info dialogs are closed too.

dlistnode is the start of a generic double linked list abstraction. Note that the foreach for dlists is defensive in that it allows the callback function to unlink a node and will continue on working. See for example the line in the patch which passes PI_Destroy to the foreach to cleanup the existing dialogs when a charview is closed. A fairly to the point single line of code ;)

The advantages over single linked lists are quite a few, a major one is being able to simply remove any element. No more tracking "prev" explicitly in a loop so current can be skipped if desired.