Example #1
0
        public void addTextCenteredHorizontal(int xPos, int yPos, string text, Color color, BasicFonts font = BasicFonts.CG_14_REGULAR)
        {
            BasicText textToAdd = new BasicText(xPos, yPos, getSpriteFont(font), text, Color.White, StringAlignment.CENTER);

            componentsOnScreen.Add(textToAdd);
            textLabelsOnScreen.Add(textToAdd);
        }
Example #2
0
        public void addText(int xPos, int yPos, string text, Color color, BasicFonts font = BasicFonts.CG_14_REGULAR)
        {
            BasicText textToAdd = new BasicText(xPos, yPos, getSpriteFont(font), text, color);

            componentsOnScreen.Add(textToAdd);
            textLabelsOnScreen.Add(textToAdd);
        }
Example #3
0
        public void addTextCenteredVertical(int xPos, string text, Color color)
        {
            BasicText textToAdd = new BasicText(xPos, GameConfig.APP_HEIGHT/2, buttonFontStyle1, text, Color.White);

            componentsOnScreen.Add(textToAdd);
            textLabelsOnScreen.Add(textToAdd);
        }
Example #4
0
        public void addTextCenteredOnScreen(string text, Color color)
        {
            BasicText textToAdd = new BasicText(GameConfig.APP_WIDTH/2, GameConfig.APP_HEIGHT / 2, buttonFontStyle1, text, Color.White, StringAlignment.CENTER);

            componentsOnScreen.Add(textToAdd);
            textLabelsOnScreen.Add(textToAdd);
        }