void AllocFont() { if (_asset == null) _asset = new TextBuffer(GetFontFamilyOrInherited(), GetFontSizeOrInherited()) {Text = _resourceString}; }
public override void Deallocate() { base.Deallocate(); if (_asset != null) { _asset.Dispose(); _asset = null; } }
void AllocFont() { if (_asset == null) { // We want to select the font based on the maximum zoom height (fullscreen) // This means that the font will be scaled down in windowed mode, but look // good in full screen. _asset = new TextBuffer(GetFontFamilyOrInherited(), GetFontSizeOrInherited()) { Text = VisibleText }; } }