--[[
@title !EDI - text editor
@chdk_version 1.4
@param n Newline (0=Windows 1=Unix)
@default n 0
@values n Windows Unix
@param y Editor height
@default y 14
@range y 10 20
@param x Editor width
@default x 42
@range x 30 50
@param s Start Browser in
@default s 0
@values s SCRIPTS LOGS BOOKS HELP DATA A/Z
--%04d= get_exp_count()
@param f insert function map
@default f 0
@values f script other
@param a Write a new file? (1=Yes)
@default a 0
@range a 0 1
@param b Do backups? (0=No)
@default b 1
@range b 0 1
@param i Create A/Z/.../ab.c
@default i 0
@range i 0 1
@param m Low Memory (1=Yes)
@default m 0
@range m 0 1
@param e fix execute() (1=Yes)
@default e 1
@range e 0 1
--@param z Has this camera zoom?(0=NO)
--@default z 1
--]]
--[[
Version: 2.7
Author: Pawel Tokarz aka outslider
License: GPL 3+;see: http://www.gnu.org/licenses/gpl-3.0.html
in order to use with GPL<3: You can also use it with GPL<3 software.
----------------------------------------------------------------
| This version requires CHDK with Virtual Keyboard module!!! |
----------------------------------------------------------------
Changelog for 2.x series:
- 'new file' option added
- empty file opening fixed (however really empty file can't be saved, it'll contain \n at least...)
- usage of text_box() for 'save as...' and new file name (thx for TobiMarg, tsvstar, philmoz, msl and others)
- some changes in menu() function
- fixed bug while browser is closed
- erase in MOVE mode jumps to the begin of the file
- more staff added but might be not mentioned
More info you can find on CHDK Forum http://chdk.setepontos.com/index.php?topic=6465.0
additionally: the biggest file I successfully opened on SX130IS had 916 kB. Opening 962 kB file failed. Other cameras has different size of free memory, nevertheless opening average scripts as 5-10 kb shouldn't cause any problems.
added // Caefix 05/May/2020 :...,....1....,....2....,....3....,....4..
~~ [MemWatch], some 'collectgarbage() ' to fix bigfile|longline Bug
~~