Changes in uspace/lib/draw/font/pcf.c [b7fd2a0:d5c1051] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/draw/font/pcf.c
rb7fd2a0 rd5c1051 146 146 } 147 147 148 static errno_t pcf_resolve_glyph(void *opaque_data, const wchar_t chr,148 static int pcf_resolve_glyph(void *opaque_data, const wchar_t chr, 149 149 glyph_id_t *glyph_id) 150 150 { … … 183 183 } 184 184 185 static errno_t load_glyph_metrics(pcf_data_t *data, uint32_t glyph_id,185 static int load_glyph_metrics(pcf_data_t *data, uint32_t glyph_id, 186 186 pcf_toc_entry_t *table, pcf_default_metrics_t *metrics) 187 187 { … … 253 253 } 254 254 255 static errno_t pcf_load_glyph_surface(void *opaque_data, glyph_id_t glyph_id,255 static int pcf_load_glyph_surface(void *opaque_data, glyph_id_t glyph_id, 256 256 surface_t **out_surface) 257 257 { … … 260 260 pcf_default_metrics_t pcf_metrics; 261 261 memset(&pcf_metrics, 0, sizeof(pcf_default_metrics_t)); 262 errno_t rc = load_glyph_metrics(data, glyph_id, &data->metrics_table,262 int rc = load_glyph_metrics(data, glyph_id, &data->metrics_table, 263 263 &pcf_metrics); 264 264 if (rc != EOK) … … 339 339 } 340 340 341 static errno_t pcf_load_glyph_metrics(void *opaque_data, glyph_id_t glyph_id,341 static int pcf_load_glyph_metrics(void *opaque_data, glyph_id_t glyph_id, 342 342 glyph_metrics_t *gm) 343 343 { … … 346 346 pcf_default_metrics_t pcf_metrics; 347 347 memset(&pcf_metrics, 0, sizeof(pcf_default_metrics_t)); 348 errno_t rc = load_glyph_metrics(data, glyph_id, &data->metrics_table,348 int rc = load_glyph_metrics(data, glyph_id, &data->metrics_table, 349 349 &pcf_metrics); 350 350 if (rc != EOK) … … 377 377 }; 378 378 379 static errno_t pcf_read_toc(pcf_data_t *data)379 static int pcf_read_toc(pcf_data_t *data) 380 380 { 381 381 int rc = fseek(data->file, 0, SEEK_END); … … 460 460 } 461 461 462 static errno_t pcf_seek_table_header(pcf_data_t *data, pcf_toc_entry_t *table)462 static int pcf_seek_table_header(pcf_data_t *data, pcf_toc_entry_t *table) 463 463 { 464 464 uint32_t format; … … 478 478 } 479 479 480 static errno_t pcf_read_bitmap_table_header(pcf_data_t *data)481 { 482 errno_t rc = pcf_seek_table_header(data, &data->bitmap_table);480 static int pcf_read_bitmap_table_header(pcf_data_t *data) 481 { 482 int rc = pcf_seek_table_header(data, &data->bitmap_table); 483 483 if (rc != EOK) 484 484 return rc; … … 498 498 } 499 499 500 static errno_t pcf_read_metrics_table_header(pcf_data_t *data)501 { 502 errno_t rc = pcf_seek_table_header(data, &data->metrics_table);500 static int pcf_read_metrics_table_header(pcf_data_t *data) 501 { 502 int rc = pcf_seek_table_header(data, &data->metrics_table); 503 503 if (rc != EOK) 504 504 return rc; … … 531 531 } 532 532 533 static errno_t pcf_read_encodings_table_header(pcf_data_t *data)534 { 535 errno_t rc = pcf_seek_table_header(data, &data->encodings_table);533 static int pcf_read_encodings_table_header(pcf_data_t *data) 534 { 535 int rc = pcf_seek_table_header(data, &data->encodings_table); 536 536 if (rc != EOK) 537 537 return rc; … … 558 558 } 559 559 560 static errno_t pcf_read_accelerators_table(pcf_data_t *data)561 { 562 errno_t rc = pcf_seek_table_header(data, &data->accelerators_table);560 static int pcf_read_accelerators_table(pcf_data_t *data) 561 { 562 int rc = pcf_seek_table_header(data, &data->accelerators_table); 563 563 if (rc != EOK) 564 564 return rc; … … 579 579 } 580 580 581 errno_t pcf_font_create(font_t **font, char *filename, uint16_t points)582 { 583 errno_t rc;581 int pcf_font_create(font_t **font, char *filename, uint16_t points) 582 { 583 int rc; 584 584 pcf_data_t *data = malloc(sizeof(pcf_data_t)); 585 585 if (data == NULL)
Note:
See TracChangeset
for help on using the changeset viewer.