3 static winid_t mainwin = NULL;
7 /* Open the main window. */
8 mainwin = glk_window_open(0, 0, 0, wintype_TextBuffer, 1);
10 /* It's possible that the main window failed to open. There's
11 nothing we can do without it, so exit. */
15 /* Set the current output stream to print to it. */
16 glk_set_window(mainwin);
18 unsigned char buffer[256];
20 for(i = 0; i < 256; i++)
21 buffer[i] = glk_char_to_upper(i);
23 glk_put_string("Philip en Marijn zijn vet goed.\n");
24 glk_put_buffer((gchar *)buffer, 256);
27 glk_fileref_create_by_prompt(fileusage_TextMode, filemode_Write, 0);
29 if( glk_fileref_does_file_exist(f) )
30 glk_put_string("\n\nFile exists!\n");
32 glk_put_string("\n\nFile does not exist!\n");
33 glk_fileref_destroy(f);
35 glk_put_string("\n\nCancel was clicked!\n");