Rendering only a part of text FTGL, OpenGL
- by Mosquito
I'm using FTGL library to render text in my C++ project.
I can easily render text by using:
CFontManager::Instance().renderWrappedText(font, lineLength, position, text);
Unfortunately there is a situation in which this Button which displays text, is partly hidden because of resizing container in which it is situated. I'm able without any problem to draw Button's background to fit the container, but I've got a problem with doing the same with a text. Is it possible to somehow draw only text for given width and the rest just ignore?
This is a screen which presents my problem:
As you can see, the Button "Click here" is being drawn properly, but I can't do the same with "Click here" text.