Removed some debug code.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@6197 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -342,6 +342,7 @@ void wxListLineData::CalculateSize( wxDC *dc, int spacing )
|
||||
if (s.IsNull()) s = "H";
|
||||
wxCoord lw,lh;
|
||||
dc->GetTextExtent( s, &lw, &lh );
|
||||
if (lh < 15) lh = 15;
|
||||
item->SetSize( item->GetWidth(), lh );
|
||||
m_bound_all.width += lw;
|
||||
m_bound_all.height = lh;
|
||||
@@ -440,6 +441,7 @@ void wxListLineData::SetPosition( wxDC *dc, int x, int y, int window_width )
|
||||
{
|
||||
wxCoord lw,lh;
|
||||
dc->GetTextExtent( "H", &lw, &lh );
|
||||
if (lh < 15) lh = 15;
|
||||
m_bound_all.x = 0;
|
||||
m_bound_all.y -= 0;
|
||||
m_bound_all.height = lh+3;
|
||||
@@ -456,6 +458,7 @@ void wxListLineData::SetPosition( wxDC *dc, int x, int y, int window_width )
|
||||
if (s.IsEmpty()) s = wxT("H");
|
||||
wxCoord lw,lh;
|
||||
dc->GetTextExtent( s, &lw, &lh );
|
||||
if (lh < 15) lh = 15;
|
||||
m_bound_label.width = lw;
|
||||
m_bound_label.height = lh;
|
||||
if (item->HasImage())
|
||||
@@ -676,7 +679,6 @@ void wxListLineData::DoDraw( wxDC *dc, bool hilight, bool paintBG )
|
||||
while (node)
|
||||
{
|
||||
wxListItemData *item = (wxListItemData*)node->Data();
|
||||
dc->SetClippingRegion( item->GetX(), item->GetY(), item->GetWidth()-3, item->GetHeight() );
|
||||
int x = item->GetX();
|
||||
if (item->HasImage())
|
||||
{
|
||||
@@ -685,9 +687,10 @@ void wxListLineData::DoDraw( wxDC *dc, bool hilight, bool paintBG )
|
||||
m_owner->GetImageSize( item->GetImage(), x, y );
|
||||
x += item->GetX() + 5;
|
||||
}
|
||||
dc->SetClippingRegion( item->GetX(), item->GetY(), item->GetWidth()-3, item->GetHeight() );
|
||||
if (item->HasText())
|
||||
{
|
||||
dc->DrawText( item->GetText(), x, item->GetY() );
|
||||
dc->DrawText( item->GetText(), x, item->GetY()+1 );
|
||||
}
|
||||
dc->DestroyClippingRegion();
|
||||
node = node->Next();
|
||||
@@ -883,9 +886,9 @@ void wxListHeaderWindow::OnPaint( wxPaintEvent &WXUNUSED(event) )
|
||||
dc.SetPen( *wxWHITE_PEN );
|
||||
|
||||
DoDrawRect( &dc, x, y, cw, h-2 );
|
||||
// dc.SetClippingRegion( x, y, cw-5, h-4 );
|
||||
dc.SetClippingRegion( x, y, cw-5, h-4 );
|
||||
dc.DrawText( item.m_text, x+4, y+3 );
|
||||
// dc.DestroyClippingRegion();
|
||||
dc.DestroyClippingRegion();
|
||||
x += item.m_width;
|
||||
#if wxUSE_GENERIC_LIST_EXTENSIONS
|
||||
if (dc.LogicalToDeviceX(x) > w+5) break;
|
||||
|
@@ -667,6 +667,14 @@ void wxWindowDC::DoDrawBitmap( const wxBitmap &bitmap,
|
||||
gdk_gc_set_fill( gc, GDK_OPAQUE_STIPPLED );
|
||||
gdk_gc_set_stipple( gc, mask );
|
||||
gdk_draw_rectangle( new_mask, gc, TRUE, 0, 0, ww, hh );
|
||||
/*
|
||||
gdk_gc_set_clip_mask( m_brushGC, NULL );
|
||||
gdk_gc_set_clip_mask( m_textGC, NULL );
|
||||
SetBrush( *wxRED_BRUSH );
|
||||
DrawRectangle( 70, 0, 70, 1000 );
|
||||
gdk_draw_bitmap( m_window, m_textGC, new_mask, 0, 0, 100, 5, ww, hh );
|
||||
gdk_draw_bitmap( m_window, m_textGC, mask, 0, 0, 80, 5, ww, hh );
|
||||
*/
|
||||
gdk_gc_unref( gc );
|
||||
}
|
||||
|
||||
|
@@ -612,6 +612,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
|
||||
{
|
||||
DEBUG_MAIN_THREAD
|
||||
|
||||
/*
|
||||
if (win->GetName() == wxT("columntitles"))
|
||||
{
|
||||
wxPrintf( wxT("OnExpose from ") );
|
||||
@@ -622,6 +623,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
|
||||
(int)gdk_event->area.width,
|
||||
(int)gdk_event->area.height );
|
||||
}
|
||||
*/
|
||||
|
||||
win->GetUpdateRegion().Union( gdk_event->area.x,
|
||||
gdk_event->area.y,
|
||||
@@ -661,6 +663,7 @@ static void gtk_window_draw_callback( GtkWidget *WXUNUSED(widget),
|
||||
if ((rect->x == 0) && (rect->y == 0) && (rect->width <= 1) && (rect->height <= 1))
|
||||
return;
|
||||
|
||||
/*
|
||||
if (win->GetName() == wxT("columntitles"))
|
||||
{
|
||||
wxPrintf( wxT("OnDraw from ") );
|
||||
@@ -671,6 +674,7 @@ static void gtk_window_draw_callback( GtkWidget *WXUNUSED(widget),
|
||||
(int)rect->width,
|
||||
(int)rect->height );
|
||||
}
|
||||
*/
|
||||
|
||||
win->GetUpdateRegion().Union( rect->x, rect->y,
|
||||
rect->width, rect->height );
|
||||
|
@@ -667,6 +667,14 @@ void wxWindowDC::DoDrawBitmap( const wxBitmap &bitmap,
|
||||
gdk_gc_set_fill( gc, GDK_OPAQUE_STIPPLED );
|
||||
gdk_gc_set_stipple( gc, mask );
|
||||
gdk_draw_rectangle( new_mask, gc, TRUE, 0, 0, ww, hh );
|
||||
/*
|
||||
gdk_gc_set_clip_mask( m_brushGC, NULL );
|
||||
gdk_gc_set_clip_mask( m_textGC, NULL );
|
||||
SetBrush( *wxRED_BRUSH );
|
||||
DrawRectangle( 70, 0, 70, 1000 );
|
||||
gdk_draw_bitmap( m_window, m_textGC, new_mask, 0, 0, 100, 5, ww, hh );
|
||||
gdk_draw_bitmap( m_window, m_textGC, mask, 0, 0, 80, 5, ww, hh );
|
||||
*/
|
||||
gdk_gc_unref( gc );
|
||||
}
|
||||
|
||||
|
@@ -612,6 +612,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
|
||||
{
|
||||
DEBUG_MAIN_THREAD
|
||||
|
||||
/*
|
||||
if (win->GetName() == wxT("columntitles"))
|
||||
{
|
||||
wxPrintf( wxT("OnExpose from ") );
|
||||
@@ -622,6 +623,7 @@ static void gtk_window_expose_callback( GtkWidget *WXUNUSED(widget), GdkEventExp
|
||||
(int)gdk_event->area.width,
|
||||
(int)gdk_event->area.height );
|
||||
}
|
||||
*/
|
||||
|
||||
win->GetUpdateRegion().Union( gdk_event->area.x,
|
||||
gdk_event->area.y,
|
||||
@@ -661,6 +663,7 @@ static void gtk_window_draw_callback( GtkWidget *WXUNUSED(widget),
|
||||
if ((rect->x == 0) && (rect->y == 0) && (rect->width <= 1) && (rect->height <= 1))
|
||||
return;
|
||||
|
||||
/*
|
||||
if (win->GetName() == wxT("columntitles"))
|
||||
{
|
||||
wxPrintf( wxT("OnDraw from ") );
|
||||
@@ -671,6 +674,7 @@ static void gtk_window_draw_callback( GtkWidget *WXUNUSED(widget),
|
||||
(int)rect->width,
|
||||
(int)rect->height );
|
||||
}
|
||||
*/
|
||||
|
||||
win->GetUpdateRegion().Union( rect->x, rect->y,
|
||||
rect->width, rect->height );
|
||||
|
Reference in New Issue
Block a user