char *version;
char *author;
char *info;
+ char *icon;
};
const char *mainToken[] = {"MENU", "HEADER", "ICON", "DIALOG", "VLIR", ""};
const char *hdrFTypes[] = {"APPLICATION", "AUTO_EXEC", "DESK_ACC", "ASSEMBLY",
"DISK_DEVICE", "PRINTER", "SYSTEM", ""};
-const char *hdrFields[] = {"author", "info", "date", "dostype", "mode", "structure", ""};
+const char *hdrFields[] = {"author", "info", "date", "dostype", "mode", "structure", "icon", ""};
const char *hdrDOSTp[] = {"seq", "SEQ", "prg", "PRG", "usr", "USR", ""};
fprintf(outputCFile,
"//\n"
- "//\tThis file was generated by GEOS Resource Compiler\n"
+ "//\tThis file was generated by the GEOS Resource Compiler\n"
"//\n"
"//\tDO NOT EDIT! Any changes will be lost!\n"
"//\n"
- "//\tEdit proper resource file instead\n"
+ "//\tEdit proper resource file instead.\n"
"//\n\n");
}
fprintf(outputSFile,
";\n"
- ";\tThis file was generated by GEOS Resource Compiler\n"
+ ";\tThis file was generated by the GEOS Resource Compiler\n"
";\n"
";\tDO NOT EDIT! Any changes will be lost!\n"
";\n"
- ";\tEdit proper resource file instead\n"
+ ";\tEdit proper resource file instead.\n"
";\n\n");
}
myHead.dostype = 128 + 3;
myHead.structure = 0;
myHead.mode = 0;
+ myHead.icon = NULL;
t = time(NULL);
my_tm = localtime(&t);
break;
}
break;
+ case 6: /* icon */
+ myHead.icon = nextPhrase();
+ break;
}
} while (strcmp(token, "}") != 0);
"\t.import __VLIR0_START__, __STARTUP_RUN__\n\n"
"\t.byte 3, 21, 63 | $80\n");
- for (a = 0; a != 63; a = a + 3) {
+ if (myHead.icon != NULL) {
fprintf(outputSFile,
- "\t.byte %%%s, %%%s, %%%s\n",
- bintos(icon1[a], i1), bintos(icon1[a+1], i2), bintos(icon1[a+2], i3));
+ "\t.incbin \"%s\", 0, 63\n",
+ myHead.icon);
+ } else {
+ for (a = 0; a != 63; a = a + 3) {
+ fprintf(outputSFile,
+ "\t.byte %%%s, %%%s, %%%s\n",
+ bintos(icon1[a], i1), bintos(icon1[a+1], i2), bintos(icon1[a+2], i3));
+ }
}
fprintf(outputSFile,