#region --- License ---
/* Copyright (c) 2006, 2007 Stefanos Apostolopoulos
* See license.txt for license info
*/
#endregion
using System;
using System.Collections.Generic;
using System.Text;
namespace OpenTK.Fonts
{
///
/// Represents a handle to cached text.
///
public class TextHandle : IDisposable
{
internal TextHandle(int handle)
{
Handle = handle;
}
///
/// The handle of the cached text. Call the OpenTK.Fonts.ITextPrinter.Draw() method
/// to draw the text represented by this TextHandle.
///
public readonly int Handle;
internal TextureFont font;
protected bool disposed;
#region public override string ToString()
///
/// Returns a System.String that represents the current TextHandle.
///
/// a System.String that descibes the current TextHandle.
public override string ToString()
{
return String.Format("TextHandle: {0}", Handle);
}
#endregion
#region --- IDisposable Members ---
public void Dispose()
{
this.Dispose(true);
GC.SuppressFinalize(this);
}
protected virtual void Dispose(bool manual) { }
~TextHandle() { this.Dispose(false); }
#endregion
}
}