]> git.saurik.com Git - wxWidgets.git/commitdiff
More theme goodies.
authorRobert Roebling <robert@roebling.de>
Thu, 14 Sep 2000 09:08:18 +0000 (09:08 +0000)
committerRobert Roebling <robert@roebling.de>
Thu, 14 Sep 2000 09:08:18 +0000 (09:08 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@8358 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/listctrl.cpp
src/gtk/window.cpp
src/gtk1/window.cpp

index ad659482c86af6193efb895ce0d747e1cb22e21c..96af1ef03cb68c7fef80e9bb0b85c35ee61f1911 100644 (file)
@@ -1202,7 +1202,7 @@ void wxListHeaderWindow::DoDrawRect( wxDC *dc, int x, int y, int w, int h )
     x = dc->XLOG2DEV( x );
     
        gtk_paint_box (m_wxwindow->style, GTK_PIZZA(m_wxwindow)->bin_window, state, GTK_SHADOW_OUT,
-               (GdkRectangle*) NULL, m_wxwindow, "button", x, y, w+1, h+1);
+               (GdkRectangle*) NULL, m_wxwindow, "button", x-1, y-1, w+2, h+2);
 #else
     const int m_corner = 1;
 
index 9d8bd481a93b121b426372d742d8677198acf288..d216773c501d4b9ebe9655ab60014259b06072d5 100644 (file)
@@ -679,10 +679,18 @@ static int gtk_window_expose_callback( GtkWidget *widget, GdkEventExpose *gdk_ev
     }
 */
                                 
-        win->GetUpdateRegion().Union( gdk_event->area.x,
-                                      gdk_event->area.y,
-                                      gdk_event->area.width,
-                                      gdk_event->area.height );
+    GtkPizza *pizza = GTK_PIZZA (widget);
+        
+    if (win->IsTopLevel())
+    {
+        gtk_paint_flat_box (widget->style, pizza->bin_window, GTK_STATE_NORMAL, 
+                     GTK_SHADOW_NONE, &gdk_event->area, widget, "base", 0, 0, -1, -1);
+    }
+        
+    win->GetUpdateRegion().Union( gdk_event->area.x,
+                                  gdk_event->area.y,
+                                  gdk_event->area.width,
+                                  gdk_event->area.height );
 
         if (gdk_event->count == 0)
         {
@@ -702,8 +710,6 @@ static int gtk_window_expose_callback( GtkWidget *widget, GdkEventExpose *gdk_ev
            paint *anything* because it will then be allowed to paint
            over the window-less widgets */
        
-        GtkPizza *pizza = GTK_PIZZA (widget);
-        
         GList *children = pizza->children;
         while (children)
         {
@@ -776,6 +782,12 @@ static void gtk_window_draw_callback( GtkWidget *widget, GdkRectangle *rect, wxW
 */
    
     GtkPizza *pizza = GTK_PIZZA (widget);
+
+    if (win->IsTopLevel())
+    {
+        gtk_paint_flat_box (widget->style, pizza->bin_window, GTK_STATE_NORMAL, 
+                     GTK_SHADOW_NONE, rect, widget, "base", 0, 0, -1, -1);
+    }
         
         if (!(GTK_WIDGET_APP_PAINTABLE (widget)) &&
              (pizza->clear_on_draw))
index 9d8bd481a93b121b426372d742d8677198acf288..d216773c501d4b9ebe9655ab60014259b06072d5 100644 (file)
@@ -679,10 +679,18 @@ static int gtk_window_expose_callback( GtkWidget *widget, GdkEventExpose *gdk_ev
     }
 */
                                 
-        win->GetUpdateRegion().Union( gdk_event->area.x,
-                                      gdk_event->area.y,
-                                      gdk_event->area.width,
-                                      gdk_event->area.height );
+    GtkPizza *pizza = GTK_PIZZA (widget);
+        
+    if (win->IsTopLevel())
+    {
+        gtk_paint_flat_box (widget->style, pizza->bin_window, GTK_STATE_NORMAL, 
+                     GTK_SHADOW_NONE, &gdk_event->area, widget, "base", 0, 0, -1, -1);
+    }
+        
+    win->GetUpdateRegion().Union( gdk_event->area.x,
+                                  gdk_event->area.y,
+                                  gdk_event->area.width,
+                                  gdk_event->area.height );
 
         if (gdk_event->count == 0)
         {
@@ -702,8 +710,6 @@ static int gtk_window_expose_callback( GtkWidget *widget, GdkEventExpose *gdk_ev
            paint *anything* because it will then be allowed to paint
            over the window-less widgets */
        
-        GtkPizza *pizza = GTK_PIZZA (widget);
-        
         GList *children = pizza->children;
         while (children)
         {
@@ -776,6 +782,12 @@ static void gtk_window_draw_callback( GtkWidget *widget, GdkRectangle *rect, wxW
 */
    
     GtkPizza *pizza = GTK_PIZZA (widget);
+
+    if (win->IsTopLevel())
+    {
+        gtk_paint_flat_box (widget->style, pizza->bin_window, GTK_STATE_NORMAL, 
+                     GTK_SHADOW_NONE, rect, widget, "base", 0, 0, -1, -1);
+    }
         
         if (!(GTK_WIDGET_APP_PAINTABLE (widget)) &&
              (pizza->clear_on_draw))