polygone
|
|
Posted on: February 19, 2011, 11:16:46 pm |
|
|
Location: England Joined: Mar 2009
Posts: 794
|
While Josh and Ism are currently working on the script editor post any features or suggestions for it here.
Please number your suggestions so they are easier to reply to.
If you come up with more suggestions after you have already posted, start a new post and continue your numbering where you left off. This way, suggestions can be identified by Username#SuggestionNumber.
|
|
« Last Edit: February 20, 2011, 07:29:33 pm by IsmAvatar »
|
Logged
|
I honestly don't know wtf I'm talking about but hopefully I can muddle my way through.
|
|
|
polygone
|
|
Reply #1 Posted on: February 19, 2011, 11:48:48 pm |
|
|
Location: England Joined: Mar 2009
Posts: 794
|
1) Options for all features, very important for me. Like being able to turn off line numbering, any highlighting features added, change highlighting colours etc. 2) Automatic syntax checking when closing the editor, warns user upon syntax error. 3) Bracket highlight colouring feature. For example upon hotkey it would look like this: { text, text, text { text, text, text text { text, text, text, text } } text text { text }}Also an alternative for brackets and strings. This is perhaps the best way to visually see things in my opinion. 4) Smart code snippet feature. For example you can put whatever common code snippet pieces in a text file you wish, like: for (i = 0; i < $; i += 1) { $ } then upon a hotkey it insert the code snippet into the editor, like: for (i = 0; i < ; i += 1) { } and moves the cursor automatically to the first $ sign for typing, then upon another hotkey it moves to the second $ sign then to the end of the snippet piece. Not sure how it's best to choose from different code snippets from the hotkey, ideally upon the hotkey press the user should be able to see the different code snippet choices (without it getting in the way) then can press corresponding key to insert a snippet. 5) Add a help menu so a user can see all the script editor hotkeys easily. 6) Feature to indent/unindent selected lines a certain amount of space 7) CTRL selecting, allowing to select multiple text at once. 8) Math calculations. For example you highlight 2 + 3 press a hotkey it changes it to 5, or highlight 34*5 it changes it to 170. I'll probably think of more things. Feel free to shoot them down, I don't think any suggestions through
|
|
« Last Edit: July 08, 2011, 04:22:45 pm by polygone »
|
Logged
|
I honestly don't know wtf I'm talking about but hopefully I can muddle my way through.
|
|
|
|
Post made February 20, 2011, 04:50:23 am was deleted at the author's request.
|
luiscubal
|
|
Reply #4 Posted on: February 20, 2011, 09:18:31 am |
|
|
Joined: Jun 2009
Posts: 452
|
Some of these are LGM, some are code editor, some are a combination: - Expand/Collapse brackets (), {}, [], begin/end
- Fix indenting
- Refactoring(Rename variable, Rename Script, Extract Method)
- Auto-complete - see MonoDevelop for ideas(for instance, in MD "Case" matches "camelCase", etc.)
- If the above situation about camelCase is accepted, then some customization would be nice(camelCase vs underline_separated, etc.)
- Breakpoints
- Tab indents selection(in GM, tab doesn't indent selection, it replaces it)
- Shift+Tab unindents selection(or current line, or whatever)
- Script documentation support(Like /** @argument0 Instance to receive foobar */)
- Code style editing(replace begin/end by {} and vice-versa, remove all then statements, add ; to the end of lines where a ; is implicit, remove all unneeded ;, option to convert all "if (foo) stmt;" to "if (foo) { stmt; }", etc.) Note that after applying ANY of these changes, the code effect should be EXACTLY the same. This is an important detail to consider when implementing ; addition/removal.
- Code warnings like Eclipse and NetBeans and auto-fix.
- Option to auto-remove whitespaces at end of lines
|
|
« Last Edit: February 20, 2011, 07:30:12 pm by IsmAvatar »
|
Logged
|
|
|
|
|
IsmAvatar
|
|
Reply #6 Posted on: February 20, 2011, 12:44:12 pm |
|
|
LateralGM Developer
Location: Pennsylvania/USA Joined: Apr 2008
Posts: 877
|
I have some suggestions. Note that they should be options, not enforced.
1. When you copy and paste a code from somewhere, the editor automatically formats the code according to the rules set by the user in LateralGM.
2. Allow the user to use tabs in the auto-formatting script rather than spaces.
3. When you select several lines of code and start from the longest line, the editor shouldn't violently jump all the way back to the left when moving the mouse out of the long line. What if I just wanted to select a snippet of the code in that line? This happens all the time in GM. It should only move left or right when you move the mouse to the side of editor window. Moving up and down is still done the traditional way, though.
4. The code editor checks the syntax X seconds after the user stops typing.
1: This is a later-down-the-road suggestion. We'll consider it. 2: Probably will be implemented as an option when we get there. 3: I think we resolved this by allowing the caret to remain in virtual post-line space, but be drawn at min(caret.x,line.length). 4: Sounds easy enough. Some of these are LGM, some are code editor, some are a combination:
- Expand/Collapse brackets (), {}, [], begin/end
- Fix indenting
- Refactoring(Rename variable, Rename Script, Extract Method)
- Auto-complete - see MonoDevelop for ideas(for instance, in MD "Case" matches "camelCase", etc.)
- If the above situation about camelCase is accepted, then some customization would be nice(camelCase vs underline_separated, etc.)
- Breakpoints
- Tab indents selection(in GM, tab doesn't indent selection, it replaces it)
- Shift+Tab unindents selection(or current line, or whatever)
- Script documentation support(Like /** @argument0 Instance to receive foobar */)
- Code style editing(replace begin/end by {} and vice-versa, remove all then statements, add ; to the end of lines where a ; is implicit, remove all unneeded ;, option to convert all "if (foo) stmt;" to "if (foo) { stmt; }", etc.) Note that after applying ANY of these changes, the code effect should be EXACTLY the same. This is an important detail to consider when implementing ; addition/removal.
- Code warnings like Eclipse and NetBeans and auto-fix.
- Option to auto-remove whitespaces at end of lines
1: Obviously planned. 2: Define "fix" 3: In consideration for later. 4: Will require clarification/investigation. The LGM code editor already has Ctrl+Space which looks for function names matching the typed text or abbreviated by it (e.g. sm<ctrl+space> suggests show_message) 5: Will consider for later. 6: Obviously planned. 7: Will consider for later. 8: In consideration for later. Will mostly be the job of ENIGMA, I believe. 9: In consideration for later. 10: Good idea. At this point, can we just have an external code editor option? Geany has all of these and it would be nice to have them before they're actually implemented.
Already an option. Preferences property "externalScriptEditorCommand" in LateralGM. By default, it's set to NULL indicating 'use internal'. Can be overridden by Java preferences (I posted a tutorial on how to do that manually somewhere. Not sure where now, though.)
|
|
« Last Edit: February 20, 2011, 12:46:19 pm by IsmAvatar »
|
Logged
|
|
|
|
|
|
|
IsmAvatar
|
|
Reply #10 Posted on: February 20, 2011, 07:27:14 pm |
|
|
LateralGM Developer
Location: Pennsylvania/USA Joined: Apr 2008
Posts: 877
|
luiscubal2: What you are describing sounds like an aspect of Code Formatting. It's already in consideration for the later stages. 4: Good idea for the later stages. RetroXToo lazy to make one. Get me a Java code monkey to write one. Until then: http://enigma-dev.org/docs/Wiki/Overriding_settingsRuskyPlease see Fede-lasse #4
|
|
|
Logged
|
|
|
|
Post made February 22, 2011, 12:25:06 pm was deleted at the author's request.
|
luiscubal
|
|
Reply #12 Posted on: February 22, 2011, 02:45:07 pm |
|
|
Joined: Jun 2009
Posts: 452
|
8. Tabs, like in Notepad++ and Visual Studio. This will allow for multiple code windows to be open and maximized at the same time. I think it would be a mistake to add this to the code editor. Tabs shouldn't be a code editor feature, but rather LGM. So any "tabs" system should be shared with room editors, object editors, etc.
|
|
« Last Edit: February 23, 2011, 03:23:39 pm by IsmAvatar »
|
Logged
|
|
|
|
IsmAvatar
|
|
Reply #13 Posted on: February 23, 2011, 02:06:49 pm |
|
|
LateralGM Developer
Location: Pennsylvania/USA Joined: Apr 2008
Posts: 877
|
Fede-lasse6: Please see Polygon#47: Code folding is already planned. 7a: Wut? 8: This is an already existing LGM feature request, and it would extend to all maximized resource frames, not just code editors.
|
|
« Last Edit: February 23, 2011, 03:23:50 pm by IsmAvatar »
|
Logged
|
|
|
|
|
|