Name: stallman 2011-11-06 9:12
Sup prog
i'm using C
i have a problem
i have a dvi file where each line is a command and its parameters
i have to output a file and write what the commands do
i have been able to parse the lines into strings and get the first string which is the command itself
my goal is to compare that first string (the command) with strings contained in a string array (which are all the commands that exist in a dvi file)
that way i can return the corresponding function which will do the calculation using the parameters from the line
problem is that there is a command named set_char_i where i can go from 0 to 127
my command string array looks like that:
char *commandes[40]={"pre", "xxx1", "set", "set_char_i", "set_rule", "put", "put_rule", "down", "fnt_num", "w0", "w", "x0", "x", "y0", "y", "z0", "z", "fnt_def", "post", "post_post", "eop", "bop", "push", "pop"};
how can i make it so that "set_char_i" has i between 0 and 127?
i'm using C
i have a problem
i have a dvi file where each line is a command and its parameters
i have to output a file and write what the commands do
i have been able to parse the lines into strings and get the first string which is the command itself
my goal is to compare that first string (the command) with strings contained in a string array (which are all the commands that exist in a dvi file)
that way i can return the corresponding function which will do the calculation using the parameters from the line
problem is that there is a command named set_char_i where i can go from 0 to 127
my command string array looks like that:
char *commandes[40]={"pre", "xxx1", "set", "set_char_i", "set_rule", "put", "put_rule", "down", "fnt_num", "w0", "w", "x0", "x", "y0", "y", "z0", "z", "fnt_def", "post", "post_post", "eop", "bop", "push", "pop"};
how can i make it so that "set_char_i" has i between 0 and 127?