txtreader - Read / Edit your text files
#1
Hi everybody !

I made a very simple script to open files for reading and editing.
I know alexpoet already developped a 'notepad' script, but as for myself, I didn't like it so much... Maybe I need to test it again... Maybe it is better than what I remember...
Anyway, I was thinking of an editor 'line by line' for many month and decided to code it now.

It opens text files line by line and put the lines inside a controlList control. As some lines can be longer than what a list item can show on your screen, a value is used as parameter to split long lines.

I think it can be usefull for editing xml files or input user informations to set some scripts without the need to edit it on PC and FTPing on Xbox.

Anyway, hard for me to explain, so the best thing is that you guys test it and tell me what you think.
Do you like it ?
Will you use it ?
What does it need to be more usefull
...

Download : http://xbmc-scripts.gx-mod.com/documents...141006.rar

Bugs :
- For french at least, "accent" leters (à é è ...) are replaced with squares as editing it... Sad It must be because of text encoding, but didn't figure out how to solve it yet
- Empty files make the script hangs

Need more test :
ANSI files just work fine, but need to improve script for other encodings (utf8, unicode, ...)

Running :
1- launch the script
-> a default text file is open (it is a french one and explain the commands)
2- white pad button : open/close a menu (open / save)
3- open button : open the xbmc file browser to select your file
3bis- save button : save the current text and make an "on place" copy of the original file with .old extension
4- B red pad button : on a line ask to delete the selected line
5- Y yellow pad button : on a line, insert a new line on this position
6- A green pad button : on a line, open virtual keyboard for editing the line
7- ask for saving when you quit if text has been modified
8- ask for saving if you mdified the text AND if you choose to open a new file

You should get a message box for the first run, simply because it uses a .ini file for settings, and I decided that this file should be in Q:\userdata directory. So the script will tell you file is missing , then, will copy the one at root of script directory, inside userdata dir. Hope it makes sense Smile
Reply
#2
I just tested your script and like it. Nice work so far, here my suggestions to improve the texteditor:
1. the "side-scrollbuttons" (1 / 3 with arrows) are a little bit offscreen with my TV. Maybe set it 1 or 2 lines up.
2. english readme in the archive would be nice Rolleyes
3. Add a helpscreen where the buttons are explained

Haven´t tested it with german umaluts (äöüß). I´ll do it tomorrow and report back.
Philips TV with Kodi 20.2 with IPTV --- Orbsmart 500 Android 21 alpha/beta as Online-radio/TV in the kitchen
Reply
#3
thanks for feddback !
Need more feedback to know if it is interesting going on this project... Don't really want to waste my time if it is not usefull Wink
Reply
#4
Exclamation 
I'm using your script now and it is great, works nicelly for me. But I have a problem. When I use the White Button and I choose Open, it says instantaneously "ERROR - The file you selected cannot be open" and I haven't even opened anything!

And the option to create a file and to choose where to save a file would be nice. But, anyway, great job! Rolleyes
Reply
#5
sdiax how old is your build?
read the xbmc online-manual, faq and search the forums before posting! do not e-mail the xbmc-team asking for support!
read/follow the forum rules! note! team-xbmc never have and never will host or distribute ms-xdk binaries/executables!
Reply
#6
[email protected] Wrote:sdiax how old is your build?

My build is the August 6, 2006 one. Do you think that's the problem?
Reply
#7
sdiax Wrote:My build is the August 6, 2006 one. Do you think that's the problem?

August to end october... Do you remember there is adds, fixs in the cvs every day ?

So yes it could be the problem, go try the last T3CH build and enjoy this great script made by AlexSolex

Big Grin
Sorry for my...english :blush:
Reply
#8
A new version.
Juste a fiew keymap changing. Now pad and remoter both work fine.
Quote:pad keymap:
White button : show/hide the menu
Green A button : edit selected line
Red B button : delete selected line (with confirmation)
Y yellow button or black button : insert a new line
back button : Quit

Remote keymap :
"Back" or "skip-" : delete selected line (with confirmation)
"menu" : show/hide the menu
"skip+" : insert one line
"Select" : edit selected line
"back" : Quit

I added a button in the menu to quit

Work in progress :
"new file" button
"save as" button

Sorry for you guys, help.txt file remain french... Maybe a translation for next release. Anyway, it is not very interesting Smile
Reply
#9
erf !!!
I forgot the url :
http://xbmc-scripts.gx-mod.com/documents...291006.rar

Nota : if anybody knows and can explain me how to edit my post.... I can't find any "edit button"
Reply

Logout Mark Read Team Forum Stats Members Help
txtreader - Read / Edit your text files0