public MenuItemString( Vector position, Vector size, Font2DSettings font_settings, String entry, TextureManager tex_manager) { super(position, size); m_item_font = new Font2D(tex_manager, m_size, font_settings, (int) (m_size.y * 0.5f)); m_item_font.setString(entry); m_position_data = new VertexBufferFloat(VertexBufferFloat.sprite_position_data, 3); RenderHelper.initColorArray(0xffffffff, m_color); m_normal_texture = tex_manager.get(R.raw.texture_grey_unpressed_button); m_selected_texture = tex_manager.get(R.raw.texture_grey_pressed_button); }
public MenuItemButton( Vector position, Vector size, Font2DSettings font_settings, String font_string, TextureManager tex_manager) { super(position, size); m_item_font = new Font2D(tex_manager, size, font_settings, (int) Math.round(size.y * 0.7)); m_item_font.setString(font_string); m_texture_pressed = tex_manager.get(R.raw.texture_main_menu_pressed_button, false); m_texture_unpressed = tex_manager.get(R.raw.texture_main_menu_unpressed_button, false); m_position_data = new VertexBufferFloat(VertexBufferFloat.sprite_position_data, 3); RenderHelper.initColorArray(0xffffffff, m_color); // disabled button color RenderHelper.initColorArray(0xff888888, m_color_disabled); }
public void setString(String str) { m_item_font.setString(str); }
public void setString(String new_str) { m_text_input = new_str; m_item_font.setString(new_str); }