| Absolute File Name: | /home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/quick/util/qquickfontmetrics.cpp |
| Switch to Source code | Preprocessed file |
| Line | Source | Count | ||||||
|---|---|---|---|---|---|---|---|---|
| 1 | - | |||||||
| 2 | - | |||||||
| 3 | - | |||||||
| 4 | QQuickFontMetrics::QQuickFontMetrics(QObject *parent) : | - | ||||||
| 5 | QObject(parent), | - | ||||||
| 6 | m_metrics(m_font) | - | ||||||
| 7 | { | - | ||||||
| 8 | } executed 202 times by 1 test: end of blockExecuted by:
| 202 | ||||||
| 9 | - | |||||||
| 10 | QQuickFontMetrics::~QQuickFontMetrics() | - | ||||||
| 11 | { | - | ||||||
| 12 | } | - | ||||||
| 13 | - | |||||||
| 14 | - | |||||||
| 15 | - | |||||||
| 16 | - | |||||||
| 17 | - | |||||||
| 18 | - | |||||||
| 19 | QFont QQuickFontMetrics::font() const | - | ||||||
| 20 | { | - | ||||||
| 21 | return never executed: m_font;return m_font;never executed: return m_font; | 0 | ||||||
| 22 | } | - | ||||||
| 23 | - | |||||||
| 24 | void QQuickFontMetrics::setFont(const QFont &font) | - | ||||||
| 25 | { | - | ||||||
| 26 | if (m_font != font
| 0-20 | ||||||
| 27 | m_font = font; | - | ||||||
| 28 | m_metrics = QFontMetricsF(m_font); | - | ||||||
| 29 | fontChanged(m_font); | - | ||||||
| 30 | } executed 20 times by 1 test: end of blockExecuted by:
| 20 | ||||||
| 31 | } executed 20 times by 1 test: end of blockExecuted by:
| 20 | ||||||
| 32 | qreal QQuickFontMetrics::ascent() const | - | ||||||
| 33 | { | - | ||||||
| 34 | return executed 20 times by 1 test: m_metrics.ascent();return m_metrics.ascent();Executed by:
executed 20 times by 1 test: return m_metrics.ascent();Executed by:
| 20 | ||||||
| 35 | } | - | ||||||
| 36 | qreal QQuickFontMetrics::descent() const | - | ||||||
| 37 | { | - | ||||||
| 38 | return executed 20 times by 1 test: m_metrics.descent();return m_metrics.descent();Executed by:
executed 20 times by 1 test: return m_metrics.descent();Executed by:
| 20 | ||||||
| 39 | } | - | ||||||
| 40 | qreal QQuickFontMetrics::height() const | - | ||||||
| 41 | { | - | ||||||
| 42 | return executed 20 times by 1 test: m_metrics.height();return m_metrics.height();Executed by:
executed 20 times by 1 test: return m_metrics.height();Executed by:
| 20 | ||||||
| 43 | } | - | ||||||
| 44 | qreal QQuickFontMetrics::leading() const | - | ||||||
| 45 | { | - | ||||||
| 46 | return executed 20 times by 1 test: m_metrics.leading();return m_metrics.leading();Executed by:
executed 20 times by 1 test: return m_metrics.leading();Executed by:
| 20 | ||||||
| 47 | } | - | ||||||
| 48 | qreal QQuickFontMetrics::lineSpacing() const | - | ||||||
| 49 | { | - | ||||||
| 50 | return executed 20 times by 1 test: m_metrics.lineSpacing();return m_metrics.lineSpacing();Executed by:
executed 20 times by 1 test: return m_metrics.lineSpacing();Executed by:
| 20 | ||||||
| 51 | } | - | ||||||
| 52 | qreal QQuickFontMetrics::minimumLeftBearing() const | - | ||||||
| 53 | { | - | ||||||
| 54 | return executed 20 times by 1 test: m_metrics.minLeftBearing();return m_metrics.minLeftBearing();Executed by:
executed 20 times by 1 test: return m_metrics.minLeftBearing();Executed by:
| 20 | ||||||
| 55 | } | - | ||||||
| 56 | qreal QQuickFontMetrics::minimumRightBearing() const | - | ||||||
| 57 | { | - | ||||||
| 58 | return executed 20 times by 1 test: m_metrics.minRightBearing();return m_metrics.minRightBearing();Executed by:
executed 20 times by 1 test: return m_metrics.minRightBearing();Executed by:
| 20 | ||||||
| 59 | } | - | ||||||
| 60 | qreal QQuickFontMetrics::maximumCharacterWidth() const | - | ||||||
| 61 | { | - | ||||||
| 62 | return executed 20 times by 1 test: m_metrics.maxWidth();return m_metrics.maxWidth();Executed by:
executed 20 times by 1 test: return m_metrics.maxWidth();Executed by:
| 20 | ||||||
| 63 | } | - | ||||||
| 64 | qreal QQuickFontMetrics::xHeight() const | - | ||||||
| 65 | { | - | ||||||
| 66 | return executed 20 times by 1 test: m_metrics.xHeight();return m_metrics.xHeight();Executed by:
executed 20 times by 1 test: return m_metrics.xHeight();Executed by:
| 20 | ||||||
| 67 | } | - | ||||||
| 68 | qreal QQuickFontMetrics::averageCharacterWidth() const | - | ||||||
| 69 | { | - | ||||||
| 70 | return executed 20 times by 1 test: m_metrics.averageCharWidth();return m_metrics.averageCharWidth();Executed by:
executed 20 times by 1 test: return m_metrics.averageCharWidth();Executed by:
| 20 | ||||||
| 71 | } | - | ||||||
| 72 | qreal QQuickFontMetrics::underlinePosition() const | - | ||||||
| 73 | { | - | ||||||
| 74 | return executed 20 times by 1 test: m_metrics.underlinePos();return m_metrics.underlinePos();Executed by:
executed 20 times by 1 test: return m_metrics.underlinePos();Executed by:
| 20 | ||||||
| 75 | } | - | ||||||
| 76 | qreal QQuickFontMetrics::overlinePosition() const | - | ||||||
| 77 | { | - | ||||||
| 78 | return executed 20 times by 1 test: m_metrics.overlinePos();return m_metrics.overlinePos();Executed by:
executed 20 times by 1 test: return m_metrics.overlinePos();Executed by:
| 20 | ||||||
| 79 | } | - | ||||||
| 80 | qreal QQuickFontMetrics::strikeOutPosition() const | - | ||||||
| 81 | { | - | ||||||
| 82 | return executed 20 times by 1 test: m_metrics.strikeOutPos();return m_metrics.strikeOutPos();Executed by:
executed 20 times by 1 test: return m_metrics.strikeOutPos();Executed by:
| 20 | ||||||
| 83 | } | - | ||||||
| 84 | qreal QQuickFontMetrics::lineWidth() const | - | ||||||
| 85 | { | - | ||||||
| 86 | return executed 20 times by 1 test: m_metrics.lineWidth();return m_metrics.lineWidth();Executed by:
executed 20 times by 1 test: return m_metrics.lineWidth();Executed by:
| 20 | ||||||
| 87 | } | - | ||||||
| 88 | qreal QQuickFontMetrics::advanceWidth(const QString &text) const | - | ||||||
| 89 | { | - | ||||||
| 90 | return executed 200 times by 1 test: m_metrics.width(text);return m_metrics.width(text);Executed by:
executed 200 times by 1 test: return m_metrics.width(text);Executed by:
| 200 | ||||||
| 91 | } | - | ||||||
| 92 | QRectF QQuickFontMetrics::boundingRect(const QString &text) const | - | ||||||
| 93 | { | - | ||||||
| 94 | return executed 200 times by 1 test: m_metrics.boundingRect(text);return m_metrics.boundingRect(text);Executed by:
executed 200 times by 1 test: return m_metrics.boundingRect(text);Executed by:
| 200 | ||||||
| 95 | } | - | ||||||
| 96 | QRectF QQuickFontMetrics::tightBoundingRect(const QString &text) const | - | ||||||
| 97 | { | - | ||||||
| 98 | return executed 200 times by 1 test: m_metrics.tightBoundingRect(text);return m_metrics.tightBoundingRect(text);Executed by:
executed 200 times by 1 test: return m_metrics.tightBoundingRect(text);Executed by:
| 200 | ||||||
| 99 | } | - | ||||||
| 100 | QString QQuickFontMetrics::elidedText(const QString &text, Qt::TextElideMode mode, qreal width, int flags) const | - | ||||||
| 101 | { | - | ||||||
| 102 | return executed 200 times by 1 test: m_metrics.elidedText(text, mode, width, flags);return m_metrics.elidedText(text, mode, width, flags);Executed by:
executed 200 times by 1 test: return m_metrics.elidedText(text, mode, width, flags);Executed by:
| 200 | ||||||
| 103 | } | - | ||||||
| 104 | - | |||||||
| 105 | - | |||||||
| 106 | - | |||||||
| Switch to Source code | Preprocessed file |