This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
da404lewzer's profile picture

[1.4] TACO - A text editor with flavor!

Started by da404lewzer, 09 December 2012 - 05:19 PM
da404lewzer #1
Posted 09 December 2012 - 06:19 PM
TACO is a text editor written from scratch that attempts to bring modern functionality found in editors like Notepad++ to ComputerCraft.

While TACO has been tested, it is currently in BETA and may contain bugs or mess up files!

Demo:
[media]http://www.youtube.com/watch?v=BQEZ2GXQqzU[/media]

Features:
  • Fast and responsive GUI
  • Standard File menus with New, Open, Save, Save As, etc…
  • Cut/Copy/Paste/Clone/Delete entire lines of code
  • Advanced Custom File Dialogs (coming soon to an API near you…)
  • Line numbers
  • Fullscreen mode
  • Revert File (reload the file without exiting)
  • Line highlighting on Advanced Computers
  • Works on Turtles and B/W Interfaces
  • Partial mouse support (works to move cursor, not yet added to GUI elements, advanced computer only)
  • Clock in corner
To Install run these three commands:
pastebin get w1RtfqFd market
market get gjdh1m taco y
taco

Project / File Downloads:
http://turtlescripts...tor-with-flavor
Cranium #2
Posted 09 December 2012 - 06:50 PM
Wow…. Just wow….
I love this!
I might have to use this instead of the regular editor ALL the time. +1 for you!
da404lewzer #3
Posted 09 December 2012 - 07:09 PM
Thanks for checking it out! I look forward to more feedback and new feature requests :)/>
billysback #4
Posted 09 December 2012 - 09:22 PM
Looks awesome!
Just to make sure, are all of the buttons in the taskbar also hotkeys? as in ALT+KEY or something?
If not then that is a must for me…

Also, what about selecting parts of lines and copying/cutting/pasting just that part of the line, then implementing that so you can select across multiple lines.

(Also there is scrolling left/right/up/down right?)
da404lewzer #5
Posted 09 December 2012 - 09:34 PM
Key binding is not currently a feature but it will be added very soon :)/>

Also, true mouse selection will be enabled in future versions, I quickly added the Line tools to allow copy/paste at a most basic level for now.. figured that would be better than it not having it at all :)/>

And yes, scrolling left/right/up/down works.. as does home/end and page up/down (i have to go fullscreen first tho, seems like a ftb bug) as well as being able to click on the line/col :)/>
Cranium #6
Posted 09 December 2012 - 09:40 PM
One more thing you can do is add highlight + right click. That way, you don;t have to highlight, pull down the menu, and then select copy. It would just open a small minimenu to the side.
billysback #7
Posted 09 December 2012 - 09:48 PM
I think hotkeys would do that just fine, the current GUI is good and along side hotkeys it would be better but I don't think there need to be a middle.
However maybe you should add something to the end of all of the tabs in the taskbar that tell you what hotkeys represent each button when you add them.
Cranium #8
Posted 09 December 2012 - 09:50 PM
I think hotkeys would do that just fine, the current GUI is good and along side hotkeys it would be better but I don't think there need to be a middle.
However maybe you should add something to the end of all of the tabs in the taskbar that tell you what hotkeys represent each button when you add them.
I agree, Showing us what the hoykeys are right next to the options would be nice.
Sammich Lord #9
Posted 09 December 2012 - 11:19 PM
What about themes and syntax highlight? It will be a perfect in-game IDE if it had those two things.
Mads #10
Posted 10 December 2012 - 01:09 AM
Human: It would not be an IDE. An Integrated Development Environment needs to have the possibility to execute (and compile) an application, along a few others.
billysback #11
Posted 10 December 2012 - 01:25 AM
He could very easily add capabilities to test code, compiling would be the same as saving.
To test code you could simply write a temporary file (maybe in a "temp" folder) then just call
os.run({}, "\temp\temp_run_path.tmp")
when the option is chosen.
GravityScore #12
Posted 10 December 2012 - 01:49 AM
Wow this looks incredible! LOVE the way its done! (Love the name too :P/>)

