C++

String concatenation with QStringBuilder

Published Monday June 13th, 2011 | 14 Comments on String concatenation with QStringBuilder
Posted in C++, Performance, Qt

QString and QByteArray comes with very handy operator+ which allows you to write stuff like this: QString directory = /*…*/, name = /*…*/; QString dataFile = directory + QLatin1Char(‘/’) + name + QLatin1String(“.dat”); Very convenient. The QLatin1Char and QLatin1String are just there for correctness, you could omit those while writing your application. We have something […]

Read More

C++0x in Qt

Published Thursday May 26th, 2011 | 30 Comments on C++0x in Qt
Posted in C++, KDE, News, Qt

While many are so enthusiastic about QML and javascript technology, a few of us still code in C++ ;-). C++ is about to get an upgrade: C++11 (formely known as C++0x). The final draft was aproved last march in the C++ standard commitee, and the final specification is expected to be published this summer. If […]

Read More

Qt hidden gems

Published Friday April 1st, 2011 | 28 Comments on Qt hidden gems
Posted in C++, News, Qt, QtCreator, Rants

As it happens to me usually, talking on IRC revealed another interesting topic to talk about. One developer was asking a question why part of his application window suddenly became blank after the mouse entered the window. Even though it’s not really my area of expertise, I guessed it was related to painting, so after […]

Read More

QStrings and Unicode — optimising QString::fromUtf8

Published Friday March 25th, 2011 | 15 Comments on QStrings and Unicode — optimising QString::fromUtf8
Posted in C++, Performance, Qt

Other blogs in this series: http://labs.qt.nokia.com/2010/08/24/improving-the-rendering-performance-with-more-simd/ Improving the string performance with more SIMD (or not) Related: String Theory Last time, I attacked the problem of the conversion from Latin 1 (ISO-8859-1) to UTF-16 in QStrings. Most character literals in C++ source code are actually in ASCII, which is a subset of Latin 1, which in […]

Read More
Eskil Abrahamsen Blomfeldt

Hint, hint, nudge, nudge, say no more!

Published Monday March 14th, 2011 | 16 Comments on Hint, hint, nudge, nudge, say no more!
Posted in C++, KOffice, macOS, Painting, Qt, Windows

At the time of writing, the task with the most votes in Qt’s bug tracker is the somewhat vaguely named umbrella task “Allow better font rendering for projects like Koffice”. The background for the task is a lacking cross-platform support in Qt for text layouts done in the design metrics of the font. Depending on […]

Read More

Touching the X11

Published Wednesday December 15th, 2010 | 11 Comments on Touching the X11
Posted in C++, Labs, Qt

There was no easy way to make use of touch- input devices on Linux with Qt. Up until now. On a recent meeting with other people interested in getting touch (and here we are also talking about touch with multiple points) in Linux/X11 during the X.org Developer Summit and Ubuntu Developer Summit (great events!), it […]

Read More
Get started today with Qt Download now