| Line | Source | Count | 
| 1 |  | - | 
| 2 |  | - | 
| 3 |  | - | 
| 4 |  | - | 
| 5 |  | - | 
| 6 |  | - | 
| 7 |  | - | 
| 8 |  | - | 
| 9 |  | - | 
| 10 | typedef GdkPixbuf* (*Ptr_gdk_pixbuf_get_from_drawable) (GdkPixbuf *, GdkDrawable *, GdkColormap *, int, int, int, int, int, int); | - | 
| 11 | typedef GdkPixmap* (*Ptr_gdk_pixmap_new) (GdkDrawable *, gint, gint, gint); | - | 
| 12 | typedef void (*Ptr_gdk_draw_rectangle) (GdkDrawable *, GdkGC *, gboolean, gint, gint, gint, gint); | - | 
| 13 | typedef void (*Ptr_gdk_drawable_unref)(GdkDrawable *); | - | 
| 14 |  | - | 
| 15 | typedef void (*Ptr_gtk_paint_check) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint); | - | 
| 16 | typedef void (*Ptr_gtk_paint_box) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint); | - | 
| 17 | typedef void (*Ptr_gtk_paint_box_gap) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint, gint, gint , gint, GtkPositionType, gint, gint); | - | 
| 18 | typedef void (*Ptr_gtk_paint_resize_grip) (GtkStyle *, GdkWindow *, GtkStateType, const GdkRectangle *, GtkWidget *, const gchar *, GdkWindowEdge, gint , gint , gint , gint); | - | 
| 19 | typedef void (*Ptr_gtk_paint_focus) (GtkStyle *, GdkWindow *, GtkStateType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint); | - | 
| 20 | typedef void (*Ptr_gtk_paint_shadow) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint); | - | 
| 21 | typedef void (*Ptr_gtk_paint_slider) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint, GtkOrientation); | - | 
| 22 | typedef void (*Ptr_gtk_paint_expander) (GtkStyle *, GdkWindow *, GtkStateType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , GtkExpanderStyle ); | - | 
| 23 | typedef void (*Ptr_gtk_paint_handle) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint, GtkOrientation); | - | 
| 24 | typedef void (*Ptr_gtk_paint_arrow) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, GtkArrowType, gboolean, gint , gint , gint , gint); | - | 
| 25 | typedef void (*Ptr_gtk_paint_option) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint); | - | 
| 26 | typedef void (*Ptr_gtk_paint_flat_box) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint , gint , gint , gint); | - | 
| 27 | typedef void (*Ptr_gtk_paint_extension) (GtkStyle *, GdkWindow *, GtkStateType, GtkShadowType, const GdkRectangle *, GtkWidget *, const gchar *, gint, gint, gint, gint, GtkPositionType); | - | 
| 28 | typedef void (*Ptr_gtk_paint_hline) (GtkStyle *, GdkWindow *, GtkStateType, const GdkRectangle *, GtkWidget *, const gchar *, gint, gint, gint y); | - | 
| 29 | typedef void (*Ptr_gtk_paint_vline) (GtkStyle *, GdkWindow *, GtkStateType, const GdkRectangle *, GtkWidget *, const gchar *, gint, gint, gint); | - | 
| 30 |  | - | 
| 31 | namespace QGtk2PainterPrivate { | - | 
| 32 |     static Ptr_gdk_pixmap_new gdk_pixmap_new = 0; | - | 
| 33 |     static Ptr_gdk_pixbuf_get_from_drawable gdk_pixbuf_get_from_drawable = 0; | - | 
| 34 |     static Ptr_gdk_draw_rectangle gdk_draw_rectangle = 0; | - | 
| 35 |     static Ptr_gdk_drawable_unref gdk_drawable_unref = 0; | - | 
| 36 |  | - | 
| 37 |     static Ptr_gtk_paint_check gtk_paint_check = 0; | - | 
| 38 |     static Ptr_gtk_paint_box gtk_paint_box = 0; | - | 
| 39 |     static Ptr_gtk_paint_box_gap gtk_paint_box_gap = 0; | - | 
| 40 |     static Ptr_gtk_paint_flat_box gtk_paint_flat_box = 0; | - | 
| 41 |     static Ptr_gtk_paint_option gtk_paint_option = 0; | - | 
| 42 |     static Ptr_gtk_paint_extension gtk_paint_extension = 0; | - | 
| 43 |     static Ptr_gtk_paint_slider gtk_paint_slider = 0; | - | 
| 44 |     static Ptr_gtk_paint_shadow gtk_paint_shadow = 0; | - | 
| 45 |     static Ptr_gtk_paint_resize_grip gtk_paint_resize_grip = 0; | - | 
| 46 |     static Ptr_gtk_paint_focus gtk_paint_focus = 0; | - | 
| 47 |     static Ptr_gtk_paint_arrow gtk_paint_arrow = 0; | - | 
| 48 |     static Ptr_gtk_paint_handle gtk_paint_handle = 0; | - | 
| 49 |     static Ptr_gtk_paint_expander gtk_paint_expander = 0; | - | 
| 50 |     static Ptr_gtk_paint_vline gtk_paint_vline = 0; | - | 
| 51 |     static Ptr_gtk_paint_hline gtk_paint_hline = 0; | - | 
| 52 | } | - | 
| 53 |  | - | 
| 54 | static void initGtk() | - | 
| 55 | { | - | 
| 56 |  | - | 
| 57 |     static bool initialized = false; | - | 
| 58 |     if (!initialized| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 59 |  | - | 
| 60 |         QLibrary libgtk(QLatin1String("gtk-x11-2.0"), 0, 0); | - | 
| 61 |  | - | 
| 62 |         QGtk2PainterPrivate::gdk_pixmap_new = (Ptr_gdk_pixmap_new)libgtk.resolve("gdk_pixmap_new"); | - | 
| 63 |         QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable = (Ptr_gdk_pixbuf_get_from_drawable)libgtk.resolve("gdk_pixbuf_get_from_drawable"); | - | 
| 64 |         QGtk2PainterPrivate::gdk_draw_rectangle = (Ptr_gdk_draw_rectangle)libgtk.resolve("gdk_draw_rectangle"); | - | 
| 65 |         QGtk2PainterPrivate::gdk_drawable_unref = (Ptr_gdk_drawable_unref)libgtk.resolve("gdk_drawable_unref"); | - | 
| 66 |  | - | 
| 67 |         QGtk2PainterPrivate::gtk_paint_check = (Ptr_gtk_paint_check)libgtk.resolve("gtk_paint_check"); | - | 
| 68 |         QGtk2PainterPrivate::gtk_paint_box = (Ptr_gtk_paint_box)libgtk.resolve("gtk_paint_box"); | - | 
| 69 |         QGtk2PainterPrivate::gtk_paint_flat_box = (Ptr_gtk_paint_flat_box)libgtk.resolve("gtk_paint_flat_box"); | - | 
| 70 |         QGtk2PainterPrivate::gtk_paint_check = (Ptr_gtk_paint_check)libgtk.resolve("gtk_paint_check"); | - | 
| 71 |         QGtk2PainterPrivate::gtk_paint_box = (Ptr_gtk_paint_box)libgtk.resolve("gtk_paint_box"); | - | 
| 72 |         QGtk2PainterPrivate::gtk_paint_resize_grip = (Ptr_gtk_paint_resize_grip)libgtk.resolve("gtk_paint_resize_grip"); | - | 
| 73 |         QGtk2PainterPrivate::gtk_paint_focus = (Ptr_gtk_paint_focus)libgtk.resolve("gtk_paint_focus"); | - | 
| 74 |         QGtk2PainterPrivate::gtk_paint_shadow = (Ptr_gtk_paint_shadow)libgtk.resolve("gtk_paint_shadow"); | - | 
| 75 |         QGtk2PainterPrivate::gtk_paint_slider = (Ptr_gtk_paint_slider)libgtk.resolve("gtk_paint_slider"); | - | 
| 76 |         QGtk2PainterPrivate::gtk_paint_expander = (Ptr_gtk_paint_expander)libgtk.resolve("gtk_paint_expander"); | - | 
| 77 |         QGtk2PainterPrivate::gtk_paint_handle = (Ptr_gtk_paint_handle)libgtk.resolve("gtk_paint_handle"); | - | 
| 78 |         QGtk2PainterPrivate::gtk_paint_option = (Ptr_gtk_paint_option)libgtk.resolve("gtk_paint_option"); | - | 
| 79 |         QGtk2PainterPrivate::gtk_paint_arrow = (Ptr_gtk_paint_arrow)libgtk.resolve("gtk_paint_arrow"); | - | 
| 80 |         QGtk2PainterPrivate::gtk_paint_box_gap = (Ptr_gtk_paint_box_gap)libgtk.resolve("gtk_paint_box_gap"); | - | 
| 81 |         QGtk2PainterPrivate::gtk_paint_extension = (Ptr_gtk_paint_extension)libgtk.resolve("gtk_paint_extension"); | - | 
| 82 |         QGtk2PainterPrivate::gtk_paint_hline = (Ptr_gtk_paint_hline)libgtk.resolve("gtk_paint_hline"); | - | 
| 83 |         QGtk2PainterPrivate::gtk_paint_vline = (Ptr_gtk_paint_vline)libgtk.resolve("gtk_paint_vline"); | - | 
| 84 |  | - | 
| 85 |         initialized = true; | - | 
| 86 |     } never executed: end of block  | 0 | 
| 87 |  | - | 
| 88 | } never executed: end of block  | 0 | 
| 89 |  | - | 
| 90 |  | - | 
| 91 |  | - | 
| 92 |  | - | 
| 93 | QPixmap QGtk2Painter::renderTheme(uchar *bdata, uchar *wdata, const QRect &rect) const | - | 
| 94 | { | - | 
| 95 |     const int bytecount = rect.width() * rect.height() * 4; | - | 
| 96 |     for (int index = 0; index < bytecount| TRUE | never evaluated |  | FALSE | never evaluated |  
   ; index += 4) { | 0 | 
| 97 |         uchar val = bdata[index + 0]; | - | 
| 98 |         if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 99 |             int alphaval = qMax(bdata[index + 0] - wdata[index + 0], | - | 
| 100 |                                 bdata[index + 1] - wdata[index + 1]); | - | 
| 101 |             alphaval = qMax(alphaval, bdata[index + 2] - wdata[index + 2]) + 255; | - | 
| 102 |             bdata[index + 3] = alphaval; | - | 
| 103 |         } never executed: end of block  | 0 | 
| 104 |         bdata[index + 0] = bdata[index + 2]; | - | 
| 105 |         bdata[index + 1] = bdata[index + 1]; | - | 
| 106 |         bdata[index + 2] = val; | - | 
| 107 |     } never executed: end of block  | 0 | 
| 108 |     QImage converted((const uchar*)bdata, rect.width(), rect.height(), m_alpha ? | - | 
| 109 |                      QImage::Format_ARGB32_Premultiplied : QImage::Format_RGB32); | - | 
| 110 |  | - | 
| 111 |     if (m_hflipped| TRUE | never evaluated |  | FALSE | never evaluated |  
   || m_vflipped| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 112 |         return never executed: return QPixmap::fromImage(converted.mirrored(m_hflipped, m_vflipped));  QPixmap::fromImage(converted.mirrored(m_hflipped, m_vflipped));never executed: return QPixmap::fromImage(converted.mirrored(m_hflipped, m_vflipped));  | 0 | 
| 113 |     } else { | - | 
| 114 |  | - | 
| 115 |  | - | 
| 116 |         return never executed: return QPixmap::fromImage(converted.copy());  QPixmap::fromImage(converted.copy());never executed: return QPixmap::fromImage(converted.copy());  | 0 | 
| 117 |     } | - | 
| 118 | } | - | 
| 119 | QGtk2Painter::QGtk2Painter() : QGtkPainter(), m_window(QGtkStylePrivate::gtkWidget("GtkWindow")) | - | 
| 120 | { | - | 
| 121 |     initGtk(); | - | 
| 122 | } never executed: end of block  | 0 | 
| 123 |  | - | 
| 124 |  | - | 
| 125 | void QGtk2Painter::paintBoxGap(GtkWidget *gtkWidget, const gchar* part, | - | 
| 126 |                               const QRect &paintRect, GtkStateType state, | - | 
| 127 |                               GtkShadowType shadow, GtkPositionType gap_side, | - | 
| 128 |                               gint x, gint width, | - | 
| 129 |                               GtkStyle *style) | - | 
| 130 | { | - | 
| 131 |     if (!paintRect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 132 |         return; never executed: return;  | 0 | 
| 133 |  | - | 
| 134 |     QPixmap cache; | - | 
| 135 |     QRect rect = paintRect; | - | 
| 136 |  | - | 
| 137 |  | - | 
| 138 |  | - | 
| 139 |  | - | 
| 140 |     const int maxHeight = 256; | - | 
| 141 |     const int border = 16; | - | 
| 142 |     if (rect.height() > maxHeight| TRUE | never evaluated |  | FALSE | never evaluated |  
   && (gap_side == GTK_POS_TOP| TRUE | never evaluated |  | FALSE | never evaluated |  
   || gap_side == GTK_POS_BOTTOM| TRUE | never evaluated |  | FALSE | never evaluated |  
  )) | 0 | 
| 143 |         rect.setHeight(2 * border + 1); never executed: rect.setHeight(2 * border + 1);  | 0 | 
| 144 |  | - | 
| 145 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size(), gtkWidget) | - | 
| 146 |                          % HexString<uchar>(gap_side) | - | 
| 147 |                          % HexString<gint>(width) | - | 
| 148 |                          % HexString<gint>(x); | - | 
| 149 |  | - | 
| 150 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 151 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_box_gap (style, pixmap, state, shadow, __null, gtkWidget, (const gchar*)part, 0, 0, rect.width(), rect.height(), gap_side, x, width); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_box_gap (style, pixmap, state, shadow, __null, gtkWidget, (const gchar*)part, 0, 0, rect.width(), rect.height(), gap_side, x, width); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 152 |                                                   ; | - | 
| 153 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 154 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 155 |     } never executed: end of block  | 0 | 
| 156 |     if (rect.size() != paintRect.size()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 157 |  | - | 
| 158 |  | - | 
| 159 |         const QSize size = cache.size(); | - | 
| 160 |  | - | 
| 161 |         m_painter->drawPixmap(QRect(paintRect.left(), paintRect.top(), | - | 
| 162 |                                     paintRect.width(), border), cache, | - | 
| 163 |                              QRect(0, 0, size.width(), border)); | - | 
| 164 |  | - | 
| 165 |  | - | 
| 166 |         QPixmap tilePart(cache.width(), 1); | - | 
| 167 |         QPainter scanLinePainter(&tilePart); | - | 
| 168 |         scanLinePainter.drawPixmap(QRect(0, 0, tilePart.width(), tilePart.height()), cache, QRect(0, border, size.width(), 1)); | - | 
| 169 |         scanLinePainter.end(); | - | 
| 170 |         m_painter->drawTiledPixmap(QRect(paintRect.left(), paintRect.top() + border, | - | 
| 171 |                                          paintRect.width(), paintRect.height() - 2*border), tilePart); | - | 
| 172 |  | - | 
| 173 |  | - | 
| 174 |         m_painter->drawPixmap(QRect(paintRect.left(), paintRect.top() + paintRect.height() - border, | - | 
| 175 |                                     paintRect.width(), border), cache, | - | 
| 176 |                              QRect(0, size.height() - border, size.width(), border)); | - | 
| 177 |     } never executed: end of block  else | 0 | 
| 178 |         m_painter->drawPixmap(paintRect.topLeft(), cache); never executed: m_painter->drawPixmap(paintRect.topLeft(), cache);  | 0 | 
| 179 | } | - | 
| 180 |  | - | 
| 181 | void QGtk2Painter::paintBox(GtkWidget *gtkWidget, const gchar* part, | - | 
| 182 |                            const QRect &paintRect, GtkStateType state, | - | 
| 183 |                            GtkShadowType shadow, GtkStyle *style, | - | 
| 184 |                            const QString &pmKey) | - | 
| 185 | { | - | 
| 186 |     if (!paintRect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 187 |         return; never executed: return;  | 0 | 
| 188 |  | - | 
| 189 |     QPixmap cache; | - | 
| 190 |     QRect rect = paintRect; | - | 
| 191 |  | - | 
| 192 |  | - | 
| 193 |  | - | 
| 194 |  | - | 
| 195 |     const int maxHeight = 256; | - | 
| 196 |     const int maxArea = 256*512; | - | 
| 197 |     const int border = 32; | - | 
| 198 |     if (rect.height() > maxHeight| TRUE | never evaluated |  | FALSE | never evaluated |  
   && (| TRUE | never evaluated |  | FALSE | never evaluated |  
  rect.width()*rect.height() > maxArea)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 199 |         rect.setHeight(2 * border + 1); never executed: rect.setHeight(2 * border + 1);  | 0 | 
| 200 |  | - | 
| 201 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, | - | 
| 202 |                                     rect.size(), gtkWidget) % pmKey; | - | 
| 203 |  | - | 
| 204 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 205 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_box (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_box (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 206 |                                                           ; | - | 
| 207 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 208 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 209 |     } never executed: end of block  | 0 | 
| 210 |     if (rect.size() != paintRect.size()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 211 |  | - | 
| 212 |  | - | 
| 213 |         const QSize size = cache.size(); | - | 
| 214 |  | - | 
| 215 |         m_painter->drawPixmap(QRect(paintRect.left(), paintRect.top(), | - | 
| 216 |                                     paintRect.width(), border), cache, | - | 
| 217 |                               QRect(0, 0, size.width(), border)); | - | 
| 218 |  | - | 
| 219 |  | - | 
| 220 |         QPixmap tilePart(cache.width(), 1); | - | 
| 221 |         QPainter scanLinePainter(&tilePart); | - | 
| 222 |         scanLinePainter.drawPixmap(QRect(0, 0, tilePart.width(), tilePart.height()), cache, QRect(0, border, size.width(), 1)); | - | 
| 223 |         scanLinePainter.end(); | - | 
| 224 |         m_painter->drawTiledPixmap(QRect(paintRect.left(), paintRect.top() + border, | - | 
| 225 |                                          paintRect.width(), paintRect.height() - 2*border), tilePart); | - | 
| 226 |  | - | 
| 227 |  | - | 
| 228 |         m_painter->drawPixmap(QRect(paintRect.left(), paintRect.top() + paintRect.height() - border, | - | 
| 229 |                                     paintRect.width(), border), cache, | - | 
| 230 |                               QRect(0, size.height() - border, size.width(), border)); | - | 
| 231 |     } never executed: end of block  else | 0 | 
| 232 |         m_painter->drawPixmap(paintRect.topLeft(), cache); never executed: m_painter->drawPixmap(paintRect.topLeft(), cache);  | 0 | 
| 233 | } | - | 
| 234 |  | - | 
| 235 | void QGtk2Painter::paintHline(GtkWidget *gtkWidget, const gchar* part, | - | 
| 236 |                              const QRect &rect, GtkStateType state, | - | 
| 237 |                              GtkStyle *style, int x1, int x2, int y, | - | 
| 238 |                              const QString &pmKey) | - | 
| 239 | { | - | 
| 240 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 241 |         return; never executed: return;  | 0 | 
| 242 |  | - | 
| 243 |     QPixmap cache; | - | 
| 244 |     QString pixmapName = uniqueName(QLatin1String(part), state, GTK_SHADOW_NONE, rect.size(), gtkWidget) | - | 
| 245 |                          % HexString<int>(x1) | - | 
| 246 |                          % HexString<int>(x2) | - | 
| 247 |                          % HexString<int>(y) | - | 
| 248 |                          % pmKey; | - | 
| 249 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 250 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_hline (style, pixmap, state, __null, gtkWidget, part, x1, x2, y); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_hline (style, pixmap, state, __null, gtkWidget, part, x1, x2, y); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 251 |  | - | 
| 252 |  | - | 
| 253 |  | - | 
| 254 |  | - | 
| 255 |  | - | 
| 256 |                                                     ; | - | 
| 257 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 258 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 259 |     } never executed: end of block  | 0 | 
| 260 |  | - | 
| 261 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 262 | } never executed: end of block  | 0 | 
| 263 |  | - | 
| 264 | void QGtk2Painter::paintVline(GtkWidget *gtkWidget, const gchar* part, | - | 
| 265 |                              const QRect &rect, GtkStateType state, | - | 
| 266 |                              GtkStyle *style, int y1, int y2, int x, | - | 
| 267 |                              const QString &pmKey) | - | 
| 268 | { | - | 
| 269 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 270 |         return; never executed: return;  | 0 | 
| 271 |  | - | 
| 272 |     QPixmap cache; | - | 
| 273 |     QString pixmapName = uniqueName(QLatin1String(part), state, GTK_SHADOW_NONE, rect.size(), gtkWidget) | - | 
| 274 |                         % HexString<int>(y1) | - | 
| 275 |                         % HexString<int>(y2) | - | 
| 276 |                         % HexString<int>(x) | - | 
| 277 |                         % pmKey; | - | 
| 278 |  | - | 
| 279 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 280 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_vline (style, pixmap, state, __null, gtkWidget, part, y1, y2, x); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_vline (style, pixmap, state, __null, gtkWidget, part, y1, y2, x); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 281 |  | - | 
| 282 |  | - | 
| 283 |  | - | 
| 284 |  | - | 
| 285 |  | - | 
| 286 |  | - | 
| 287 |                                             ; | - | 
| 288 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 289 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 290 |     } never executed: end of block  | 0 | 
| 291 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 292 | } never executed: end of block  | 0 | 
| 293 |  | - | 
| 294 |  | - | 
| 295 | void QGtk2Painter::paintExpander(GtkWidget *gtkWidget, | - | 
| 296 |                                 const gchar* part, const QRect &rect, | - | 
| 297 |                                 GtkStateType state, GtkExpanderStyle expander_state, | - | 
| 298 |                                 GtkStyle *style, const QString &pmKey) | - | 
| 299 | { | - | 
| 300 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 301 |         return; never executed: return;  | 0 | 
| 302 |  | - | 
| 303 |     QPixmap cache; | - | 
| 304 |     QString pixmapName = uniqueName(QLatin1String(part), state, GTK_SHADOW_NONE, rect.size(), gtkWidget) | - | 
| 305 |                          % HexString<uchar>(expander_state) | - | 
| 306 |                          % pmKey; | - | 
| 307 |  | - | 
| 308 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 309 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_expander (style, pixmap, state, __null, gtkWidget, part, rect.width()/2, rect.height()/2, expander_state); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_expander (style, pixmap, state, __null, gtkWidget, part, rect.width()/2, rect.height()/2, expander_state); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 310 |  | - | 
| 311 |  | - | 
| 312 |  | - | 
| 313 |  | - | 
| 314 |                                                             ; | - | 
| 315 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 316 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 317 |     } never executed: end of block  | 0 | 
| 318 |  | - | 
| 319 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 320 | } never executed: end of block  | 0 | 
| 321 |  | - | 
| 322 | void QGtk2Painter::paintFocus(GtkWidget *gtkWidget, const gchar* part, | - | 
| 323 |                              const QRect &rect, GtkStateType state, | - | 
| 324 |                              GtkStyle *style, const QString &pmKey) | - | 
| 325 | { | - | 
| 326 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 327 |         return; never executed: return;  | 0 | 
| 328 |  | - | 
| 329 |     QPixmap cache; | - | 
| 330 |     QString pixmapName = uniqueName(QLatin1String(part), state, GTK_SHADOW_NONE, rect.size(), gtkWidget) % pmKey; | - | 
| 331 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 332 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_focus (style, pixmap, state, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_focus (style, pixmap, state, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 333 |  | - | 
| 334 |  | - | 
| 335 |  | - | 
| 336 |  | - | 
| 337 |                                                         ; | - | 
| 338 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 339 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 340 |     } never executed: end of block  | 0 | 
| 341 |  | - | 
| 342 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 343 | } never executed: end of block  | 0 | 
| 344 |  | - | 
| 345 |  | - | 
| 346 | void QGtk2Painter::paintResizeGrip(GtkWidget *gtkWidget, const gchar* part, | - | 
| 347 |                                   const QRect &rect, GtkStateType state, | - | 
| 348 |                                   GtkShadowType shadow, GdkWindowEdge edge, | - | 
| 349 |                                   GtkStyle *style, const QString &pmKey) | - | 
| 350 | { | - | 
| 351 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 352 |         return; never executed: return;  | 0 | 
| 353 |  | - | 
| 354 |     QPixmap cache; | - | 
| 355 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size(), gtkWidget) % pmKey; | - | 
| 356 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 357 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_resize_grip (style, pixmap, state, __null, gtkWidget, part, edge, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_resize_grip (style, pixmap, state, __null, gtkWidget, part, edge, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 358 |  | - | 
| 359 |  | - | 
| 360 |  | - | 
| 361 |                                                               ; | - | 
| 362 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 363 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 364 |     } never executed: end of block  | 0 | 
| 365 |  | - | 
| 366 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 367 | } never executed: end of block  | 0 | 
| 368 |  | - | 
| 369 |  | - | 
| 370 | void QGtk2Painter::paintArrow(GtkWidget *gtkWidget, const gchar* part, | - | 
| 371 |                              const QRect &arrowrect, GtkArrowType arrow_type, | - | 
| 372 |                              GtkStateType state, GtkShadowType shadow, | - | 
| 373 |                              gboolean fill, GtkStyle *style, const QString &pmKey) | - | 
| 374 | { | - | 
| 375 |     QRect rect = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? m_cliprect : arrowrect; | 0 | 
| 376 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 377 |         return; never executed: return;  | 0 | 
| 378 |  | - | 
| 379 |     QPixmap cache; | - | 
| 380 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size()) | - | 
| 381 |                          % HexString<uchar>(arrow_type) | - | 
| 382 |                          % pmKey; | - | 
| 383 |  | - | 
| 384 |     GdkRectangle gtkCliprect = {0, 0, rect.width(), rect.height()}; | - | 
| 385 |     int xOffset = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? arrowrect.x() - m_cliprect.x() : 0; | 0 | 
| 386 |     int yOffset = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? arrowrect.y() - m_cliprect.y() : 0; | 0 | 
| 387 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 388 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_arrow (style, pixmap, state, shadow, >kCliprect, gtkWidget, part, arrow_type, fill, xOffset, yOffset, arrowrect.width(), arrowrect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_arrow (style, pixmap, state, shadow, >kCliprect, gtkWidget, part, arrow_type, fill, xOffset, yOffset, arrowrect.width(), arrowrect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 389 |  | - | 
| 390 |  | - | 
| 391 |  | - | 
| 392 |  | - | 
| 393 |  | - | 
| 394 |  | - | 
| 395 |  | - | 
| 396 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 397 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 398 |     } never executed: end of block  | 0 | 
| 399 |  | - | 
| 400 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 401 | } never executed: end of block  | 0 | 
| 402 |  | - | 
| 403 |  | - | 
| 404 | void QGtk2Painter::paintHandle(GtkWidget *gtkWidget, const gchar* part, const QRect &rect, | - | 
| 405 |                               GtkStateType state, GtkShadowType shadow, | - | 
| 406 |                               GtkOrientation orientation, GtkStyle *style) | - | 
| 407 | { | - | 
| 408 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 409 |         return; never executed: return;  | 0 | 
| 410 |  | - | 
| 411 |     QPixmap cache; | - | 
| 412 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size()) | - | 
| 413 |                          % HexString<uchar>(orientation); | - | 
| 414 |  | - | 
| 415 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 416 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_handle (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height(), orientation); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_handle (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height(), orientation); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 417 |                                                        ; | - | 
| 418 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 419 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 420 |     } never executed: end of block  | 0 | 
| 421 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 422 | } never executed: end of block  | 0 | 
| 423 |  | - | 
| 424 |  | - | 
| 425 | void QGtk2Painter::paintSlider(GtkWidget *gtkWidget, const gchar* part, const QRect &rect, | - | 
| 426 |                               GtkStateType state, GtkShadowType shadow, | - | 
| 427 |                               GtkStyle *style, GtkOrientation orientation, | - | 
| 428 |                               const QString &pmKey) | - | 
| 429 | { | - | 
| 430 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 431 |         return; never executed: return;  | 0 | 
| 432 |  | - | 
| 433 |     QPixmap cache; | - | 
| 434 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size(), gtkWidget) % pmKey; | - | 
| 435 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 436 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_slider (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height(), orientation); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_slider (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height(), orientation); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 437 |                                                        ; | - | 
| 438 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 439 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 440 |     } never executed: end of block  | 0 | 
| 441 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 442 | } never executed: end of block  | 0 | 
| 443 |  | - | 
| 444 |  | - | 
| 445 | void QGtk2Painter::paintShadow(GtkWidget *gtkWidget, const gchar* part, | - | 
| 446 |                               const QRect &rect, GtkStateType state, | - | 
| 447 |                               GtkShadowType shadow, GtkStyle *style, | - | 
| 448 |                               const QString &pmKey) | - | 
| 449 |  | - | 
| 450 | { | - | 
| 451 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 452 |         return; never executed: return;  | 0 | 
| 453 |  | - | 
| 454 |     QPixmap cache; | - | 
| 455 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size()) % pmKey; | - | 
| 456 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 457 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_shadow(style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_shadow(style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 458 |                                                                                              ; | - | 
| 459 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 460 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 461 |     } never executed: end of block  | 0 | 
| 462 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 463 | } never executed: end of block  | 0 | 
| 464 |  | - | 
| 465 | void QGtk2Painter::paintFlatBox(GtkWidget *gtkWidget, const gchar* part, | - | 
| 466 |                                const QRect &rect, GtkStateType state, | - | 
| 467 |                                GtkShadowType shadow, GtkStyle *style, | - | 
| 468 |                                const QString &pmKey) | - | 
| 469 | { | - | 
| 470 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 471 |         return; never executed: return;  | 0 | 
| 472 |     QPixmap cache; | - | 
| 473 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size()) % pmKey; | - | 
| 474 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 475 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_flat_box (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_flat_box (style, pixmap, state, shadow, __null, gtkWidget, part, 0, 0, rect.width(), rect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 476 |  | - | 
| 477 |  | - | 
| 478 |  | - | 
| 479 |  | - | 
| 480 |  | - | 
| 481 |  | - | 
| 482 |  | - | 
| 483 |                                                            ; | - | 
| 484 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 485 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 486 |     } never executed: end of block  | 0 | 
| 487 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 488 | } never executed: end of block  | 0 | 
| 489 |  | - | 
| 490 | void QGtk2Painter::paintExtention(GtkWidget *gtkWidget, | - | 
| 491 |                                  const gchar *part, const QRect &rect, | - | 
| 492 |                                  GtkStateType state, GtkShadowType shadow, | - | 
| 493 |                                  GtkPositionType gap_pos, GtkStyle *style) | - | 
| 494 | { | - | 
| 495 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 496 |         return; never executed: return;  | 0 | 
| 497 |  | - | 
| 498 |     QPixmap cache; | - | 
| 499 |     QString pixmapName = uniqueName(QLatin1String(part), state, shadow, rect.size(), gtkWidget) | - | 
| 500 |                          % HexString<uchar>(gap_pos); | - | 
| 501 |  | - | 
| 502 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 503 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_extension (style, pixmap, state, shadow, __null, gtkWidget, (const gchar*)part, 0, 0, rect.width(), rect.height(), gap_pos); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_extension (style, pixmap, state, shadow, __null, gtkWidget, (const gchar*)part, 0, 0, rect.width(), rect.height(), gap_pos); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 504 |  | - | 
| 505 |  | - | 
| 506 |  | - | 
| 507 |  | - | 
| 508 |                                                       ; | - | 
| 509 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 510 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 511 |     } never executed: end of block  | 0 | 
| 512 |  | - | 
| 513 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 514 | } never executed: end of block  | 0 | 
| 515 |  | - | 
| 516 | void QGtk2Painter::paintOption(GtkWidget *gtkWidget, const QRect &radiorect, | - | 
| 517 |                               GtkStateType state, GtkShadowType shadow, | - | 
| 518 |                               GtkStyle *style, const QString &detail) | - | 
| 519 |  | - | 
| 520 | { | - | 
| 521 |     QRect rect = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? m_cliprect : radiorect; | 0 | 
| 522 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 523 |         return; never executed: return;  | 0 | 
| 524 |  | - | 
| 525 |     QPixmap cache; | - | 
| 526 |     QString pixmapName = uniqueName(detail, state, shadow, rect.size()); | - | 
| 527 |     GdkRectangle gtkCliprect = {0, 0, rect.width(), rect.height()}; | - | 
| 528 |     int xOffset = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? radiorect.x() - m_cliprect.x() : 0; | 0 | 
| 529 |     int yOffset = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? radiorect.y() - m_cliprect.y() : 0; | 0 | 
| 530 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 531 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_option(style, pixmap, state, shadow, >kCliprect, gtkWidget, detail.toLatin1(), xOffset, yOffset, radiorect.width(), radiorect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_option(style, pixmap, state, shadow, >kCliprect, gtkWidget, detail.toLatin1(), xOffset, yOffset, radiorect.width(), radiorect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 532 |  | - | 
| 533 |  | - | 
| 534 |  | - | 
| 535 |  | - | 
| 536 |  | - | 
| 537 |  | - | 
| 538 |                                                              ; | - | 
| 539 |  | - | 
| 540 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 541 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 542 |     } never executed: end of block  | 0 | 
| 543 |  | - | 
| 544 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 545 | } never executed: end of block  | 0 | 
| 546 |  | - | 
| 547 | void QGtk2Painter::paintCheckbox(GtkWidget *gtkWidget, const QRect &checkrect, | - | 
| 548 |                                 GtkStateType state, GtkShadowType shadow, | - | 
| 549 |                                 GtkStyle *style, const QString &detail) | - | 
| 550 |  | - | 
| 551 | { | - | 
| 552 |     QRect rect = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? m_cliprect : checkrect; | 0 | 
| 553 |     if (!rect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 554 |         return; never executed: return;  | 0 | 
| 555 |  | - | 
| 556 |     QPixmap cache; | - | 
| 557 |     QString pixmapName = uniqueName(detail, state, shadow, rect.size()); | - | 
| 558 |     GdkRectangle gtkCliprect = {0, 0, rect.width(), rect.height()}; | - | 
| 559 |     int xOffset = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? checkrect.x() - m_cliprect.x() : 0; | 0 | 
| 560 |     int yOffset = m_cliprect.isValid()| TRUE | never evaluated |  | FALSE | never evaluated |  
   ? checkrect.y() - m_cliprect.y() : 0; | 0 | 
| 561 |     if (!m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
   || !QPixmapCache::find(pixmapName, cache)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { | 0 | 
| 562 |         if (rect.width() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
   || rect.height() > ((1<<24)-1)| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  QRect pixmapRect(0, 0, rect.width(), rect.height()); { GdkPixmap *pixmap = QGtk2PainterPrivate::gdk_pixmap_new((GdkDrawable*)(m_window->window), rect.width(), rect.height(), -1); if (!pixmap| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  style = QGtkStylePrivate::gtk_style_attach (style, m_window->window); QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, m_alpha ? style->black_gc : *style->bg_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_check (style, pixmap, state, shadow, >kCliprect, gtkWidget, detail.toLatin1(), xOffset, yOffset, checkrect.width(), checkrect.height()); GdkPixbuf *imgb = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgb| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgb = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgb, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* bdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgb); if (m_alpha| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) { QGtk2PainterPrivate::gdk_draw_rectangle(pixmap, style->white_gc, true, 0, 0, rect.width(), rect.height()); QGtk2PainterPrivate::gtk_paint_check (style, pixmap, state, shadow, >kCliprect, gtkWidget, detail.toLatin1(), xOffset, yOffset, checkrect.width(), checkrect.height()); GdkPixbuf *imgw = QGtkStylePrivate::gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8, rect.width(), rect.height()); if (!imgw| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) return;never executed: return;  imgw = QGtk2PainterPrivate::gdk_pixbuf_get_from_drawable(imgw, pixmap, __null, 0, 0, 0, 0, rect.width(), rect.height()); uchar* wdata = (uchar*)QGtkStylePrivate::gdk_pixbuf_get_pixels(imgw); cache = renderTheme(bdata, wdata, rect); QGtkStylePrivate::gdk_pixbuf_unref(imgw); }never executed: end of block  else { cache = renderTheme(bdata, 0, rect); }never executed: end of block  QGtk2PainterPrivate::gdk_drawable_unref(pixmap); QGtkStylePrivate::gdk_pixbuf_unref(imgb); } | 0 | 
| 563 |                                                              ; | - | 
| 564 |         if (m_usePixmapCache| TRUE | never evaluated |  | FALSE | never evaluated |  
  ) | 0 | 
| 565 |             QPixmapCache::insert(pixmapName, cache); never executed: QPixmapCache::insert(pixmapName, cache);  | 0 | 
| 566 |     } never executed: end of block  | 0 | 
| 567 |  | - | 
| 568 |     m_painter->drawPixmap(rect.topLeft(), cache); | - | 
| 569 | } never executed: end of block  | 0 | 
| 570 |  | - | 
| 571 |  | - | 
 |  |  |