Changeset 313ac8e in mainline for uspace/lib/gfxfont/test
- Timestamp:
- 2020-09-17T15:28:03Z (5 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 7bef2d8
- Parents:
- 414020d9
- Location:
- uspace/lib/gfxfont/test
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/gfxfont/test/font.c
r414020d9 r313ac8e 332 332 gfx_glyph_t *glyph; 333 333 gfx_context_t *gc; 334 gfx_rect_t nrect; 334 335 test_gc_t tgc; 335 336 errno_t rc; … … 350 351 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 351 352 352 rc = gfx_font_splice_at_glyph(font, glyph, 10, 10); 353 nrect.p0.x = -5; 354 nrect.p0.y = -5; 355 nrect.p1.x = 5; 356 nrect.p1.y = 5; 357 rc = gfx_font_splice_at_glyph(font, glyph, &nrect); 353 358 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 354 359 -
uspace/lib/gfxfont/test/glyph_bmp.c
r414020d9 r313ac8e 185 185 PCUT_ASSERT_INT_EQUALS(0, pix); 186 186 187 gfx_glyph_bmp_close(bmp); 187 /* ... */ 188 189 rc = gfx_glyph_bmp_setpix(bmp, 1, -1, 1); 190 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 191 192 rc = gfx_glyph_bmp_save(bmp); 193 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 194 195 gfx_glyph_bmp_close(bmp); 196 197 /* Once again */ 198 199 rc = gfx_glyph_bmp_open(glyph, &bmp); 200 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 201 PCUT_ASSERT_NOT_NULL(bmp); 202 203 pix = gfx_glyph_bmp_getpix(bmp, 0, 0); 204 PCUT_ASSERT_INT_EQUALS(1, pix); 205 206 pix = gfx_glyph_bmp_getpix(bmp, 1, 1); 207 PCUT_ASSERT_INT_EQUALS(1, pix); 208 209 pix = gfx_glyph_bmp_getpix(bmp, 1, 0); 210 PCUT_ASSERT_INT_EQUALS(0, pix); 211 212 pix = gfx_glyph_bmp_getpix(bmp, 0, 1); 213 PCUT_ASSERT_INT_EQUALS(0, pix); 214 215 pix = gfx_glyph_bmp_getpix(bmp, 1, -1); 216 PCUT_ASSERT_INT_EQUALS(1, pix); 217 218 pix = gfx_glyph_bmp_getpix(bmp, 0, -1); 219 PCUT_ASSERT_INT_EQUALS(0, pix); 220 188 221 gfx_glyph_destroy(glyph); 189 222
Note:
See TracChangeset
for help on using the changeset viewer.