I've added a list of strings that should go along with the GpFontCollection, this list are the temporary files created by the GdipPrivateAddMemoryFont function.
When Dispose is called by C# code, GdipDeletePrivateFontCollection should go through the list and removes all temp files created.
There are ways to get files associated with an FcConfig, however, it will be hard to distinguish between files added using GdipPrivateAddMemoryFont or files managed by the user added through GdipPrivateAddFontFile, so I guess keeping a list of strings for later deletion is still a good solution.
This should fix #690.
I've added a list of strings that should go along with the
GpFontCollection
, this list are the temporary files created by theGdipPrivateAddMemoryFont
function.When
Dispose
is called by C# code,GdipDeletePrivateFontCollection
should go through the list andremove
s all temp files created.There are ways to get files associated with an
FcConfig
, however, it will be hard to distinguish between files added usingGdipPrivateAddMemoryFont
or files managed by the user added throughGdipPrivateAddFontFile
, so I guess keeping a list of strings for later deletion is still a good solution.