[[ArchivePage]] An engine, that renders text on openGLTextures, and displays them on the screen. == usage == * simple: {{{ #!cpp #include "text.h" ... // create a new Text. Text* newText = new Text("fontfile.ttf", 16); // set some color (red, green, blue [0-1]) newText->setColor(1, 0, 0); // set some blending, and everything will shine through. newText->setBlending(.8); // set another alignment newText->setAlignment(TEXT_ALIGN_LEFT); // and display some text newText->setText("wow... so easy??"); ... }}} * advanced: * Text implements Element2D from [wiki:archive/Render2D Render2D] * you can reload fonts using {{{ #!cpp newText->setFont(const char* fontFile, unsigned int fontSize); }}} * if you like to be quick, and handle the char-array externally (the text wont delete the array, and will segfault, if the char-array is deleted) use something like: (notice the true) {{{ #!cpp char* textPointerHandledExternally = "blabla"; newText->setText(textPointerHandledExternally, true); }}} * Hiding text: {{{ #!cpp newText->setVisibility(false); }}} (this is Element2D-functionality)