| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
When the paint engine does not support QStaticText, we fall back to
regular drawText() calls. This fallback would previously paint all
text to (0, 0). This fixes the qstatictext autotest on Linux.
Reviewed-by: Olivier
|
|\ |
|
| |
| |
| |
| |
| |
| |
| | |
Make the API more general and more readable by using a PerformanceHint
enum instead of an on/off-trigger for the OpenGL-specific caching.
Reviewed-by: Samuel
|
|/
|
|
| |
Reviewed-by: Trust Me
|
|
|
|
|
|
|
| |
The QGLWidget tests would fail at random. The use case has been
confirmed to work through manual tests, but I haven't found any good
way to test them automatically. They have been removed until time
permits.
|
|
|
|
|
| |
QStaticText was previously made private API to support inclusion in
Qt 4.6.x. This change turns it back into public API for Qt 4.7.0.
|
|
|
|
| |
Some tests with and without VBO caching.
|
|
|
|
|
|
|
|
|
|
|
| |
We can't add new symbols to QPainter for Qt 4.6.x, as we would not be
able to remove them again if we regretted the API. Hence, I've made
removable symbols instead, a private global function and a
drawStaticText() in QPainterPrivate. In order to tie things together,
I needed a static private-getter in QPainterPrivate, and hence it
had to be a friend of QPainter.
Reviewed-by: Trond
|
|
|
|
|
|
| |
The rotatedTranslatedScaled-test would transform the text out of the
destination rect, so we'd just confirm two blank images. Also added
input to the two basic tests for backend optimizations.
|
|
|
|
|
|
|
|
| |
Turns QStaticText into private API in preparation for Qt 4.6.x. The
related functions in QPainter are marked as internal in the docs. There
are already internal functions in QPainter, so this seemed like a
reasonable solution. Since the functions require QStaticText they will
not be accessible to anyone who does not include private API.
|
|
|
|
|
| |
Projected text always has to go via paths, so we use the fall back for
this.
|
|
|
|
|
|
|
| |
Using QImage would only let us test the raster engine. Substitute
QPixmap, so we can test different graphics systems. Also initialize the
memory in the pixmaps (this was missed because memory is initialized by
default in debug builds.)
|
|
|
|
|
| |
This is more suited to be a benchmark, as it doesn't cover the
functionality of the class.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
painter
1. The font property in QStaticText has been removed. Rather than set a
font on the text explicitly, it picks up the font from the painter. If
you change the font on the painter, the text layout will have to be
updated, like with a matrix.
2. The translation might not be the only transformation on the painter,
so rather than translate back to origo, we explicitly set dx and dy
on the transform to 0.0 for the duration of the function.
3. Update test to reflect changes
|
|
|
|
|
|
| |
Combining rotations and translations will cause minor differences
between drawText() and drawStaticText(). This is not what the function
is testing, so it has been massaged to pass.
|
|
|
|
| |
Don't save images by default.
|
|
|
|
|
|
|
|
| |
There are tiny rounding errors in the matrix rotations which cause tiny
differences in drawText() and drawStaticText(). I've chosen to ignore
these. Instead of having a threshold on the comparison between the two
images, I've chosen to take the easy way out and avoid the problem by
not passing in any position for the text.
|
|
|
|
|
| |
Most of these tests currently fail revealing som offset bugs in the
painting code.
|
|
Tests that QStaticText rendering is identical to the same operations
done with regular QPainter::drawText()
|