Few (ok maybe not) things I would love to see added:
- Go to lines/function declarations
- Split the code into sections (using a certain keyword like "– —- Section: Variable Declarations")
- Go to sections
- Print files/sections
- Split the file into multiple ones at sections
- Mouse support (clicking on dialoges, menus, lines/text, ect…)
- Customizable color themes
- Selecting pieces of text (using mouse dragging)
- Cut/copy/paste pieces of text
- Contextual menus (by right clicking)
- Normal computer support
- Batch file editing (useful for creating databases)
- List of open files (navigate between them)
- Cut/copy/paste between open files
- Live compiler errors (not runtime errors)
- Plugins (could add new items to menus that process/edit text? Get event notifications like when something is typed, deleted, menu clicked, scrolled, ect…)
- Code folding
- Syntax highlighting (already mentioned)
- File info (amount of lines/characters/words/functions/global variables/local variables/total variables, size, location saved at, ect…)
- Merge files
- File templates (like game templates, standard templates, ones that have useful functions already implemented, and user created templates made by a menu option like "Save as Template..")
- Cloud editing across multiple computers on servers (like google docs)? Pweez :P/>


Edit: Derrrppppp. Just looked at the code on turtle scripts and found the planned features section which contains most of these :P/>
Sammich Lord #13
Posted 10 December 2012 - 02:14 AM
Human: It would not be an IDE. An Integrated Development Environment needs to have the possibility to execute (and compile) an application, along a few others.
If you look at his TurtleScripts project page he said he is adding that feature soon.
da404lewzer #14
Posted 10 December 2012 - 05:16 AM
Hey guys, thanks for the messages, I look forward to adding a lot of the features you guys have mentioned. I would respond in more detail (will do in a while) but I'm about to pass out as I've been working on a new project that I'll probably release tomorrow.. (it's a simple request I had from a friend) anyways.. good night/morning.. whatever! XD
rhyleymaster #15
Posted 10 December 2012 - 08:36 AM
Reminds me of Windows 3.1
Sammich Lord #16
Posted 10 December 2012 - 08:39 AM
I have found a issue with this. It seems to re-draw the screen at such a rapid rate that the screen tends to flicker a lot.

PS: 500th post!!
anonimo182 #17
Posted 10 December 2012 - 12:52 PM
Nice program!
NeonJ #18
Posted 10 December 2012 - 01:06 PM
Heh, this is great. Only got a few criticisms / wanted features here:

1. Screen tends to flicker a lot, and it can get annoying after a while. This is especially noticable on the "About" screen.. it looks like you tried (and failed) to make a transparency effect.

2. Unlike the built-in text editor, the text doesn't have coloured things for comments, variables, etc. I wonder if you could make it just like Notepad++'s colour system? (Well, except with better detection of comments.)

3. Not everywhere has mouse support, and when clicking on text it appears to click 2 squares to the right of the cursor. I'm guessing this is because of the numbers on the side, but it seems to be 2 squares right even when I went down to 100, where it pushed a third row to the side. Hm.

