This is the same code, but I fixed the compiling errors that appeared. Sorry for causing you so much trouble over this code posting thing. :/
And I do confirm that this produces the same error.
#include <iostream>
#include <SFML/Graphics.hpp>
#include <SFML/System.hpp>
using namespace std;
namespace tGUI
{
class Button
{
string text;
sf::String sf_text;
sf::Shape canvas;
public:
Button()
{
canvas = sf::Shape::Rectangle(100,100,400,400, sf::Color::White, 5, sf::Color::White);
canvas.EnableFill(false);
canvas.EnableOutline(true);
canvas.SetPosition(100,100);
sf_text.SetPosition(100,100);
}
void SetText(string c = "")
{
text = c;
sf_text.SetText(text);
}
virtual void Render(sf::RenderTarget& Window) const
{
Window.Clear();
Window.SetView(Window.GetDefaultView());
Window.Draw(canvas);
Window.Draw(sf_text);
}
};
}
int main()
{
sf::RenderWindow App(sf::VideoMode::GetMode(0), " ");
tGUI::Button button;
button.SetText("Text String");
while (App.IsOpened())
{
button.Render(App);
App.Display();
}
return 0;
}