Changeset 2305 for libcaca/trunk/caca/driver_x11.c
- Timestamp:
- Apr 19, 2008, 9:25:52 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcaca/trunk/caca/driver_x11.c
r2299 r2305 76 76 char const *fonts[] = { NULL, "8x13bold", "fixed" }, **parser; 77 77 char const *geometry; 78 unsignedint width = cucul_get_canvas_width(dp->cv);79 unsignedint height = cucul_get_canvas_height(dp->cv);78 int width = cucul_get_canvas_width(dp->cv); 79 int height = cucul_get_canvas_height(dp->cv); 80 80 int i; 81 81 … … 112 112 for( ; ; parser++) 113 113 { 114 u nsigned int font_max_char;114 uint32_t font_max_char; 115 115 116 116 if(!*parser) … … 144 144 145 145 font_max_char = 146 ( ((unsigned int)dp->drv.p->font_struct->max_byte1)<< 8)146 (dp->drv.p->font_struct->max_byte1 << 8) 147 147 | dp->drv.p->font_struct->max_char_or_byte2; 148 148 if(font_max_char && (font_max_char < dp->drv.p->max_char)) … … 278 278 } 279 279 280 static unsignedint x11_get_display_width(caca_display_t const *dp)280 static int x11_get_display_width(caca_display_t const *dp) 281 281 { 282 282 return cucul_get_canvas_width(dp->cv) * dp->drv.p->font_width; 283 283 } 284 284 285 static unsignedint x11_get_display_height(caca_display_t const *dp)285 static int x11_get_display_height(caca_display_t const *dp) 286 286 { 287 287 return cucul_get_canvas_height(dp->cv) * dp->drv.p->font_height; … … 292 292 uint32_t const *cvchars = (uint32_t const *)cucul_get_canvas_chars(dp->cv); 293 293 uint32_t const *cvattrs = (uint32_t const *)cucul_get_canvas_attrs(dp->cv); 294 unsignedint width = cucul_get_canvas_width(dp->cv);295 unsignedint height = cucul_get_canvas_height(dp->cv);296 unsignedint x, y, len;294 int width = cucul_get_canvas_width(dp->cv); 295 int height = cucul_get_canvas_height(dp->cv); 296 int x, y, len; 297 297 298 298 /* First draw the background colours. Splitting the process in two … … 323 323 for(y = 0; y < height; y++) 324 324 { 325 unsignedint yoff = (y + 1) * dp->drv.p->font_height325 int yoff = (y + 1) * dp->drv.p->font_height 326 326 - dp->drv.p->font_offset; 327 327 uint32_t const *chars = cvchars + y * width; … … 379 379 static int x11_get_event(caca_display_t *dp, caca_privevent_t *ev) 380 380 { 381 unsignedint width = cucul_get_canvas_width(dp->cv);382 unsignedint height = cucul_get_canvas_height(dp->cv);381 int width = cucul_get_canvas_width(dp->cv); 382 int height = cucul_get_canvas_height(dp->cv); 383 383 XEvent xevent; 384 384 char key; … … 402 402 if(xevent.type == ConfigureNotify) 403 403 { 404 unsignedint w, h;404 int w, h; 405 405 406 406 w = (xevent.xconfigure.width + dp->drv.p->font_width / 3) … … 422 422 if(xevent.type == MotionNotify) 423 423 { 424 unsignedint newx = xevent.xmotion.x / dp->drv.p->font_width;425 unsignedint newy = xevent.xmotion.y / dp->drv.p->font_height;424 int newx = xevent.xmotion.x / dp->drv.p->font_width; 425 int newy = xevent.xmotion.y / dp->drv.p->font_height; 426 426 427 427 if(newx >= width)
Note: See TracChangeset
for help on using the changeset viewer.