4. Classic keyboard shortcuts would be awesome. CTRL + A, CTRL + C, CTRL + V? I know CTRL is for the menu, but if you could somehow implement these too, bonus points! (Perhaps make it so that if you press A within 500ms of CTRL or something? I'unno.)

You've been coding awesome things. xD Next thing you know you'd be making the next Excel (or similar 2d-database-thing) in CC.
billysback #19
Posted 11 December 2012 - 04:56 AM
Why are you updating the text on a timer at all?
Try making it so that the screen is only drawn every time something changes on it. i.e. when a key is pressed or the mouse is clicked, then if you still want to have the cursor blink then make it only redraw the cursor on the update.
da404lewzer #20
Posted 11 December 2012 - 07:51 AM
Hey guise, I'll try to get to the flickering, it doesn't happen on mine unless I goto HUGE screens in which case I'm blaming the network. Still, I'll implement something that updates only on changes, i was waiting to implement my double buffer but oh well.


1. Screen tends to flicker a lot, and it can get annoying after a while. This is especially noticable on the "About" screen.. it looks like you tried (and failed) to make a transparency effect.

Hrm.. the about screen is bugging out anyways, It's probably related. the code doesn't draw much overlap (and surely not overlapping dialogs) so i'm not sure what you mean by a "failed" transparency. I'm sure it's the flicker you mentioned not but 10 words previous ;)/>


3. Not everywhere has mouse support, and when clicking on text it appears to click 2 squares to the right of the cursor. I'm guessing this is because of the numbers on the side, but it seems to be 2 squares right even when I went down to 100, where it pushed a third row to the side. Hm.

I'm aware the menus don't have mouse support and it's mentioned in the description (future update, other things were more important). As for the 2 squares.. D'oh. Was a last minute fix.. I'll have to release this update after the multi-key update (see next)



4. Classic keyboard shortcuts would be awesome. CTRL + A, CTRL + C, CTRL + V? I know CTRL is for the menu, but if you could somehow implement these too, bonus points! (Perhaps make it so that if you press A within 500ms of CTRL or something? I'unno.)

I've actually already started on this, and yes there will have to be a delay lock.


You've been coding awesome things. xD Next thing you know you'd be making the next Excel (or similar 2d-database-thing) in CC.

Thanks man.. and yes, you caught me.. http://imgur.com/a/gScBt, that and hex-edit were part of the plan but I thought they may be overkill.. so anyways now I may add them as modes foXD
anonimo182 #21
Posted 11 December 2012 - 10:29 AM
Hey guise, I'll try to get to the flickering, it doesn't happen on mine unless I goto HUGE screens in which case I'm blaming the network. Still, I'll implement something that updates only on changes, i was waiting to implement my double buffer but oh well.


1. Screen tends to flicker a lot, and it can get annoying after a while. This is especially noticable on the "About" screen.. it looks like you tried (and failed) to make a transparency effect.

Hrm.. the about screen is bugging out anyways, It's probably related. the code doesn't draw much overlap (and surely not overlapping dialogs) so i'm not sure what you mean by a "failed" transparency. I'm sure it's the flicker you mentioned not but 10 words previous ;)/>


3. Not everywhere has mouse support, and when clicking on text it appears to click 2 squares to the right of the cursor. I'm guessing this is because of the numbers on the side, but it seems to be 2 squares right even when I went down to 100, where it pushed a third row to the side. Hm.

I'm aware the menus don't have mouse support and it's mentioned in the description (future update, other things were more important). As for the 2 squares.. D'oh. Was a last minute fix.. I'll have to release this update after the multi-key update (see next)



4. Classic keyboard shortcuts would be awesome. CTRL + A, CTRL + C, CTRL + V? I know CTRL is for the menu, but if you could somehow implement these too, bonus points! (Perhaps make it so that if you press A within 500ms of CTRL or something? I'unno.)

I've actually already started on this, and yes there will have to be a delay lock.


You've been coding awesome things. xD Next thing you know you'd be making the next Excel (or similar 2d-database-thing) in CC.

Thanks man.. and yes, you caught me.. http://imgur.com/a/gScBt, that and hex-edit were part of the plan but I thought they may be overkill.. so anyways now I may add them as modes foXD

I did fix the flickering screen by editing line 1351, the timer, to 0.1 seconds instead of 0.01, thats too high comparing at the rate it need to refresh.

Also, nice Excel you are doing there…
Jojo.bacon #22
Posted 11 December 2012 - 04:12 PM
My request: printer support
da404lewzer #23
Posted 11 December 2012 - 06:48 PM
Printer support will be fun :-)
Goof #24
Posted 15 December 2012 - 06:39 AM
if you want to only update if the version is updated, then you could make a seperate file which contains the Version number like "1.0" and then make the startup-file first download the version file, and then if the version file is bigger than the current version, then it would ask, for updating… i have made that in my AdvLock, and that works fine…
if you want any examples then feel free to PM me :D/>
Edited on 19 February 2014 - 08:15 AM
CastleMan2000 #25
Posted 15 December 2012 - 08:47 AM
This is really cool, but I have two complaints:

First, why isn't it mouse controlled? It's a little annoying to be using advanced compys without using mouse control.
Second, it flickers like it's having a seizure. Somewhat bothersome.
darkroom #26
Posted 15 December 2012 - 02:24 PM
local logo = {
" 1111111111 ";
" 11115e454e5e11 ";
" 11545e5111111111";
"1154e411111111111";
"1e455111111111111";
"15ec5111111111111";
"1cccc1111111111 ";
"1cccc111111 ";
" 111111 ";
}
–[[Stolen Shamelessly from nPaintPro - http://pastebin.com/4QmTuJGU]]
Reading through your epic code….It cannot be unseen
KillaVanilla #27
Posted 15 December 2012 - 03:51 PM
Nice IDE / text editor.
I'd use it, but I prefer using Notepad++.
Zaggy1024 #28
Posted 15 December 2012 - 08:32 PM
Soo… I decided it would be fun to try adding mouse support to this today, and so I started playing around with it. It turned into a day-long project, which was successful. I believe I've made all the menus and dialogs have mouse support. Here's a link:

http://pastebin.com/aKyMYgbF

Note: I totally garbled the indentation because I decided it would be too annoying to get used to using spaces instead…

Also, if you find any bugs, please say so, because I haven't tested it all that much.

@da404lewzer: I hope you don't mind me modifying your code and posting it… but it sure was fun. :)/> The code was pretty well organized, so it wasn't too difficult.

edit: Ugh, somehow a ridiculously obvious error slipped past me (it didn't even cause errors when it should have, which was weird). If anyone downloaded it already (which is unlikely), re-download it from the link above.

edit: Accidentally left some debug code in there, too… I guess that's what I get for staying up till 3:00 coding. :P/> Update it again if you downloaded it…
Cranium #29
Posted 27 December 2012 - 01:24 PM
Why the name TACO? I think it's an acronym, but I'm not sure.
Mendax #30
Posted 29 December 2012 - 10:35 PM
Could I get permission to use this in my operating system?
da404lewzer #31
Posted 05 January 2013 - 07:56 AM
Hey guys, sorry the holidays ate me up. So, I'm back now, ready to post new updates. I have some updates to TACO coming out here in the next day or so, something this weekend. Happy New Year! XD

Why the name TACO? I think it's an acronym, but I'm not sure.

Probably an Invader ZIM reference, I'm not sure. It just sounded funny I guess.


Could I get permission to use this in my operating system?

I don't mind if you use TACO in your OS. I would just like some credit and if you could try to keep the auto-update functionality.
coryb2007 #32
Posted 14 January 2013 - 10:24 AM
It would be awesome if your update includes printer support, I don't think there are any (many very few I have not found) with printer support. So far all we have is the "edit filename" command…
CastleMan2000 #33
Posted 14 January 2013 - 04:48 PM
Ok, if there is one thing that's needed, it's FULL MOUSE SUPPORT! (soz for caps) I mean really, why do you have to use keyboard for everything on an advanced comp?? Aside from that, pretty good.
Unit158 #34
Posted 31 March 2013 - 06:53 AM
Reminds me of QBasic's editor. If someone could make a QBasic intepreter for computercraft, that would be awesome.
gamax92 #35
Posted 31 March 2013 - 07:09 AM
I've gotten rid of most of the flickering by simply changing the update rate from 0.01 (Actually 0.05, rounds up) to 0.1.

This is a great editor otherwise, I'd love to have this be the default (Once the bugs are hammered out of course)
TheOddByte #36
Posted 31 March 2013 - 11:47 PM
Ok.. Just tested this and I gotta say: Awesome!
Since that what it is..
But you should try to add some code highlighting like in the
normal editior. Since that can be useful.
And you should mention that you have to press CTRL to
access the menu options since I tried clicking them first and wondered why it did'nt work.