summaryrefslogtreecommitdiffstats
path: root/tests/auto/qfont/tst_qfont.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Update year in Nokia copyright messages.Jason McDonald2012-01-111-1/+1
| | | | | | | | | Simple search and replace. This commit doesn't touch 3rd-party files, nor translations (where the change is not so simple and will be handled in a separate commit). Change-Id: I4e48513b8078a44a8cd272326685b25338890148 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Allow selecting fonts with irregular style namesJiang Jiang2011-06-101-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fonts like "Helvetica Neue UltraLight" or "Skia Regular Black Condensed" can't be selected in Qt because either they don't report correct numeric values for weight/stretch/etc. or these values are not mapped from QFont enums in a linear way. Thus we provide a shortcut to select these fonts with PostScript name or full name without resorting to family name matching in QFontDatabase (these fonts are not registered in font database anyway). After this, we can simply use: QFont font("Helvetica Neue"); font.setStyleName("UltraLight"); to select these fonts. QCoreTextFontEngineMulti matched like this can be created directly from the CTFontRef instance instead of creating from the font name, making this process faster. The commit also cleaned up the font loading process in Mac font database a bit, moving the code for family matching into a separate function. Add QFontInfo::styleName() and QRawFont::styleName() to access the resolved style name for a font. Task-number: QTBUG-19366 Change-Id: Iad07768c02ed06cc8d6b7395dec554384f410506 Reviewed-on: http://codereview.qt.nokia.com/333 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com> (cherry picked from commit 97391be5ebddc62545ddb88f92fc2045bfa10711)
* Update licenseheader text in source files for qt4.8Jyri Tahtela2011-05-131-17/+17
| | | | | | | Updated version of LGPL and FDL licenseheaders. Apply release phase licenseheaders for all source files. Reviewed-by: Trust Me
* Resolve font alias before testing for exact matchingJiang Jiang2011-02-281-0/+7
| | | | | | | | | It is required in X11 for resolving some default substitutions like 'sans', 'serif', etc. It also provides stub to implement similar replacement in other platforms like Windows. Task-number: QTBUG-15575 Reviewed-by: Eskil
* Update copyright year to 2011.Jason McDonald2011-01-101-1/+1
| | | | Reviewed-by: Trust Me
* Skip tst_QFont::lastResortFont() for Q_WS_QWSAlessandro Portale2010-09-291-0/+5
| | | | | | | QFont::lastResortFont() may abort with qFatal() on QWS if absolutely no font is found. Just as ducumented. This happens on our CI machines which run QWS autotests.
* Implemeting, exporting and autotesting QFont::lastResortFont()Alessandro Portale2010-09-281-0/+7
| | | | | | | | | | | | | | | | | | | | | An implementation of QFont::lastResortFont() is still(!) missing in Qt 4.7.0. I only became aware of QTBUG-6921, lately. This patch... 1) implements QFont::lastResortFont() in qfont_s60.cpp by first trying to get the lastResortFamily() and then falling back to a hardcoded font. 2) updates the .def files with one additional entry 3) adds an autotest which verifies that lastResortFamily() does return a non-empty string. In the firt place, that autotest makes sure that lastResortFamily() is implemented and exported, so that something like this issue will not go unnoticed in the next Qt port. Task-number: QTBUG-6921 Reviewed-by: Eskil
* Update copyright year to 2010Jason McDonald2010-01-061-1/+1
| | | | Reviewed-by: Trust Me
* Small caps font variant wouldn't be used when defined through style sheetsGabriel de Dietrich2009-11-111-0/+7
| | | | | | | | The font comparison (operator==) didn't check the capital attribute, which is the one responsible for this variant. Now it does. Auto-test updated. Reviewed-by: Samuel Reviewed-by: Olivier
* Update license headers again.Jason McDonald2009-09-091-4/+4
| | | | Reviewed-by: Trust Me
* Update tech preview license header.Jason McDonald2009-08-311-13/+13
| | | | Reviewed-by: Trust Me
* Update license headers.Jason McDonald2009-08-111-1/+1
| | | | Reviewed-by: Trust Me
* Update license headers as requested by the marketing department.Jason McDonald2009-06-161-2/+2
| | | | Reviewed-by: Trust Me
* Remove obsolete code from autotests.Jason McDonald2009-04-161-3/+0
| | | | | | | | Each version of Qt has its own set of autotests, therefore preprocessor directives relating to obsolete QT_VERSION's are not necessary. Reviewed-by: Carlos Duclos
* Long live Qt 4.5!Lars Knoll2009-03-231-0/+593