Package org.newdawn.slick

Examples of org.newdawn.slick.TrueTypeFont


                hidden = false;
        }
       
        public static void loadTexture(){
                Font awtFont = new Font("Times New Roman", Font.BOLD, 24);
                font = new TrueTypeFont(awtFont, true);
        }
View Full Code Here


                hidden = false;
        }
       
        public static void loadTexture(){
                Font awtFont = new Font("Times New Roman", Font.BOLD, 24);
                font = new TrueTypeFont(awtFont, true);
        }
View Full Code Here

  }
 
 
  public static void loadTexture(){
        Font awtFont = new Font("Times New Roman", Font.BOLD, 24);
        font = new TrueTypeFont(awtFont, true);
  }
View Full Code Here

  public static void loadTexture(){
    try {
      gunPowder = TextureLoader.getTexture("PNG", ResourceLoader.getResourceAsStream("res/gunpowder.png"));
      diamond = TextureLoader.getTexture("PNG", ResourceLoader.getResourceAsStream("res/diamond.png"));
      Font awtFont = new Font("Times New Roman", Font.BOLD, 24);
      gpFont = new TrueTypeFont(awtFont, true);
      dFont = new TrueTypeFont(awtFont, true);
    } catch (IOException e) {
      e.printStackTrace();
    }
  }
View Full Code Here

   
   
    try {
      /*DOES NOT WORK YET!!!
       */
      m_trueTypeFont = new TrueTypeFont(java.awt.Font.createFont(java.awt.Font.TRUETYPE_FONT, new File(m_filepath+"res/fonts/PokeFont.ttf"))
          .deriveFont(java.awt.Font.PLAIN, 10), false);
      //m_trueTypeFont = m_fontSmall;
    } catch (Exception e) {e.printStackTrace(); m_trueTypeFont = m_fontSmall;}
    /*
     * Time/Weather Services
View Full Code Here

    this.engine = engine;
    try {
        InputStream inputStream = ResourceLoader.getResourceAsStream("Engine/Ubuntu-L.ttf");
        Font awtFont = Font.createFont(Font.TRUETYPE_FONT, inputStream);
        awtFont = awtFont.deriveFont(12f); // set font size
        font = new TrueTypeFont(awtFont, true);
      } catch (Exception e) {
        e.printStackTrace();
      }
   
  }
View Full Code Here

  public void init() {
    // turn off all but errors
    Log.setVerbose(false);

    java.awt.Font awtFont = new java.awt.Font("Times New Roman", java.awt.Font.BOLD, 16);
    font = new TrueTypeFont(awtFont, false);
   
    // texture load, the second argument is a name assigned to the texture to
    // allow for caching in the texture loader. The 3rd argument indicates whether
    // the image should be flipped on loading
    try {
View Full Code Here

  public void init() {
    // turn off all but errors
    Log.setVerbose(false);

    java.awt.Font awtFont = new java.awt.Font("Times New Roman", java.awt.Font.BOLD, 16);
    font = new TrueTypeFont(awtFont, false);
   
    // texture load, the second argument is a name assigned to the texture to
    // allow for caching in the texture loader. The 3rd argument indicates whether
    // the image should be flipped on loading
    try {
View Full Code Here

  /**
   * @see org.newdawn.slick.Game#init(org.newdawn.slick.GameContainer)
   */
  public void init(GameContainer container) throws SlickException {
    awtFont = new java.awt.Font("Verdana", Font.PLAIN, 16);
    font = new TrueTypeFont(awtFont, false);

    for (int j = 0; j < 2; j++) {
      int lineLen = 90;
      for (int i = 0; i < text.length(); i += lineLen) {
        if (i + lineLen > text.length()) {
View Full Code Here

TOP

Related Classes of org.newdawn.slick.TrueTypeFont

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.