• Jens' Script Editor - An on-calc lua editor 5 2
Currently:  

Author Topic: Jens' Script Editor - An on-calc lua editor  (Read 144072 times)

0 Members and 1 Guest are viewing this topic.

Offline ElementCoder

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 611
  • Rating: +42/-2
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #135 on: November 07, 2013, 12:17:31 am »
To make a tns document for your program you need an external tool such as the student/teacher software or th 3rd party tool luna.
« Last Edit: November 07, 2013, 12:17:57 am by ElementCoder »

Some people need a high five in the face... with a chair.
~EC

Offline AnToX98

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 107
  • Rating: +10/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #136 on: November 07, 2013, 11:43:31 am »
A little thing you should correct also :
- When using the 2D editor, you can't escape with [EE]
- It would be possible to create shortcuts, like [ctrl] + [7] to go at the the end of the code ?



My Lua projects :

Offline Jens_K

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 187
  • Rating: +52/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #137 on: November 07, 2013, 12:39:30 pm »
@hking1 & ElementCoder: I have already a document lying around where you can insert your code once and then it will execute it automatically when restarting it. It would be like a seperate self-made program. I will include it to v2.0

@AnToX98: Yep, as mentioned in the readme, you shouldn't use the 2D Editors yet, if you don't remove.them yourself before exiting your program. But I already have an idea for that... is the a way to remove or hide the 2D Editors in apilevel 1?
Unfortunately, there is neither an event for ctrl+number nor for the ctrl key and I also used every detectable button... but you can do menu => 5 => 2 to get to the end.
Aand sorry for my stupidity about the insert function :/ I didn't notice that I broke it completely; I'll fix that soon :)
« Last Edit: January 07, 2014, 10:51:39 am by Jens_K »
Sorry for nonsense.

Projects:



Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: Jens' Script Editor - An on-calc lua editor
« Reply #138 on: November 07, 2013, 01:03:15 pm »
is the a way to remove or hide the 2D Editors in apilevel 1?
No, and this is why it exists in apilevel 2. In apilevel 1, D2Editors were unusable.
« Last Edit: November 07, 2013, 01:03:21 pm by Levak »
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline AnToX98

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 107
  • Rating: +10/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #139 on: November 07, 2013, 02:15:09 pm »
@Ok thank you for fast-answering :)



My Lua projects :

Offline AnToX98

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 107
  • Rating: +10/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #140 on: March 09, 2014, 04:56:24 am »

Hey Jen's, i'm back with the features would be cool to add in v2.0 :)
These might be difficult to add but they'll make the editor so much better !


- Add a separated window with Only Images ! Images slow the coding too much !
- Possibility to edit TI-Images like Ncreator and directly copy the code to the Images window
- Autocompleting ?
- More synthax colouring, like with numbers or names of functions.


PS : I would recommend the Sublime text Lua synthax and colours that are so pretty
Pierrotdu18 started changing the colours of your editor :




But with numbers and functions names, in Sublime text 2 :







- Auto-indenting when writing if then/for do/ function()
- When autocompleting/writing gc:setColorRBG : possibility to open a little popup and choose color


I don't know if I said everything but these are all ideas and it's up to you :)
If someone has more ideas post it right here for 2.0 :)



My Lua projects :

Offline LDStudios

  • Coder Of Tomorrow
  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 388
  • Rating: +41/-1
    • View Profile
    • LD Studios
Re: Jens' Script Editor - An on-calc lua editor
« Reply #141 on: March 09, 2014, 07:10:25 am »
Having those colors would be awesome. I would also love the ability to search and replace :)
Anyways, this is pretty much my favorite lua program.  :D



Offline Jens_K

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 187
  • Rating: +52/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #142 on: March 09, 2014, 07:48:17 am »
@AnToX98: Thank you very much for the suggestions, that looks very cool! Now I'm looking forward to work on the editor again :D But to make that all properly, I'll have to rewrite very much of the code because some parts are really bad and slow; also a screen manager would be important for all the dialogues for the new features! I also didn't know about some very useful functions of the string library, which would make everything better! And seperating editor, console and user script to individual windows removes the annoying __mG! That will be über cool! :D :D

PS: How do you name development versions between v1.0 and v2.0?
Sorry for nonsense.

Projects:



Offline The_King

  • LV5 Advanced (Next: 300)
  • *****
  • Posts: 247
  • Rating: +6/-2
  • Ⓣⓗⓔ Ⓖⓐⓜⓔ ⓍⒹ
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #143 on: March 09, 2014, 07:10:47 pm »


PS: How do you name development versions between v1.0 and v2.0?


v1.5 maybe ;)

also i like the background color for the the pics by antox98
« Last Edit: March 09, 2014, 07:12:28 pm by The_King (hking1) »

