diff options
author | KatolaZ <katolaz@freaknet.org> | 2019-07-30 12:15:54 +0100 |
---|---|---|
committer | KatolaZ <katolaz@freaknet.org> | 2019-07-30 12:15:54 +0100 |
commit | eebc645dee0d15871d6cc46f156d424cd916b191 (patch) | |
tree | 82bb51d04d05a3cf1b4937e2cefb70cc282e9993 /files.c | |
parent | a99759398841d86928c7ad4d8248f907765cbeb2 (diff) |
yank buffer and initial copy/cut/paste support
Diffstat (limited to 'files.c')
-rw-r--r-- | files.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -24,7 +24,7 @@ void write_file(FILE *fc){ return; } for (i=0; i<HEIGHT; i++){ - fprintf(fout, "%s\n", screen[i].s); + fprintf(fout, "%s\n", screen.l[i].s); } fclose(fout); modified = 0; @@ -50,8 +50,8 @@ void load_file(FILE *fc){ get_string(fc, "Load file: ", newfname, 255); if ((fin=fopen(newfname, "r")) != NULL){ i = 0; - while((fgets(screen[i].s, WIDTH+2, fin)) != NULL && i<HEIGHT) - screen[i++].s[WIDTH-1]='\0'; + while((fgets(screen.l[i].s, WIDTH+2, fin)) != NULL && i<HEIGHT) + screen.l[i++].s[WIDTH-1]='\0'; for(;i<HEIGHT; i++){ erase_line(i); } |