Changeset 9383 in ntrip for trunk/BNC/qwt/qwt_plot_textlabel.cpp
- Timestamp:
- Mar 19, 2021, 9:15:03 AM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/qwt/qwt_plot_textlabel.cpp
r8127 r9383 16 16 17 17 static QRect qwtItemRect( int renderFlags, 18 const QRectF &rect, const QSizeF &itemSize ) 18 const QRectF &rect, const QSizeF &itemSize ) 19 19 { 20 20 int x; … … 33 33 34 34 int y; 35 if ( renderFlags & Qt::AlignTop ) 35 if ( renderFlags & Qt::AlignTop ) 36 36 { 37 37 y = rect.top(); … … 50 50 51 51 class QwtPlotTextLabel::PrivateData 52 { 52 { 53 53 public: 54 54 PrivateData(): … … 61 61 62 62 QPixmap pixmap; 63 }; 63 }; 64 64 65 65 /*! … … 102 102 103 103 /*! 104 Set the text 104 Set the text 105 105 106 106 The label will be aligned to the plot canvas according to … … 211 211 pw = qMax( d_data->text.borderPen().width(), 1 ); 212 212 213 QRect pixmapRect; 213 QRect pixmapRect; 214 214 pixmapRect.setLeft( qFloor( rect.left() ) - pw ); 215 215 pixmapRect.setTop( qFloor( rect.top() ) - pw ); 216 216 pixmapRect.setRight( qCeil( rect.right() ) + pw ); 217 217 pixmapRect.setBottom( qCeil( rect.bottom() ) + pw ); 218 218 219 219 #define QWT_HIGH_DPI 1 220 220 … … 225 225 const QSize scaledSize = pixmapRect.size(); 226 226 #endif 227 if ( d_data->pixmap.isNull() || 227 if ( d_data->pixmap.isNull() || 228 228 ( scaledSize != d_data->pixmap.size() ) ) 229 229 { … … 234 234 d_data->pixmap.fill( Qt::transparent ); 235 235 236 const QRect r( pw, pw, 236 const QRect r( pw, pw, 237 237 pixmapRect.width() - 2 * pw, pixmapRect.height() - 2 * pw ); 238 238 … … 260 260 \sa setMargin(), QwtText::renderFlags(), QwtText::textSize() 261 261 */ 262 QRectF QwtPlotTextLabel::textRect( 262 QRectF QwtPlotTextLabel::textRect( 263 263 const QRectF &rect, const QSizeF &textSize ) const 264 264 {
Note:
See TracChangeset
for help on using the changeset viewer.