Changeset 9805cde in mainline for uspace/srv/fb/ega.c
- Timestamp:
- 2009-01-01T13:31:23Z (16 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 7122bc7
- Parents:
- 666773c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified uspace/srv/fb/ega.c ¶
r666773c r9805cde 50 50 #include <ipc/services.h> 51 51 #include <libarch/ddi.h> 52 #include <console/style.h> 53 #include <console/color.h> 52 54 53 55 #include "ega.h" … … 65 67 #define EGA_IO_SIZE 2 66 68 67 int ega_normal_color =0x0f;68 int ega_inverted_color =0xf0;69 int ega_normal_color = 0x0f; 70 int ega_inverted_color = 0xf0; 69 71 70 72 #define NORMAL_COLOR ega_normal_color … … 155 157 for (i = 0; i < scr_width * scr_height; i++) { 156 158 scr_addr[i * 2] = data[i].character; 159 /* FIXME 157 160 scr_addr[i * 2 + 1] = EGA_STYLE(data[i].style.fg_color, 158 161 data[i].style.bg_color); 162 */ 159 163 } 160 164 } … … 276 280 break; 277 281 case FB_SET_STYLE: 282 retval = 0; 283 switch (IPC_GET_ARG1(call)) { 284 case STYLE_NORMAL: style = INVERTED_COLOR; break; 285 case STYLE_EMPHASIS: style = INVERTED_COLOR | 4; break; 286 default: retval = EINVAL; 287 } 288 break; 289 case FB_SET_COLOR: 290 fgcolor = IPC_GET_ARG1(call); 291 bgcolor = IPC_GET_ARG2(call); 292 style = (fgcolor & 7) | ((bgcolor & 7) << 4); 293 if (IPC_GET_ARG3(call) & CATTR_BRIGHT) 294 style = style | 0x08; 295 retval = 0; 296 break; 297 case FB_SET_RGB_COLOR: 278 298 fgcolor = IPC_GET_ARG1(call); 279 299 bgcolor = IPC_GET_ARG2(call); … … 318 338 if(sysinfo_value("fb.blinking")) 319 339 { 320 ega_normal_color &=0x77;321 ega_inverted_color &=0x77;340 ega_normal_color &= 0x77; 341 ega_inverted_color &= 0x77; 322 342 } 323 343 style = NORMAL_COLOR;
Note:
See TracChangeset
for help on using the changeset viewer.