diff options
| author | Jim Blandy | 1993-05-10 00:15:58 +0000 |
|---|---|---|
| committer | Jim Blandy | 1993-05-10 00:15:58 +0000 |
| commit | 88fd275e697fe57fd686e4fedde7f879c943a04f (patch) | |
| tree | ac56eb3d625621a6cedfe655ea2982cf09a03f16 /src | |
| parent | 783f85c7ae3cbdbec34872e30dc29c252127c6a0 (diff) | |
| download | emacs-88fd275e697fe57fd686e4fedde7f879c943a04f.tar.gz emacs-88fd275e697fe57fd686e4fedde7f879c943a04f.zip | |
* dispextern.h (struct face): Add cached_index member.
* xfaces.c (get_cached_face): Use it to avoid unnecessary
searches of face_vector.
Diffstat (limited to 'src')
| -rw-r--r-- | src/dispextern.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/dispextern.h b/src/dispextern.h index a89e73120c9..6efe29de8e7 100644 --- a/src/dispextern.h +++ b/src/dispextern.h | |||
| @@ -29,6 +29,13 @@ struct face | |||
| 29 | /* If this is non-zero, it is a GC we can use without modification | 29 | /* If this is non-zero, it is a GC we can use without modification |
| 30 | to represent this face. */ | 30 | to represent this face. */ |
| 31 | GC gc; | 31 | GC gc; |
| 32 | |||
| 33 | /* If we have ever called get_cached_face on this face structure, | ||
| 34 | here is the index in face_vector of the face it returned. It | ||
| 35 | might not be valid any more, but it's a good place to start | ||
| 36 | looking; get_cached_face tries to use this to avoid searching | ||
| 37 | all of face_vector. */ | ||
| 38 | int cached_index; | ||
| 32 | 39 | ||
| 33 | /* Pixel value for foreground color. */ | 40 | /* Pixel value for foreground color. */ |
| 34 | int foreground; | 41 | int foreground; |