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[255];
20 for(i = 0; i < 255; i++)
21 buffer[i] = glk_char_to_upper(i + 1);
23 glk_put_string("Philip en Marijn zijn vet goed.\n");
24 glk_put_string(buffer);
26 frefid_t f = glk_fileref_create_by_prompt(fileusage_TextMode, filemode_Write, 0);
27 if( glk_fileref_does_file_exist(f) )
28 glk_put_string("\n\nFile exists!\n");
30 glk_put_string("\n\nFile does not exist!\n");
31 glk_fileref_destroy(f);