+ if (m_window && m_window->GetBackingPixmap())
+ {
+ XFillRectangle ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + rd2, yd2, wd2 - rw_d2, hd2);
+ XFillRectangle ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2, yd2 + rd2, wd2, hd2 - rh_d2);
+
+ XFillArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2, yd2, rw_d2, rh_d2, 90 * 64, 90 * 64);
+ XFillArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + wd2 - rw_d2, yd2,
+ // rw_d2, rh_d2, 0, 90 * 64);
+ rw_d2, rh_d2, 0, 91 * 64);
+ XFillArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + wd2 - rw_d2,
+ yd2 + hd2 - rh_d2,
+ // rw_d2, rh_d2, 270 * 64, 90 * 64);
+ rw_d2, rh_d2, 269 * 64, 92 * 64);
+ XFillArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2, yd2 + hd2 - rh_d2,
+ rw_d2, rh_d2, 180 * 64, 90 * 64);
+ }
+ }
+
+ if (m_pen.IsOk() && m_pen.GetStyle () != wxTRANSPARENT)
+ {
+ SetPen (m_pen);
+ XDrawLine ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd + rd, yd,
+ xd + wd - rd + 1, yd);
+ XDrawLine ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd + rd, yd + hd,
+ xd + wd - rd, yd + hd);
+
+ XDrawLine ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd, yd + rd,
+ xd, yd + hd - rd);
+ XDrawLine ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd + wd, yd + rd,
+ xd + wd, yd + hd - rd + 1);
+ XDrawArc ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd, yd,
+ rw_d, rh_d, 90 * 64, 90 * 64);
+ XDrawArc ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd + wd - rw_d, yd,
+ // rw_d, rh_d, 0, 90 * 64);
+ rw_d, rh_d, 0, 91 * 64);
+ XDrawArc ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd + wd - rw_d,
+ yd + hd - rh_d,
+ rw_d, rh_d, 269 * 64, 92 * 64);
+ XDrawArc ((Display*) m_display, (Pixmap) m_pixmap, (GC) m_gc, xd, yd + hd - rh_d,
+ rw_d, rh_d, 180 * 64, 90 * 64);
+
+ if (m_window && m_window->GetBackingPixmap())
+ {
+ XDrawLine ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + rd2, yd2,
+ xd2 + wd2 - rd2 + 1, yd2);
+ XDrawLine ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + rd2, yd2 + hd2,
+ xd2 + wd2 - rd2, yd2 + hd2);
+
+ XDrawLine ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2, yd2 + rd2,
+ xd2, yd2 + hd2 - rd2);
+ XDrawLine ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + wd2, yd2 + rd2,
+ xd2 + wd2, yd2 + hd2 - rd2 + 1);
+ XDrawArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2, yd2,
+ rw_d2, rh_d2, 90 * 64, 90 * 64);
+ XDrawArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + wd2 - rw_d2, yd2,
+ // rw_d2, rh_d2, 0, 90 * 64);
+ rw_d2, rh_d2, 0, 91 * 64);
+ XDrawArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2 + wd2 - rw_d2,
+ yd2 + hd2 - rh_d2,
+ rw_d2, rh_d2, 269 * 64, 92 * 64);
+ XDrawArc ((Display*) m_display, (Pixmap) m_window->GetBackingPixmap(),(GC) m_gcBacking,
+ xd2, yd2 + hd2 - rh_d2,
+ rw_d2, rh_d2, 180 * 64, 90 * 64);
+ }
+ }
+ CalcBoundingBox (x, y);
+ CalcBoundingBox (x + width, y + height);
+}
+
+void wxWindowDCImpl::DoDrawEllipse( wxCoord x, wxCoord y, wxCoord width, wxCoord height )
+{
+ wxCHECK_RET( IsOk(), "invalid dc" );
+
+ // Check for negative width and height
+ if (height < 0)