Valgrind helped to spot one issue with the Hash-Function and ownership of the FontPlatformData.
Created attachment 15328 [details] Improve Gdk Font Handling -Fix various uninitialized variables -Make the FontPlatformData::hash method at least a more reliable (I don't know if this will make a good source for the hash...) -Move destroying of FontPlatformData resources to FontData::platformDestroy
Comment on attachment 15328 [details] Improve Gdk Font Handling Ask for review
This patch helps solve some real issues. Can I suggest C++ style casts? Also + * this create a deep copy should be + * this creates a deep copy
(In reply to comment #3) > This patch helps solve some real issues. Can I suggest C++ style casts? Also > > + * this create a deep copy > > should be > > + * this creates a deep copy > No this comment should be removed. This is from making FontPlatformData copyable by implementing copy c'tor and assignment operator. I will update the patch
Created attachment 15353 [details] Improve Gdk Font Handling -Remove the bogus comment -Use c++ casts instead of c-casts as wished by alp.
Comment on attachment 15353 [details] Improve Gdk Font Handling >+ to FontData::platformDestroy. The ownership of these objects is hold by Is held by. >+ Replace c-casts with c++ casts, in this case reinterpret_cast. >+ >+ >+ >+ >+ * platform/gdk/FontDataGdk.cpp: I wouldn't do so many empty lines, but that is a style thing. Code looks fine.
Landed in r24017.