+/**
+ * stylehint_Indentation:
+ *
+ * How much to indent lines of text in the given style. May be a negative
+ * number, to shift the text out (left) instead of in (right). The exact metric
+ * isn't precisely specified; you can assume that +1 is the smallest indentation
+ * possible which is clearly visible to the player.
+ */
+
+/**
+ * stylehint_ParaIndentation:
+ *
+ * How much to indent the first line of each paragraph. This is in addition to
+ * the indentation specified by %stylehint_Indentation. This too may be
+ * negative, and is measured in the same units as %stylehint_Indentation.
+ */
+
+/**
+ * stylehint_Justification:
+ *
+ * The value of this hint must be one of the constants
+ * %stylehint_just_LeftFlush, %stylehint_just_LeftRight (full justification),
+ * %stylehint_just_Centered, or %stylehint_just_RightFlush.
+ */
+
+/**
+ * stylehint_Size:
+ *
+ * How much to increase or decrease the font size. This is relative; 0 means the
+ * interpreter's default font size will be used, positive numbers increase it,
+ * and negative numbers decrease it. Again, +1 is the smallest size increase
+ * which is easily visible.
+ * <note><para>
+ * The amount of this increase may not be constant. +1 might increase an
+ * 8-point font to 9-point, but a 16-point font to 18-point.
+ * </para></note>
+ */
+
+/**
+ * stylehint_Weight:
+ *
+ * The value of this hint must be 1 for heavy-weight fonts (boldface), 0 for
+ * normal weight, and -1 for light-weight fonts.
+ */
+
+/**
+ * stylehint_Oblique:
+ *
+ * The value of this hint must be 1 for oblique fonts (italic), or 0 for normal
+ * angle.
+ */
+
+/**
+ * stylehint_Proportional:
+ *
+ * The value of this hint must be 1 for proportional-width fonts, or 0 for
+ * fixed-width.
+ */
+
+/**
+ * stylehint_TextColor:
+ *
+ * The foreground color of the text. This is encoded in the 32-bit hint value:
+ * the top 8 bits must be zero, the next 8 bits are the red value, the next 8
+ * bits are the green value, and the bottom 8 bits are the blue value. Color
+ * values range from 0 to 255.
+ * <note><para>
+ * So 0x00000000 is black, 0x00FFFFFF is white, and 0x00FF0000 is bright red.
+ * </para></note>
+ */
+
+/**
+ * stylehint_BackColor:
+ *
+ * The background color behind the text. This is encoded the same way as
+ * %stylehint_TextColor.
+ */
+
+/**
+ * stylehint_ReverseColor:
+ *
+ * The value of this hint must be 0 for normal printing (%stylehint_TextColor on
+ * %stylehint_BackColor), or 1 for reverse printing (%stylehint_BackColor on
+ * %stylehint_TextColor).
+ * <note><para>
+ * Some libraries may support this hint but not the %stylehint_TextColor and
+ * %stylehint_BackColor hints. Other libraries may take the opposite tack;
+ * others may support both, or neither.
+ * </para></note>
+ */
+
+/**
+ * stylehint_NUMHINTS:
+ *
+ * The number of style hints defined in this library.
+ */
+
+/**
+ * stylehint_just_LeftFlush:
+ *
+ * A value for %stylehint_Justification representing left-justified text.
+ */
+
+/**
+ * stylehint_just_LeftRight:
+ *
+ * A value for %stylehint_Justification representing fully justified text.
+ */
+
+/**
+ * stylehint_just_Centered:
+ *
+ * A value for %stylehint_Justification representing centered text.
+ */
+
+/**
+ * stylehint_just_RightFlush:
+ *
+ * A value for %stylehint_Justification representing right-justified text.
+ */
+
+/*---------- TYPES, FUNCTIONS AND CONSTANTS FROM GI_BLORB.H ------------------*/
+
+/**
+ * giblorb_err_t:
+ *
+ * An integer type that can hold the Blorb error codes.
+ */
+
+/**
+ * giblorb_err_None:
+ *
+ * No error.
+ */
+
+/**
+ * giblorb_err_CompileTime:
+ *
+ * Something is compiled wrong in the Blorb layer.
+ */
+
+/**
+ * giblorb_err_Alloc:
+ *
+ * Memory could not be allocated.
+ * <note><title>Chimara</title>
+ * <para>
+ * The Blorb layer in the Chimara library should not return this error code;
+ * instead, the program aborts if memory allocation fails, in keeping with
+ * GLib practices.
+ * </para></note>
+ */
+
+/**
+ * giblorb_err_Read:
+ *
+ * Data could not be read from the file.
+ */
+
+/**
+ * giblorb_err_NotAMap:
+ *
+ * The map parameter is invalid.
+ */
+
+/**
+ * giblorb_err_Format:
+ *
+ * The Blorb file is corrupted or invalid.
+ */
+
+/**
+ * giblorb_err_NotFound:
+ *
+ * The requested data could not be found.
+ */
+
+/**
+ * giblorb_method_DontLoad:
+ *
+ * Pass this to giblorb_load_chunk_by_type(), giblorb_load_chunk_by_number(), or
+ * giblorb_load_resource() to obtain information about a chunk without actually
+ * loading it.
+ */
+
+/**
+ * giblorb_method_Memory:
+ *
+ * Pass this to giblorb_load_chunk_by_type(), giblorb_load_chunk_by_number(), or
+ * giblorb_load_resource() to load a chunk into memory.
+ */
+
+/**
+ * giblorb_method_DontLoad:
+ *
+ * Pass this to giblorb_load_chunk_by_type(), giblorb_load_chunk_by_number(), or
+ * giblorb_load_resource() to get the position in the Blorb file at which the
+ * chunk data starts.
+ */
+
+/**
+ * giblorb_ID_Snd:
+ *
+ * Resource usage constant representing a sound file.
+ */
+
+/**
+ * giblorb_ID_Exec:
+ *
+ * Resource usage constant representing an executable program.
+ */
+
+/**
+ * giblorb_ID_Pict:
+ *
+ * Resource usage constant representing an image file.
+ */
+
+/**
+ * giblorb_ID_Copyright:
+ *
+ * Resource usage constant representing the copyright message (date and holder,
+ * without the actual copyright symbol). There should only be one such chunk per
+ * file.
+ */
+
+/**
+ * giblorb_ID_AUTH:
+ *
+ * Resource usage constant representing the name of the author or creator of the
+ * file. This could be a login name on multi-user systems, for example. There
+ * should only be one such chunk per file.
+ */
+
+/**
+ * giblorb_ID_ANNO:
+ *
+ * Resource usage constant representing any textual annotation that the user or
+ * writing program sees fit to include.
+ */
+
+/**
+ * giblorb_map_t:
+ *
+ * Holds the complete description of an open Blorb file. This type is opaque for
+ * normal interpreter use.
+ */
+
+/**
+ * giblorb_result_t:
+ *
+ * Holds information about a chunk loaded from a Blorb file, and the method of
+ * accessing the chunk data. See giblorb_load_chunk_by_type() and
+ * giblorb_load_chunk_by_number().
+ */
+
+/**
+ * giblorb_create_map:
+ * @file: An input stream pointing to a Blorb file.
+ * @newmap: Return location for a Blorb resource map.
+ *
+ * Reads Blorb data out of a Glk stream. It does not load every resource at
+ * once; instead, it creates a map in memory which makes it easy to find
+ * resources. A pointer to the map is stored in @newmap. This is an opaque
+ * object; you pass it to the other Blorb-layer functions.
+ *
+ * Returns: a Blorb error code.
+ */
+
+/**
+ * giblorb_destroy_map:
+ * @map: A Blorb resource map to deallocate.
+ *
+ * Deallocates @map and all associated memory. This does
+ * <emphasis>not</emphasis> close the original stream.
+ *
+ * Returns: a Blorb error code.
+ */
+
+/**
+ * giblorb_load_chunk_by_type:
+ * @map: The Blorb resource map to load a chunk from.
+ * @method: The loading method to use, one of %giblorb_method_DontLoad,
+ * %giblorb_method_Memory, or %giblorb_method_FilePos.
+ * @res: Return location for the result.
+ * @chunktype: The type of chunk to load.
+ * @count: The chunk number of type @chunktype to load.
+ *
+ * Loads a chunk of a given type. The @count parameter distinguishes between
+ * chunks of the same type. If @count is zero, the first chunk of that type is
+ * loaded, and so on.
+ *
+ * To load a chunk of an IFF FORM type (such as AIFF), you should pass in the
+ * form type, rather than FORM.
+ * <note><para>
+ * This introduces a slight ambiguity — you cannot distiguish between a
+ * FORM AIFF chunk and a non-FORM chunk of type AIFF. However, the latter is
+ * almost certainly a mistake.
+ * </para></note>
+ *
+ * The returned data is written into @res, according to @method.
+ *
+ * The <structfield>chunknum</structfield> field is filled in with the number of
+ * the chunk. (This value can then be passed to giblorb_load_chunk_by_number()
+ * or giblorb_unload_chunk().) The <structfield>length</structfield> field is
+ * filled in with the length of the chunk in bytes. The
+ * <structfield>chunktype</structfield> field is the chunk's type, which of
+ * course will be the type you asked for.
+ *
+ * If you specify %giblorb_method_DontLoad, no data is actually loaded in. You
+ * can use this if you are only interested in whether a chunk exists, or in the
+ * <structfield>chunknum</structfield> and <structfield>length</structfield>
+ * parameters.
+ *
+ * If you specify %giblorb_method_FilePos,
+ * <structfield>data.startpos</structfield> is filled in with the file position
+ * of the chunk data. You can use glk_stream_set_position() to read the data
+ * from the stream.
+ *
+ * If you specify %giblorb_method_Memory, <structfield>data.ptr</structfield> is
+ * filled with a pointer to allocated memory containing the chunk data. This
+ * memory is owned by the map, not you. If you load the chunk more than once
+ * with %giblorb_method_Memory, the Blorb layer is smart enough to keep just one
+ * copy in memory. You should not deallocate this memory yourself; call
+ * giblorb_unload_chunk() instead.
+ *
+ * Returns: a Blorb error code.
+ */
+
+/**
+ * giblorb_load_chunk_by_number:
+ * @map: The Blorb resource map to load a chunk from.
+ * @method: The loading method to use, one of %giblorb_method_DontLoad,
+ * %giblorb_method_Memory, or %giblorb_method_FilePos.
+ * @res: Return location for the result.
+ * @chunknum: The chunk number to load.
+ *
+ * This is similar to giblorb_load_chunk_by_type(), but it loads a chunk with a
+ * given chunk number. The type of the chunk can be found in the
+ * <structfield>chunktype</structfield> field of #giblorb_result_t. You can get
+ * the chunk number from the <structfield>chunknum</structfield> field, after
+ * calling one of the other load functions.
+ *
+ * Returns: a Blorb error code.
+ */
+
+/**
+ * giblorb_unload_chunk:
+ * @map: The Blorb resource map to unload a chunk from.
+ * @chunknum: The chunk number to unload.
+ *
+ * Frees the chunk data allocated by %giblorb_method_Memory. If the given chunk
+ * has never been loaded into memory, this has no effect.
+ *
+ * Returns: a Blorb error code.
+ */
+
+/**
+ * giblorb_load_resource:
+ * @map: The Blorb resource map to load a resource from.
+ * @method: The loading method to use, one of %giblorb_method_DontLoad,
+ * %giblorb_method_Memory, or %giblorb_method_FilePos.
+ * @res: Return location for the result.
+ * @usage: The type of data resource to load.
+ * @resnum: The resource number to load.
+ *
+ * Loads a resource, given its usage and resource number. Currently, the three
+ * usage values are %giblorb_ID_Pict (images), %giblorb_ID_Snd (sounds), and
+ * %giblorb_ID_Exec (executable program). See the Blorb specification for more
+ * information about the types of data that can be stored for these usages.
+ *
+ * Note that a resource number is not the same as a chunk number. The resource
+ * number is the sound or image number specified by a Glk program. Chunk number
+ * is arbitrary, since chunks in a Blorb file can be in any order. To find the
+ * chunk number of a given resource, call giblorb_load_resource() and look in
+ * <structfield>res.chunknum</structfield>.
+ *
+ * Returns: a Blorb error code.
+ */
+
+/**
+ * giblorb_count_resources:
+ * @map: The Blorb resource map in which to count the resources.
+ * @usage: The type of data resource to count.
+ * @num: Return location for the number of chunks of @usage.
+ * @min: Return location for the lowest resource number of @usage.
+ * @max: Return location for the highest resource number of @usage.
+ *
+ * Counts the number of chunks with a given usage (image, sound, or executable.)
+ * The total number of chunks of that usage is stored in @num. The lowest and
+ * highest resource number of that usage are stored in @min and @max. You can
+ * leave any of the three pointers %NULL if you don't care about that
+ * information.
+ *
+ * Returns: a Blorb error code.
+ */
+
+/*--------------------TYPES AND CONSTANTS FROM GLKSTART.H---------------------*/
+
+/**
+ * glkunix_argumentlist_t:
+ *
+ * In each entry, name is the option as it would appear on the command line
+ * (including the leading dash, if any.) The desc is a description of the
+ * argument; this is used when the library is printing a list of options. And
+ * argtype is one of the following constants:
+ *
+ * <variablelist>
+ * <varlistentry>
+ * <term>%glkunix_arg_NoValue</term>
+ * <listitem><para>The argument appears by itself.</para></listitem>
+ * </varlistentry>
+ * <varlistentry>
+ * <term>%glkunix_arg_ValueFollows</term>
+ * <listitem><para>The argument must be followed by another argument (the
+ * value).</para></listitem>
+ * </varlistentry>
+ * <varlistentry>
+ * <term>%glkunix_arg_ValueCanFollow</term>
+ * <listitem><para>The argument may be followed by a value, optionally. (If the
+ * next argument starts with a dash, it is taken to be a new argument, not the
+ * value of this one.)</para></listitem>
+ * </varlistentry>
+ * <varlistentry>
+ * <term>%glkunix_arg_NumberValue</term>
+ * <listitem><para>The argument must be followed by a number, which may be the
+ * next argument or part of this one. (That is, either <quote><code>-width
+ * 20</code></quote> or <quote><code>-width20</code></quote> will be accepted.)
+ * </para></listitem>
+ * </varlistentry>
+ * <varlistentry>
+ * <term>%glkunix_arg_End</term>
+ * <listitem><para>The <code>glkunix_arguments[]</code> array must be
+ * terminated with an entry containing this value.</para></listitem>
+ * </varlistentry>
+ * </variablelist>
+ *
+ * To accept arbitrary arguments which lack dashes, specify a name of
+ * <code>""</code> and an argtype of %glkunix_arg_ValueFollows.
+ *
+ * If you don't care about command-line arguments, you must still define an
+ * empty arguments list, as follows:
+ * |[
+ * #glkunix_argumentlist_t glkunix_arguments[] = {
+ * { NULL, #glkunix_arg_End, NULL }
+ * };
+ * ]|
+ *
+ * Here is a more complete sample list:
+ * |[
+ * #glkunix_argumentlist_t glkunix_arguments[] = {
+ * { "", #glkunix_arg_ValueFollows, "filename: The game file to load." },
+ * { "-hum", #glkunix_arg_ValueFollows, "-hum NUM: Hum some NUM." },
+ * { "-bom", #glkunix_arg_ValueCanFollow, "-bom [ NUM ]: Do a bom (on
+ * the NUM, if given)." },
+ * { "-goo", #glkunix_arg_NoValue, "-goo: Find goo." },
+ * { "-wob", #glkunix_arg_NumberValue, "-wob NUM: Wob NUM times." },
+ * { NULL, #glkunix_arg_End, NULL }
+ * };
+ * ]|
+ * This would match the arguments <quote><code>thingfile -goo -wob8 -bom -hum
+ * song</code></quote>.
+ *
+ * After the library parses the command line, it does various occult rituals of
+ * initialization, and then calls glkunix_startup_code().
+ *
+ * |[ int glkunix_startup_code(#glkunix_startup_t *data); ]|
+ *
+ * This should return %TRUE if everything initializes properly. If it returns
+ * %FALSE, the library will shut down without ever calling your glk_main()
+ * function.
+ */
+
+/**
+ * glkunix_startup_t:
+ *
+ * The fields are a standard Unix <code>(argc, argv)</code> list, which contain
+ * the arguments you requested from the command line. In deference to custom,
+ * <code>argv[0]</code> is always the program name.
+ */
+
+/**
+ * glkunix_arg_End:
+ *
+ * Terminates a list of #glkunix_argumentlist_t.
+ */
+
+/**
+ * glkunix_arg_ValueFollows:
+ *
+ * Indicates an argument which must be followed by a value, as the next
+ * argument.
+ */
+
+/**
+ * glkunix_arg_NoValue:
+ *
+ * Indicates an argument which occurs by itself, without a value.
+ */
+
+/**
+ * glkunix_arg_ValueCanFollow:
+ *
+ * Indicates an argument which may be followed by a value, or may occur by
+ * itself.
+ */
+
+/**
+ * glkunix_arg_NumberValue:
+ *
+ * Indicates an argument which must be followed by a numerical value, either as
+ * the next argument or tacked onto the end of this argument.
+ */