Code editor improvements?

If there is something important you think is missing in the current version of ZGameEditor then you can post a feature request here!

Moderator: Moderators

Post Reply
User avatar
VilleK
Site Admin
Posts: 2355
Joined: Mon Jan 15, 2007 4:50 pm
Location: Stockholm, Sweden
Contact:

Code editor improvements?

Post by VilleK »

With the impressive projects recently posted here with lots of code in ZLibrary-components I'm sure you have thought of ideas on how the editor could be improved while writing and testing all that code. What can be done? What is frustrating with the current editor? Here are some suggestions that I've already noted:

- standard right-click menu with copy/select/search etc
- improved code-completion
- optionally turn off code-completion (or set delay before completion is displayed)
- maximize code editor

Anything else?
User avatar
diki
Posts: 140
Joined: Thu Sep 11, 2008 7:53 pm
Location: GMT+1
Contact:

Post by diki »

agreed; i sometimes copy long code over to notepad++ for more comfortable editing, although i need to skip back frequently to look at the project tree for reference.

- maximize editor
with an option to retain the project tree, maybe?

- improved code completion
i second that one; the automatic completion often misinterprets the input (e.g. expanding something that was not meant to be completed). a variable delay or keyboard shortcuts (ctrl-space to pop it up / explicitly demand completion) could be nice. i bet there are some good ideas one could copy from IDEs like eclipse, for example.
edit: i see that ctrl-space is already in there; i didn't notice because the autopopup distracted me.

- improved indentation
indenting code is a bit uncomfortable currently. i don't mind 2-space instead of 4-space indents (they are more readable in the small window). if it is possible, the tab key could indent instead of taking focus from the code window (indenting with space is sometimes tedious). shift-tab and ctrl-shift-tab to increase/decrease indent on a marked block of code is also handy.

- markup
marking the names of components (variable / objects) in the code might be helpful (or not; i'll have to mock it up to decide;)).
edit: that's probably nonsense, since those are apparently not usually marked in any other language either. looks pretty though.
User avatar
jph_wacheski
Posts: 1005
Joined: Sat Feb 16, 2008 8:10 pm
Location: Canada
Contact:

Post by jph_wacheski »

a simple Find/Replace will also be usefull,. I often change the name of variables I have created and used in multiple locations in some code, . currently a pain!

yeah that is when the code compleation get me too,. type color.r and get color.random,. I would set it to only actually complete when I hit the key combo.
iterationGAMES.com
User avatar
VilleK
Site Admin
Posts: 2355
Joined: Mon Jan 15, 2007 4:50 pm
Location: Stockholm, Sweden
Contact:

Post by VilleK »

These are all good suggestions and just what I was looking for. I'll try to fix them bit by bit.
User avatar
VilleK
Site Admin
Posts: 2355
Joined: Mon Jan 15, 2007 4:50 pm
Location: Stockholm, Sweden
Contact:

Post by VilleK »

I have now fixed most of these items in the latest beta except I did not find a good technique to maximize the editor. However if you click the editor header (the "Code editor" caption) the height of the code editor will be swapped with the window above it. I'll make a better solution for this in a later release.
User avatar
Lupo
Posts: 76
Joined: Wed Sep 09, 2009 6:21 pm
Location: Montevideo, Uruguay

Post by Lupo »

Thanks Ville!

Now It's easier to develop in the built-in editor.

I had this couple of issues working in the code editor:
- The Del key is not working, Backspace is working.
- when you copy/paste a couple of line at the end of the editor, the lines copied did not appear completely or other lines are shown, but if you scroll up/down, they show correctly.

Again thanks for the improvements, they DO a difference.
Close, but not there yet.
User avatar
VilleK
Site Admin
Posts: 2355
Joined: Mon Jan 15, 2007 4:50 pm
Location: Stockholm, Sweden
Contact:

Post by VilleK »

Thanks Lupo, I can reproduce those bugs and I'll try to fix them to this release.
User avatar
y offs et
Posts: 418
Joined: Wed Apr 22, 2009 4:26 pm
Location: BC, Canada

Post by y offs et »

It's probably not "important", but I find it annoying when I go to click/slide the bottom slider, and hit the help button instead.
.
As a fix, since Pascal doesn't end a code line until it finds a semi-colon, I've started cutting up long code lines into stacked chunks, and just don't use the slider any more.
Post Reply