From GameBrew - a wiki dedicated to Video Game Homebrew.
Text File Editor
Use either the virtual keyboard with the Wiimote or an external USB keyboard.
You can use the cursor keys and Home/End to navigate. Ctrl-Home will move to the top, Ctrl-End to the end of the file. PageUp(Ctrl-CursorUP) and PageDown(Ctrl-CursorDown) scroll by one screen. Backspace and Delete erase characters. TABs will be expanded to eight blanks.
Press ESC or the Menu key to call the menu to load and save files.
- Graphic text display with black text on white background.
- Shows a virtual keyboard for using the editor with the Wiimote if no external keyboard is available.
- Supports an external USB keyboard
- Supports line length up to 160 characters and scrolls horizontally.
- Shows a small menu when you press ESC or select the Menu key.
- Maximum file size: 2MB
When you load TopEdit you can enter text and save it in the current directory using the file name you enter. The initial current directory is the one where the editor program is located, i.e. apps\topedit.
Or you load an existing file by calling the menu and entering the file name or browsing the directories. When you browse the directories you will start in the root directory.
The directory where the loaded file is located becomes the current directory. You can save it again with a different name. A file loaded with linefeeds as line endings will be converted to CRLF line endings when saved. Control characters in the file are displayed as blanks. Therefore the CR at the end of the line may show as a blank in a different editor.
Exit the editor by calling the menu and entering "q" there.
The following features could be added in the future:
- Enable key repeat.
- Mark part of the text and copy that to the clipboard and retrieve it again.
- Open more than one file simultaneously.
- Save the edited file in a different directory.
- Add a drop-down menu.
All cursor movements and features of an editor which you use every day you take for granted. But when you write an editor yourself it takes a lot of time and testing implementing them. I release this version knowing that it leaves room for improvement.
The editor is written with SDL and the previous version of devkitpro. It uses libfat. The external keyboard is not read with SDL but with libusbkeyb.
Version 0.61 - Actual - 15th Feb 2009:
- modified Backspace, Del and End key functions
Version 0.6 - 14th Feb 2009:
- Corrected problem concatenating lines with Backspace and Del
- Added CTRL-Cursor UP/DOWN to external keyboard routine
Version 0.5 - 8th Feb 2009:
- Initial release.