Nez.Portable/Utils/Fonts/BatcherBitmapFontExt.cs
/// <summary>
/// Submit a text string of sprites for drawing in the current batch.
/// </summary>
/// <param name="spriteFont">A font.</param>
/// <param name="text">The text which will be drawn.</param>
/// <param name="position">The drawing location on screen.</param>
/// <param name="color">A color mask.</param>
/// <param name="rotation">A rotation of this string.</param>
/// <param name="origin">Center of the rotation. 0,0 by default.</param>
/// <param name="scale">A scaling of this string.</param>
/// <param name="effects">Modificators for drawing. Can be combined.</param>
/// <param name="layerDepth">A depth of the layer of this string.</param>
Submit a text string of sprites for drawing in the current batch.
Submit a text string of sprites for drawing in the current batch .
public static void drawString(
            this Batcher batcher,
            BitmapFont bitmapFont,
            StringBuilder text,
            Vector2 position,
            Color color,
            float rotation,
            Vector2 origin,
            float scale,
            SpriteEffects effects,
            float layerDepth)
        {
            var scaleVec = new Vector2(scale, scale);
            var source = new FontCharacterSource(text);
            bitmapFont.drawInto(batcher, ref source, position, color, rotation, origin, scaleVec, effects, layerDepth);
        }
public static void drawString ( this Batcher batcher , BitmapFont bitmapFont , StringBuilder text , Vector2 position , Color color , float rotation , Vector2 origin , float scale , SpriteEffects effects , float layerDepth ) { var scaleVec = new Vector2 ( scale , scale ) ; var source = new FontCharacterSource ( text ) ; bitmapFont . drawInto ( batcher , ref source , position , color , rotation , origin , scaleVec , effects , layerDepth ) ; }
Submit a text string of sprites for drawing in the current batch.
Submit a text string of sprites for drawing in the current batch .
Batcher
this
bitmapFont
BitmapFont
text
StringBuilder
The text which will be drawn.
The text which will be drawn .
position
Vector2
The drawing location on screen.
The drawing location on screen .
color
Color
A color mask.
A color mask .
rotation
float
A rotation of this string.
A rotation of this string .
origin
Vector2
Center of the rotation. 0,0 by default.
Center of the rotation . 0 0 by default .
scale
float
A scaling of this string.
A scaling of this string .
effects
SpriteEffects
Modificators for drawing. Can be combined.
Modificators for drawing . Can be combined .
layerDepth
float
A depth of the layer of this string.
A depth of the layer of this string .
spriteFont
None