Offline AnToX98

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 107
  • Rating: +10/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #144 on: March 10, 2014, 07:04:25 am »

Other thing that would be very helpful when we're coding oncalc.
In a coding software called Intellij IDEA, you can reduce functions/strings. There's also a lot of things like autocompletion (Nspire API by Adriweb), and details that make programming so much easier :)











My Lua projects :

Offline LDStudios

  • Coder Of Tomorrow
  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 388
  • Rating: +41/-1
    • View Profile
    • LD Studios
Re: Jens' Script Editor - An on-calc lua editor
« Reply #145 on: March 10, 2014, 09:48:21 am »
You could also add a quicker method of scrolling. In oclua, I enjoyed the ctrl+9 and ctrl+3 that are quick scrollers for notes pages. I know you have the bar on the side, but I hate using the mouse. I would love a shortcut for scrolling faster :)



Offline Jens_K

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 187
  • Rating: +52/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #146 on: May 25, 2014, 10:58:26 am »

Hello again!


Well, you may noticed that the reboot of this project didn't proceed as intended; When I looked in the code the only thing I saw was very much work, and everything I did ended up in problems an more work which quite deterred me.


But finally I pulled myself up and did a huge chunk of work on this project so that I finally finished the following features:
- seperate editor, console and user script application
- far more efficient syntax colouring: Image codes are no problem anymore!
- advanced protection: custom event distribution and defining event handling functions after initialization is now supported and protected
- fixed the "insert" function


I know, that doesn't look like much work, it was enough to keep me from making progress :P
Now that I "broke this barrier", I hopefully can continue to work on your suggested features :D


Here is what's planned for v2.0
- autocompletion
- customizable "insert" function
- customizable syntax colouring
- better unicode character support
- better saving and loading (the menu doesn't support dynamic changes on OS 3.0, which is why some people had problems with loading)
- unlimited code length (It's currently limited by the maximum length of saveable strings)
- more detailed error screen with informations(callStack and local variables) via the registerErrorHandler; therefor only for apilevel 2.0
- save use of the 2DEditor (only for apilevel 2.0)
- if possible: resetting environment for every new "build" via setfenv (I have to do some research here)


The current develpment version is still very unstable and buggy, but as soon as I think it's usable, I'll upload it :3
Sorry for nonsense.

Projects:



Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Jens' Script Editor - An on-calc lua editor
« Reply #147 on: May 25, 2014, 12:06:43 pm »
Nice :D
GLHF !

Also, you should wonder if you want to support old apilevel (since 3.6 is ndlessed, not a whole lot of people will be/stay on OS 3.1 forever...).

On some cases, it will be simpler to just use new apis rather than testing if it's available then use it, (in addition to having to code fallbacks (when possible) for older versions.)
« Last Edit: May 25, 2014, 12:08:20 pm by Adriweb »
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline AnToX98

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 107
  • Rating: +10/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #148 on: May 25, 2014, 02:55:04 pm »
Thank you jens you are awesome :)

Reducing functions would be very nice to as I mentioned it but I know it's hard to do it :)


Could you give anyways the new file ?


Another question : how about compatibility with the "Ressources" images on os 3.6 ? And customize the colours ?
« Last Edit: May 25, 2014, 02:59:10 pm by AnToX98 »



My Lua projects :

Offline Jens_K

  • LV4 Regular (Next: 200)
  • ****
  • Posts: 187
  • Rating: +52/-0
    • View Profile
Re: Jens' Script Editor - An on-calc lua editor
« Reply #149 on: May 25, 2014, 05:01:34 pm »
Also, you should wonder if you want to support old apilevel (since 3.6 is ndlessed, not a whole lot of people will be/stay on OS 3.1 forever...).

On some cases, it will be simpler to just use new apis rather than testing if it's available then use it, (in addition to having to code fallbacks (when possible) for older versions.)
Yes, you are right! Covering all possible situations for an error is far more complicated that just register and errorHandler... but now I already covered the most anyways ^^
But outsourcing the loading menu to a seperate GUI to be able to load files on apilevel 1.0 would be much work... I think I'll add a poll to this topic for the question of compatibility!


Reducing functions would be very nice to as I mentioned it but I know it's hard to do it :)
Yes, very hard indeed... I currently have no idea how to realize that with the current "engine"... But it wouldn't be the first time if I found an unexpected solution in the middle of a boring history lesson ;)

Could you give anyways the new file ?
Um... lets say tomorrow (trust me, you wouldn't have much fun with the current mess of the front-end! ;))

Another question : how about compatibility with the "Ressources" images on os 3.6 ? And customize the colours ?
I still use the old 3.2 software (sorry), because I couldn't find much informations about 3.6; neither about the lua api, nor the 3.6 script editor. Does it still have an option to convert an image to the old format?
Sorry for nonsense.

Projects: