Esempio n. 1
0
 // Clear the ImGui-side font data (glyphs storage, UV coordinates)
 void ClearFonts()
 {
     //for (int i = 0; i < Fonts.Size; i++)
     //{
     //    Fonts[i]->~ImFont();
     //    ImGui::MemFree(Fonts[i]);
     //}
     Fonts.clear();
 }
Esempio n. 2
0
        // Clear the input TTF data (inc sizes, glyph ranges)
        void ClearInputData()
        {
            for (int i = 0; i < ConfigData.Size; i++)
            {
                if (ConfigData[i].FontData != null && ConfigData[i].FontDataOwnedByAtlas)
                {
                    //ImGui::MemFree(ConfigData[i].FontData);
                    ConfigData[i].FontData = null;
                }
            }

            // When clearing this we lose access to the font name and other information used to build the font.
            for (int i = 0; i < Fonts.Size; i++)
            {
                if (Fonts[i].ConfigData.FontData == null)
                {
                    Fonts[i].ConfigData      = null;
                    Fonts[i].ConfigDataCount = 0;
                }
            }
            ConfigData.clear();
        }
Esempio n. 3
0
 internal void Clear()
 {
     Data.clear();
 }