Hi, I just discovered SFML some weeks ago and I still learning this great API.
Today I have seen the new website and downloaded the final 2.0 release. It looks awesome.
Thank you Laurent for your work.
#include <SFML/Graphics.hpp>
int main()
{
sf::RenderWindow window(sf::VideoMode(800, 600, 32), "Hello SFML forum");
sf::Text message;
sf::Font font;
if (!font.loadFromFile("Font1.ttf"))
return EXIT_FAILURE;
message.setString("Hello SFML forum users, I'm Ivan");
message.setFont(font);
message.setCharacterSize(16);
message.setColor(sf::Color(255, 255, 0, 255));
message.setPosition(sf::Vector2f(20, 20));
while (window.isOpen())
{
sf::Event event;
while (window.pollEvent(event))
{
if (event.type == sf::Event::Closed ||
event.key.code == sf::Keyboard::Escape)
window.close();
}
window.clear(sf::Color::Black);
window.draw(message);
window.display();
}
return EXIT_SUCCESS;
}