Dispose() public method

public Dispose ( ) : void
return void
Beispiel #1
0
        /// <summary>
        /// Reloads the font using the original loader/builder options. This may be useful if the underlying
        /// files change, or, more commonly, if the "TransformToCurrentOrthogProjection" option was used when
        /// creating the font, and the orthog projection has since changed (e.g. resizing the window). This
        /// will do nothing for fonts created directly from a Font object.
        /// </summary>
        public void Reload()
        {
            switch (fontLoadDescription.Method)
            {
            case FontLoadMethod.QFontFile:
            {
                fontData.Dispose();         //dispose old data
                LoadQFontFromQFontFile(fontLoadDescription);
                break;
            }

            case FontLoadMethod.FontFile:
            {
                fontData.Dispose();         //dispose old data
                LoadQFontFromFontFile(fontLoadDescription);
                break;
            }
            }
        }