Details
-
Bug
-
Resolution: Out of scope
-
P2: Important
-
None
-
4.8.0
-
None
-
Windows 7 64, XP 32
Description
In the function QGLWidget::renderText(), if the font size supplied to the function is 0, the function takes a default font size and draws the text in the OpenGL scene. The problem I'm presenting here is the case between font size 0 and font sizes more than zero. In OpenGL scenes, one sometimes needs to change the size of the objects in the scene using glScaled() (or any equivalent function) to give the illusion of objects going far away and coming closer. And since text is not effected by glScaled(), the developer has to do it manually by adding a scale coefficient beside the font's size. I have implemented this idea in my own simulation, and got segmentation faults when the font is small enough.
In the file attached, I present the abstract problem in the grabber example provided in QtSDK 1.2. I just added a text to that simulation, and with the mousewheel, the text size changes. Surprisingly, the program crashes with a segmentation fault at some text size greater than zero, where this doesn't make sense, since zero font size is supported.