diff options
| author | Kenichi Handa | 2007-04-25 11:59:44 +0000 |
|---|---|---|
| committer | Kenichi Handa | 2007-04-25 11:59:44 +0000 |
| commit | b6c8772afcdc9cc50f45e2505bd599fb8de60052 (patch) | |
| tree | 9747b0f664509cac3510bf4c6864ee7aa5971549 /src | |
| parent | de921524f8ded96f46b74856ca0a74dfac5434d6 (diff) | |
| download | emacs-b6c8772afcdc9cc50f45e2505bd599fb8de60052.tar.gz emacs-b6c8772afcdc9cc50f45e2505bd599fb8de60052.zip | |
*** empty log message ***
Diffstat (limited to 'src')
| -rw-r--r-- | src/font.h | 47 |
1 files changed, 11 insertions, 36 deletions
diff --git a/src/font.h b/src/font.h index cfc30051f68..ee8d2e27258 100644 --- a/src/font.h +++ b/src/font.h | |||
| @@ -390,17 +390,11 @@ struct font_driver | |||
| 390 | Lisp_Object (*otf_capability) P_ ((struct font *font)); | 390 | Lisp_Object (*otf_capability) P_ ((struct font *font)); |
| 391 | 391 | ||
| 392 | /* Optional. | 392 | /* Optional. |
| 393 | Drive FONT's OTF GSUB features according to GSUB_SPEC. | 393 | Apply FONT's OTF-FEATURES to the glyph string. |
| 394 | 394 | ||
| 395 | GSUB_SPEC is in this format (all elements are symbols): | 395 | FEATURES specifies which OTF features to apply in this format: |
| 396 | (SCRIPT LANGSYS GSUB-FEATURE ...) | 396 | (SCRIPT LANGSYS GSUB-FEATURE GPOS-FEATURE) |
| 397 | If one of GSUB-FEATURE is nil, apply all gsub features except for | 397 | See the documentation of `font-drive-otf' for the detail. |
| 398 | already applied and listed later. For instance, if the font has | ||
| 399 | GSUB features nukt, haln, rphf, blwf, and half, | ||
| 400 | (deva nil nukt haln nil rphf) | ||
| 401 | applies nukt and haln in this order, then applies blwf and half | ||
| 402 | in the order apearing in the font. The features are of the | ||
| 403 | default langsys of `deva' script. | ||
| 404 | 398 | ||
| 405 | This method applies the specified features to the codes in the | 399 | This method applies the specified features to the codes in the |
| 406 | elements of GSTRING-IN (between FROMth and TOth). The output | 400 | elements of GSTRING-IN (between FROMth and TOth). The output |
| @@ -410,26 +404,9 @@ struct font_driver | |||
| 410 | Return the number of output codes. If none of the features are | 404 | Return the number of output codes. If none of the features are |
| 411 | applicable to the input data, return 0. If GSTRING-OUT is too | 405 | applicable to the input data, return 0. If GSTRING-OUT is too |
| 412 | short, return -1. */ | 406 | short, return -1. */ |
| 413 | int (*otf_gsub) P_ ((struct font *font, Lisp_Object gsub_spec, | 407 | int (*otf_drive) P_ ((struct font *font, Lisp_Object features, |
| 414 | Lisp_Object gstring_in, int from, int to, | 408 | Lisp_Object gstring_in, int from, int to, |
| 415 | Lisp_Object gstring_out, int idx, int alternate_subst)); | 409 | Lisp_Object gstring_out, int idx, int alternate_subst)); |
| 416 | |||
| 417 | /* Optional. | ||
| 418 | Drive FONT's OTF GPOS features according to GPOS_SPEC. | ||
| 419 | |||
| 420 | GPOS_SPEC is in this format (all elements are symbols): | ||
| 421 | (SCRIPT LANGSYS GPOS-FEATURE ...) | ||
| 422 | The meaning is the same as GSUB_SPEC above. | ||
| 423 | |||
| 424 | This method applies the specified features to the codes in the | ||
| 425 | elements of GSTRING (between FROMth and TOth). The resulting | ||
| 426 | positioning information (x-offset and y-offset) is stored in the | ||
| 427 | slots of the elements. | ||
| 428 | |||
| 429 | Return 1 if at least one glyph has nonzero x-offset or y-offset. | ||
| 430 | Otherwise return 0. */ | ||
| 431 | int (*otf_gpos) P_ ((struct font *font, Lisp_Object gpos_spec, | ||
| 432 | Lisp_Object gstring, int from, int to)); | ||
| 433 | }; | 410 | }; |
| 434 | 411 | ||
| 435 | 412 | ||
| @@ -467,8 +444,9 @@ extern int font_set_lface_from_name P_ ((FRAME_PTR f, | |||
| 467 | int force_p, int may_fail_p)); | 444 | int force_p, int may_fail_p)); |
| 468 | extern Lisp_Object font_find_for_lface P_ ((FRAME_PTR f, Lisp_Object *lface, | 445 | extern Lisp_Object font_find_for_lface P_ ((FRAME_PTR f, Lisp_Object *lface, |
| 469 | Lisp_Object spec)); | 446 | Lisp_Object spec)); |
| 470 | extern Lisp_Object font_open_for_lface P_ ((FRAME_PTR f, Lisp_Object *lface, | 447 | extern Lisp_Object font_open_for_lface P_ ((FRAME_PTR f, Lisp_Object entity, |
| 471 | Lisp_Object entity)); | 448 | Lisp_Object *lface, |
| 449 | Lisp_Object spec)); | ||
| 472 | extern void font_load_for_face P_ ((FRAME_PTR f, struct face *face)); | 450 | extern void font_load_for_face P_ ((FRAME_PTR f, struct face *face)); |
| 473 | extern void font_prepare_for_face P_ ((FRAME_PTR f, struct face *face)); | 451 | extern void font_prepare_for_face P_ ((FRAME_PTR f, struct face *face)); |
| 474 | extern Lisp_Object font_open_by_name P_ ((FRAME_PTR f, char *name)); | 452 | extern Lisp_Object font_open_by_name P_ ((FRAME_PTR f, char *name)); |
| @@ -499,14 +477,11 @@ extern struct font *font_prepare_composition P_ ((struct composition *cmp)); | |||
| 499 | #ifdef HAVE_LIBOTF | 477 | #ifdef HAVE_LIBOTF |
| 500 | /* This can be used as `otf_capability' method of a font-driver. */ | 478 | /* This can be used as `otf_capability' method of a font-driver. */ |
| 501 | extern Lisp_Object font_otf_capability P_ ((struct font *font)); | 479 | extern Lisp_Object font_otf_capability P_ ((struct font *font)); |
| 502 | /* This can be used as `otf_gsub' method of a font-driver. */ | 480 | /* This can be used as `otf_drive' method of a font-driver. */ |
| 503 | extern int font_otf_gsub P_ ((struct font *font, Lisp_Object gsub_spec, | 481 | extern int font_drive_otf P_ ((struct font *font, Lisp_Object otf_features, |
| 504 | Lisp_Object gstring_in, int from, int to, | 482 | Lisp_Object gstring_in, int from, int to, |
| 505 | Lisp_Object gstring_out, int idx, | 483 | Lisp_Object gstring_out, int idx, |
| 506 | int alternate_subst)); | 484 | int alternate_subst)); |
| 507 | /* This can be used as `otf_gpos' method of a font-driver. */ | ||
| 508 | extern int font_otf_gpos P_ ((struct font *font, Lisp_Object gpos_spec, | ||
| 509 | Lisp_Object gstring, int from, int to)); | ||
| 510 | #endif /* HAVE_LIBOTF */ | 485 | #endif /* HAVE_LIBOTF */ |
| 511 | 486 | ||
| 512 | #ifdef HAVE_FREETYPE | 487 | #ifdef HAVE_FREETYPE |