Changeset a9bd960c in mainline for console/screenbuffer.c
- Timestamp:
- 2006-06-02T17:46:21Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- e87e18f
- Parents:
- f1b4e74
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
console/screenbuffer.c
rf1b4e74 ra9bd960c 31 31 #include <unistd.h> 32 32 33 /** Get field from buffer that corresponds to character at position x,y at screen 34 * 33 /** Store one character to screenbuffer. Its position is determined by scr->position_x and scr->position_y. 34 * @param scr screenbuffer 35 * @param c stored character 35 36 */ 36 37 int screenbuffer_putchar(screenbuffer_t *scr, char c) 37 void screenbuffer_putchar(screenbuffer_t *scr, char c) 38 38 { 39 39 keyfield_t *field; … … 43 43 field->character = c; 44 44 field->style = scr->style; 45 46 return 1;47 45 } 48 46 47 /** Initilize screenbuffer. Allocate space for screen content in accordance to given size. 48 * @param scr initialized screenbuffer 49 * @param size_x 50 * @param size_y 51 */ 49 52 screenbuffer_t *screenbuffer_init(screenbuffer_t *scr, int size_x, int size_y) 50 53 { … … 103 106 { 104 107 scr->position_x = x % scr->size_x; 105 scr->position_y = y 108 scr->position_y = y % scr->size_y; 106 109 } 107 110 111 void screenbuffer_set_style(screenbuffer_t *scr, unsigned int fg_color, unsigned int bg_color) 112 { 113 scr->style.fg_color = fg_color; 114 scr->style.bg_color = bg_color; 115 } 116
Note:
See TracChangeset
for help on using the changeset viewer.