mirror of
https://github.com/bobbimanners/emailler.git
synced 2024-09-30 14:57:08 +00:00
Improved OA-I 'Insert File' function.
This commit is contained in:
parent
039dceeff7
commit
28e2b8d020
@ -140,6 +140,7 @@ ip65.dsk: bin
|
||||
java -jar $(AC) -as $@ date65 < date65.bin
|
||||
java -jar $(AC) -p $@ date65.system sys < $(CC65)/apple2enh/util/loader.system
|
||||
java -jar $(AC) -as $@ edit < edit.bin
|
||||
java -jar $(AC) -p $@ edithelp.txt txt < edithelp.txt
|
||||
java -jar $(AC) -p $@ edit.system sys < $(CC65)/apple2enh/util/loader.system
|
||||
java -jar $(AC) -as $@ email < email.bin
|
||||
java -jar $(AC) -p $@ email.cfg txt < email.cfg
|
||||
|
13
apps/edit.c
13
apps/edit.c
@ -7,7 +7,6 @@
|
||||
|
||||
// TODO: There is a bug whereby the rowlen[] values seem to get corrupted
|
||||
// TODO: Add word wrap feature (OA-W ?)
|
||||
// TODO: Improve insert file feature to not change filename
|
||||
// TODO: Improve status line, refresh it properly
|
||||
// TODO: Minor bug - can delete too many chars from status line
|
||||
// TODO: Should be smarter about redrawing when updating selection!!!
|
||||
@ -544,7 +543,7 @@ void draw_screen(void) {
|
||||
cputc(' ');
|
||||
} else {
|
||||
cprintf(
|
||||
" File:NONE ");
|
||||
" File:NONE ");
|
||||
}
|
||||
revers(0);
|
||||
|
||||
@ -1165,10 +1164,16 @@ int edit(char *fname) {
|
||||
break;
|
||||
case 0x80 + 'I': // OA-I "Insert file"
|
||||
case 0x80 + 'i':
|
||||
tmp = 65535U;
|
||||
if (prompt_for_name("File to insert", 1) == 255)
|
||||
break; // ESC pressed
|
||||
if (strlen(userentry) == 0)
|
||||
break;
|
||||
if (load_file(userentry, (tmp == 0 ? 0 : 1)))
|
||||
show_error("Can't open");
|
||||
draw_screen();
|
||||
break;
|
||||
case 0x80 + 'L': // OA-L "Load"
|
||||
case 0x80 + 'l':
|
||||
++tmp;
|
||||
if (prompt_for_name((tmp == 0 ? "File to insert" : "File to load"), 1) == 255)
|
||||
break; // ESC pressed
|
||||
if (strlen(userentry) == 0)
|
||||
|
22
apps/edithelp.txt
Normal file
22
apps/edithelp.txt
Normal file
@ -0,0 +1,22 @@
|
||||
+------------------------------------------------------------------------------+
|
||||
| emai//er EDIT.SYSTEM HELP Bobbi 2020 |
|
||||
+-------------------------------------+----------------------------------------+
|
||||
|Navigation: | Editing: |
|
||||
| Cursor keys Move the cursor | [Return] Split line |
|
||||
| @-Up Page up | [Delete] Delete char left |
|
||||
| @-Down Page down | @-[Delete] Delete char right |
|
||||
| @-Left Word left | [Tab] Go to next tabstop |
|
||||
| @-Right Word right +----------------------------------------+
|
||||
| @-< Beginning of line | Search and Replace: |
|
||||
| @-> End of line | @-F Find string |
|
||||
| @-1 ... Beginning of file ... | @-R Find and replace string |
|
||||
| @-9 through end of file +----------------------------------------+
|
||||
+-------------------------------------+ Block Commands: |
|
||||
|File Management Commands | @-C Copy block of text |
|
||||
| @-I Insert file at cursor | @-D Delete block of text |
|
||||
| @-L Load file | @-M Move block of text |
|
||||
| @-N Set file name to save +----------------------------------------+
|
||||
| @-Q Quit | Miscellaneous: |
|
||||
| @-S Save file | @-? This help |
|
||||
| | Ctrl-L Refresh screen |
|
||||
+-------------------------------------+----------------------------------------+
|
Loading…
Reference in New Issue
Block a user