No es compatible, pero como un truco, puede recorrer todas las letras de la cadena e insertar un espacio en blanco entre cada una. Puede crear una función simple para él como tal:
Editar - He vuelto a hacer esto en Visual Studio y probado - los errores se han eliminado.
private string SpacedString(string myOldString)
{
System.Text.StringBuilder newStringBuilder = new System.Text.StringBuilder("");
foreach (char c in myOldString.ToCharArray())
{
newStringBuilder.Append(c.ToString() + ' ');
}
string MyNewString = "";
if (newStringBuilder.Length > 0)
{
// remember to trim off the last inserted space
MyNewString = newStringBuilder.ToString().Substring(0, newStringBuilder.Length - 1);
}
// no else needed if the StringBuilder's length is <= 0... The resultant string would just be "", which is what it was intitialized to when declared.
return MyNewString;
}
Luego, su línea de código anterior solo se modificaría como:
g.DrawString(SpacedString("MyString"), new Font("Courier", 44, GraphicsUnit.Pixel), Brushes.Black, new PointF(262, 638));
pude simplemente dibujar cada letra individual. – beckelmw
+1. Aunque no es agradable de escuchar, aprecio cuando alguien sale y te dice que algo no es compatible. – jp2code