| OLD | NEW |
| 1 | 1 |
| 2 #line 1 "../../src/hb-buffer-deserialize-text.rl" | 2 #line 1 "../../src/hb-buffer-deserialize-text.rl" |
| 3 /* | 3 /* |
| 4 * Copyright © 2013 Google, Inc. | 4 * Copyright © 2013 Google, Inc. |
| 5 * | 5 * |
| 6 * This is part of HarfBuzz, a text shaping library. | 6 * This is part of HarfBuzz, a text shaping library. |
| 7 * | 7 * |
| 8 * Permission is hereby granted, without written agreement and without | 8 * Permission is hereby granted, without written agreement and without |
| 9 * license or royalty fees, to use, copy, modify, and distribute this | 9 * license or royalty fees, to use, copy, modify, and distribute this |
| 10 * software and its documentation for any purpose, provided that the | 10 * software and its documentation for any purpose, provided that the |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 * | 25 * |
| 26 * Google Author(s): Behdad Esfahbod | 26 * Google Author(s): Behdad Esfahbod |
| 27 */ | 27 */ |
| 28 | 28 |
| 29 #ifndef HB_BUFFER_DESERIALIZE_TEXT_HH | 29 #ifndef HB_BUFFER_DESERIALIZE_TEXT_HH |
| 30 #define HB_BUFFER_DESERIALIZE_TEXT_HH | 30 #define HB_BUFFER_DESERIALIZE_TEXT_HH |
| 31 | 31 |
| 32 #include "hb-private.hh" | 32 #include "hb-private.hh" |
| 33 | 33 |
| 34 | 34 |
| 35 #line 36 "hb-buffer-deserialize-text.hh.tmp" | 35 #line 36 "../../src/hb-buffer-deserialize-text.hh" |
| 36 static const unsigned char _deserialize_text_trans_keys[] = { | 36 static const unsigned char _deserialize_text_trans_keys[] = { |
| 37 0u, 0u, 9u, 122u, 45u, 57u, 48u, 57u, 45u, 57u, 48u, 57u, 48u, 57u, 45u,
57u, | 37 0u, 0u, 9u, 122u, 45u, 57u, 48u, 57u, 45u, 57u, 48u, 57u, 48u, 57u, 45u,
57u, |
| 38 48u, 57u, 44u, 44u, 45u, 57u, 48u, 57u, 44u, 57u, 9u, 124u, 9u, 124u, 0u
, 0u, | 38 48u, 57u, 44u, 44u, 45u, 57u, 48u, 57u, 44u, 57u, 9u, 124u, 9u, 124u, 0u
, 0u, |
| 39 9u, 122u, 9u, 124u, 9u, 124u, 9u, 124u, 9u, 124u, 9u, 124u, 9u, 124u, 9u
, 124u, | 39 9u, 122u, 9u, 124u, 9u, 124u, 9u, 124u, 9u, 124u, 9u, 124u, 9u, 124u, 9u
, 124u, |
| 40 9u, 124u, 9u, 124u, 9u, 124u, 0 | 40 9u, 124u, 9u, 124u, 9u, 124u, 0 |
| 41 }; | 41 }; |
| 42 | 42 |
| 43 static const char _deserialize_text_key_spans[] = { | 43 static const char _deserialize_text_key_spans[] = { |
| 44 0, 114, 13, 10, 13, 10, 10, 13, | 44 0, 114, 13, 10, 13, 10, 10, 13, |
| 45 10, 1, 13, 10, 14, 116, 116, 0, | 45 10, 1, 13, 10, 14, 116, 116, 0, |
| (...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 332 if (p < pe && *p == (buffer->len ? '|' : '[')) | 332 if (p < pe && *p == (buffer->len ? '|' : '[')) |
| 333 { | 333 { |
| 334 *end_ptr = ++p; | 334 *end_ptr = ++p; |
| 335 } | 335 } |
| 336 | 336 |
| 337 const char *eof = pe, *tok = NULL; | 337 const char *eof = pe, *tok = NULL; |
| 338 int cs; | 338 int cs; |
| 339 hb_glyph_info_t info; | 339 hb_glyph_info_t info; |
| 340 hb_glyph_position_t pos; | 340 hb_glyph_position_t pos; |
| 341 | 341 |
| 342 #line 343 "hb-buffer-deserialize-text.hh.tmp" | 342 #line 343 "../../src/hb-buffer-deserialize-text.hh" |
| 343 { | 343 { |
| 344 cs = deserialize_text_start; | 344 cs = deserialize_text_start; |
| 345 } | 345 } |
| 346 | 346 |
| 347 #line 348 "hb-buffer-deserialize-text.hh.tmp" | 347 #line 348 "../../src/hb-buffer-deserialize-text.hh" |
| 348 { | 348 { |
| 349 int _slen; | 349 int _slen; |
| 350 int _trans; | 350 int _trans; |
| 351 const unsigned char *_keys; | 351 const unsigned char *_keys; |
| 352 const char *_inds; | 352 const char *_inds; |
| 353 if ( p == pe ) | 353 if ( p == pe ) |
| 354 goto _test_eof; | 354 goto _test_eof; |
| 355 if ( cs == 0 ) | 355 if ( cs == 0 ) |
| 356 goto _out; | 356 goto _out; |
| 357 _resume: | 357 _resume: |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 469 { if (!parse_int (tok, p, &pos.y_advance)) return false; } | 469 { if (!parse_int (tok, p, &pos.y_advance)) return false; } |
| 470 #line 43 "../../src/hb-buffer-deserialize-text.rl" | 470 #line 43 "../../src/hb-buffer-deserialize-text.rl" |
| 471 { | 471 { |
| 472 buffer->add_info (info); | 472 buffer->add_info (info); |
| 473 if (buffer->in_error) | 473 if (buffer->in_error) |
| 474 return false; | 474 return false; |
| 475 buffer->pos[buffer->len - 1] = pos; | 475 buffer->pos[buffer->len - 1] = pos; |
| 476 *end_ptr = p; | 476 *end_ptr = p; |
| 477 } | 477 } |
| 478 break; | 478 break; |
| 479 #line 480 "hb-buffer-deserialize-text.hh.tmp" | 479 #line 480 "../../src/hb-buffer-deserialize-text.hh" |
| 480 } | 480 } |
| 481 | 481 |
| 482 _again: | 482 _again: |
| 483 if ( cs == 0 ) | 483 if ( cs == 0 ) |
| 484 goto _out; | 484 goto _out; |
| 485 if ( ++p != pe ) | 485 if ( ++p != pe ) |
| 486 goto _resume; | 486 goto _resume; |
| 487 _test_eof: {} | 487 _test_eof: {} |
| 488 if ( p == eof ) | 488 if ( p == eof ) |
| 489 { | 489 { |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 546 { if (!parse_int (tok, p, &pos.y_advance)) return false; } | 546 { if (!parse_int (tok, p, &pos.y_advance)) return false; } |
| 547 #line 43 "../../src/hb-buffer-deserialize-text.rl" | 547 #line 43 "../../src/hb-buffer-deserialize-text.rl" |
| 548 { | 548 { |
| 549 buffer->add_info (info); | 549 buffer->add_info (info); |
| 550 if (buffer->in_error) | 550 if (buffer->in_error) |
| 551 return false; | 551 return false; |
| 552 buffer->pos[buffer->len - 1] = pos; | 552 buffer->pos[buffer->len - 1] = pos; |
| 553 *end_ptr = p; | 553 *end_ptr = p; |
| 554 } | 554 } |
| 555 break; | 555 break; |
| 556 #line 557 "hb-buffer-deserialize-text.hh.tmp" | 556 #line 557 "../../src/hb-buffer-deserialize-text.hh" |
| 557 } | 557 } |
| 558 } | 558 } |
| 559 | 559 |
| 560 _out: {} | 560 _out: {} |
| 561 } | 561 } |
| 562 | 562 |
| 563 #line 119 "../../src/hb-buffer-deserialize-text.rl" | 563 #line 119 "../../src/hb-buffer-deserialize-text.rl" |
| 564 | 564 |
| 565 | 565 |
| 566 *end_ptr = p; | 566 *end_ptr = p; |
| 567 | 567 |
| 568 return p == pe && *(p-1) != ']'; | 568 return p == pe && *(p-1) != ']'; |
| 569 } | 569 } |
| 570 | 570 |
| 571 #endif /* HB_BUFFER_DESERIALIZE_TEXT_HH */ | 571 #endif /* HB_BUFFER_DESERIALIZE_TEXT_HH */ |
| OLD | NEW |