Changeset 946 for libcaca/trunk/cucul/import.c
- Timestamp:
- May 9, 2006, 3:57:47 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcaca/trunk/cucul/import.c
r920 r946 244 244 cucul_canvas_t *cv; 245 245 unsigned int i, j, skip, dummy = 0; 246 unsigned int width = 80, height = 25;246 unsigned int width = 1, height = 1; 247 247 int x = 0, y = 0, save_x = 0, save_y = 0; 248 248 … … 263 263 264 264 /* Wrap long lines */ 265 if((unsigned int)x >= width)265 if((unsigned int)x >= 80) 266 266 { 267 267 x = 0; … … 380 380 break; 381 381 case 'K': /* EL - Erase In Line */ 382 for(j = x; j < width; j++) 382 if(width < 80) 383 cucul_set_canvas_size(cv, width = 80, height); 384 for(j = x; j < 80; j++) 383 385 _cucul_putchar32(cv, j, y, (uint32_t)' '); 384 x = width;386 x = 80; 385 387 break; 386 388 case 'm': /* SGR - Select Graphic Rendition */ … … 397 399 /* We're going to paste a character. First make sure the canvas 398 400 * is big enough. */ 401 if((unsigned int)x >= width) 402 cucul_set_canvas_size(cv, width = x + 1, height); 403 399 404 if((unsigned int)y >= height) 400 { 401 height = y + 1; 402 cucul_set_canvas_size(cv, width, height); 403 } 405 cucul_set_canvas_size(cv, width, height = y + 1); 404 406 405 407 /* Now paste our character */
Note: See TracChangeset
for help on using the changeset viewer.