X-Git-Url: https://git.stderr.nl/gitweb?a=blobdiff_plain;f=libchimara%2Fgestalt.c;h=06154591117d7d8d6ede5204e1141761e6ffd3c7;hb=f3d667ede27d019fc0728cc6d2bcf71854cf2d03;hp=2316dca52cc9992e6abe2d498ff2b7ff1342e944;hpb=68d8cb11ff2e3e6978cc01947c66312bacd52a99;p=projects%2Fchimara%2Fchimara.git diff --git a/libchimara/gestalt.c b/libchimara/gestalt.c index 2316dca..0615459 100644 --- a/libchimara/gestalt.c +++ b/libchimara/gestalt.c @@ -1,4 +1,5 @@ #include /* Surprisingly, the only symbol needed is NULL */ +#include #include "glk.h" /* Version of the Glk specification implemented by this library */ @@ -108,19 +109,34 @@ glk_gestalt_ext(glui32 sel, glui32 val, glui32 *arr, glui32 arrlen) case gestalt_Hyperlinks: return 1; - /* Hyperlinks supported on textbuffers only at the moment */ + /* Hyperlinks supported on textbuffers and textgrids */ case gestalt_HyperlinkInput: - return val == wintype_TextBuffer; - - /* Unsupported capabilities */ + return val == wintype_TextBuffer || val == wintype_TextGrid; + + /* Mouse support present in textgrids */ case gestalt_MouseInput: + return val == wintype_TextGrid; + case gestalt_Graphics: + return 1; + case gestalt_DrawImage: + return val == wintype_Graphics || val == wintype_TextBuffer; + + case gestalt_GraphicsTransparency: + return 1; + case gestalt_Sound: case gestalt_SoundVolume: +#ifdef GSTREAMER_SOUND + return 1; +#else + return 0; +#endif + + /* Unsupported capabilities */ case gestalt_SoundNotify: case gestalt_SoundMusic: - case gestalt_GraphicsTransparency: /* Selector not supported */ default: return 0;