Mercurial > dwindows
comparison dwtest.c @ 1461:09323eb9dc32
Clear the side pixmap on configure so there won't sometimes be garbage there.
author | bsmith@81767d24-ef19-dc11-ae90-00e081727c95 |
---|---|
date | Thu, 15 Dec 2011 23:30:50 +0000 |
parents | da9cd5da3440 |
children | 77f530f95826 |
comparison
equal
deleted
inserted
replaced
1460:da9cd5da3440 | 1461:09323eb9dc32 |
---|---|
389 /* If we aren't drawing direct do a bitblt */ | 389 /* If we aren't drawing direct do a bitblt */ |
390 if(!direct && !hpma) | 390 if(!direct && !hpma) |
391 { | 391 { |
392 text_expose( textbox2, NULL, NULL); | 392 text_expose( textbox2, NULL, NULL); |
393 } | 393 } |
394 /* Make sure the side area is cleared too */ | |
395 dw_color_foreground_set(DW_CLR_BLACK); | |
396 dw_draw_rect(textbox1, 0, DW_DRAW_FILL, 0, 0, DW_PIXMAP_WIDTH(text1pm), DW_PIXMAP_HEIGHT(text1pm)); | |
397 } | 394 } |
398 | 395 |
399 void update_render(void) | 396 void update_render(void) |
400 { | 397 { |
401 switch(render_type) | 398 switch(render_type) |
704 | 701 |
705 /* Create new pixmaps with the current sizes */ | 702 /* Create new pixmaps with the current sizes */ |
706 text1pm = dw_pixmap_new(textbox1, (unsigned long)(font_width*(width1)), (unsigned long)height, (int)depth); | 703 text1pm = dw_pixmap_new(textbox1, (unsigned long)(font_width*(width1)), (unsigned long)height, (int)depth); |
707 text2pm = dw_pixmap_new(textbox2, (unsigned long)width, (unsigned long)height, (int)depth); | 704 text2pm = dw_pixmap_new(textbox2, (unsigned long)width, (unsigned long)height, (int)depth); |
708 | 705 |
709 /* Destroy the old pixmaps */ | 706 /* Make sure the side area is cleared */ |
707 dw_color_foreground_set(DW_CLR_WHITE); | |
708 dw_draw_rect(0, text1pm, DW_DRAW_FILL, 0, 0, DW_PIXMAP_WIDTH(text1pm), DW_PIXMAP_HEIGHT(text1pm)); | |
709 | |
710 /* Destroy the old pixmaps */ | |
710 dw_pixmap_destroy(old1); | 711 dw_pixmap_destroy(old1); |
711 dw_pixmap_destroy(old2); | 712 dw_pixmap_destroy(old2); |
712 | 713 |
713 /* Update scrollbar ranges with new values */ | 714 /* Update scrollbar ranges with new values */ |
714 dw_scrollbar_set_range(hscrollbar, max_linewidth, cols); | 715 dw_scrollbar_set_range(hscrollbar, max_linewidth, cols); |