Banner
Views: 763,642,414
Time:
8 users online:  Atari2.0, Fullcannon, hash, kamekku14, Mega, TheBiob, Yagami, Yoshivert99 - Guests: 37 - Bots: 135Users: 40,137 (1,949 active)
Latest: Cekoblox
Not logged in.
Super Scriptnes: SNES Code Editor
Forum Index - SMW Hacking - Resource & Tool Releases - Super Scriptnes: SNES Code Editor
Pages: « 1 »
I am doing a code editor, this will have the following features:

-Highlight commands, constants, tables, labels, etc...
-Highlight asar commands and defines.
-Highlight syntax errors and show you info about the error.
-Give you warnings if a label doesn't exists or if a branch exceeds the limits.
-Advice you if you are using a 16 bits constant and mode is 8 bits or vice versa.
-Know the number of bytes that will be inserted in any moment.
-Hotkeys, shortcuts, etc...
-Customizable colors for anything.
-Show documentation of routines (like visual studio does).
-allows cntrl+space to get recommendations of things that can be used (like defines, tables or routines).
-Compile into a rom and show asar errors, warnings and prints.

This code editor will be available as an independent tool or as a custom control on SMWControlLib, also will be available in Dyzen.


This is pretty cool, have often wanted something like this. What version of Asar is this currently supporting? The newest v1.61? And how is the performance? Does it hang occasionally during writing? Does it handle large source files well?

--------------------
Feel free to visit my website/blog - it's updated rarely, but it looks pretty cool!


Interesting tool you have there. I confess that, for a moment, I thought you were doing some new version of that ancient tool, asmdev (not that it wouldn't be nice having a newer version of asmdev, though). Now, as syntax highlighting is possible in several text editors, the features involving code preprocessing and analysis are truly nice to have. I'm looking forward to test your project.

--------------------


Signed Major Flare, a.k.a Br OW Hacker.


Originally posted by RPG Hacker
What version of Asar is this currently supporting? The newest v1.61?


1.61.

Originally posted by RPG Hacker
And how is the performance? Does it hang occasionally during writing? Does it handle large source files well?


For now dont have any problem of performance and can handle any size of source because only analize the changed text not the whole text, but have some bugs, i will upload a version when i fix some things and add labels, tables, asar commands and defines support.

Originally posted by Fierce Deity Manuz OW Hacker
Interesting tool you have there. I confess that, for a moment, I thought you were doing some new version of that ancient tool, asmdev (not that it wouldn't be nice having a newer version of asmdev, though). Now, as syntax highlighting is possible in several text editors, the features involving code preprocessing and analysis are truly nice to have. I'm looking forward to test your project.


Thanks :)

Something that recently came into my mind: will this also have some of the features that modern code editors are expected to have? Some examples:

-Automatic indentation (at the very least a simple one where it always remembers the indentation from the previous line, but you could also make a smart one where it automatically indents after a label and unindents on a new label etc.)
-Automatic whitespace conversion (spaces <-> tabs)
-Automatic line ending conversion
-Holding Alt and moving the cursor to edit multiple lines of text at once
-Commenting out highlighted code by pressing CTRL + K
-Search & replace features

That's all I can think of right now in terms of basic features. There's a few advanced features I can think of, but they might not be doable at all or only doable with a lot of hackery:

-Display values of defines/labels when hovering over them
-"Intelisense"/auto-complete

--------------------
Feel free to visit my website/blog - it's updated rarely, but it looks pretty cool!
Originally posted by RPG Hacker

-Automatic indentation (at the very least a simple one where it always remembers the indentation from the previous line, but you could also make a smart one where it automatically indents after a label and unindents on a new label etc.)


Yes will have auto-identation.


Originally posted by RPG Hacker
-Automatic whitespace conversion (spaces <-> tabs)


it will have an option to use tabs as real tabs or tabs as 3 or 4 white spaces. I personally prefere real tabs than 3 o or 4 whitespaces.


Originally posted by RPG Hacker
-Automatic line ending conversion


I didn't understand that.


Originally posted by RPG Hacker
-Holding Alt and moving the cursor to edit multiple lines of text at once


it wont be on the first version, but i will include that on the future.

Originally posted by RPG Hacker
-Commenting out highlighted code by pressing CTRL + K


i didn't understand this point.

Originally posted by RPG Hacker
-Search & replace features


Yes, will have search (hotkey: cntrl+f) and replace, also with double click over a word will highlight all copies of that word. Also will have "Change Name" function of visual studio.

Originally posted by RPG Hacker
-Display values of defines/labels when hovering over them


it will display values of defines and the Hex code for commands. Now for labels probably is harder because the tool can't know what hijack will use the code.

Originally posted by RPG Hacker
-"Intelisense"/auto-complete


Probably i will include the classic cntrl+space to show options, but i need to do some research to do a good auto-complete.

Also a lot of features won't be in the first version, but i will include them in future versions.

Sounds good so far!

Originally posted by anonimzwx
Originally posted by RPG Hacker
-Automatic line ending conversion


I didn't understand that.


I'm refering to conversions between different newline (\n) formats. For example, conversions between Windows line endings (CR LF) and Unix line endings (LF). This can be very pratical when you work on some code from different computers with different OSes installed, but want line endings to stay consistent, no matter what system you're working on. For example, when working on Windows you should be able to tell the application to use LF as line endings instead of the native CR LF (vice versa when working on Unix). And when opening a text file on Windows that only has LFs for line endings, it should still correctly treat them as line breaks (notepad.exe, for example, would completely ignore them and display everything on a single line).

Originally posted by anonimzwx
Originally posted by RPG Hacker
-Commenting out highlighted code by pressing CTRL + K


i didn't understand this point.


Let's say you have this piece of code:

Code
MyRoutine:
	lda #$10
	sta $00
	rts


Now you highlight the two middle lines (the lda and the sta) with your mouse cursor and press CTRL + K (in Visual Studio, you would press CTRL + K and then CTRL + C). The code editor should now automatically do the following:

Code
MyRoutine:
	; lda #$10
	; sta $00
	rts


Effectively preventing the code from being compiled. Now if you select the same lines again and press another combination (in Notepad++ it's CTRL + Q, in Visual studio it's CTRL + K and then CTRL + U), those semicolons should be removed again, making the respective lines of code be compiled again. That's the gist of it.

--------------------
Feel free to visit my website/blog - it's updated rarely, but it looks pretty cool!
Aaa, yes it will have both, also will have cntrl+tab to add an indentation and cntrl+shift+tab to remove an identation.

Ah, nice! Didn't think about that, but a useful feature as well.

--------------------
Feel free to visit my website/blog - it's updated rarely, but it looks pretty cool!
a little preview of the tool:



For now it highligh syntax errors, highlight labels, sublabels, comments, commands, arguments and signatures of defines. Still i have some problems with defines to know when they cause a syntax error. It have good performance, because i am using ScintillaNET (the same library used by Notepad++).

For the first version i will do:

Highlights: Commands, errors, arguments, macros, defines, asar commands, etc...

Hotkeys: Paste = Cntrl+V, Copy = Cntrl+C, Comment Code = Cntrl+K, Add identation = Cntrl+tab, Remove Identation = Cntrl+Shift+Tab, Show Suggestions = Cntrl+Space.

Autocomplete for some ram Address: tool will suggest you a define that is on the file "./ASM/Defines.asm". Also will suggest you defines that are on the current file.

For now this are the defines that will be included by default: Defines

Autoidentation.

Search and Research (Cntrl+F): You can find thing by perfect match, case sensitive match or by regex, then you can replace them.

Auto-convertion for end lines.

Tabs to open multiples files.

Customizable scheme: You can change font and all colors of the editor.

I definitely like it! #smw{:TUP:}

A minor suggestion: Maybe use a different color for comments starting with ;@ since those lines are recognized as special commands by Asar. You could use a lighter shade of green, for example.

--------------------
Feel free to visit my website/blog - it's updated rarely, but it looks pretty cool!
Originally posted by RPG Hacker
I definitely like it! #smw{:TUP:}

A minor suggestion: Maybe use a different color for comments starting with ;@ since those lines are recognized as special commands by Asar. You could use a lighter shade of green, for example.


oh i forgot that thanks, i will change the color of that also i will change the format of super snescript tags too, i was thinking use ";@" but probably i will use another format, because that tags they will be used to show documentation about things on the editor on future versions, they will have another color too.

I am so glad that this exists. It's surprising that nobody's really done something like this despite SNES homebrewing having been a thing for around 20 years or so. You're doing the Lord's work.
Pages: « 1 »
Forum Index - SMW Hacking - Resource & Tool Releases - Super Scriptnes: SNES Code Editor

The purpose of this site is not to distribute copyrighted material, but to honor one of our favourite games.

Copyright © 2005 - 2019 - SMW Central
Legal Information - Privacy Policy - Link To Us


Total queries: 21

Menu

Follow Us On

  • Facebook
  • Twitter
  • YouTube

Affiliates

  • Talkhaus
  • SMBX Community
  • GTx0
  • Super Luigi Bros
  • ROMhacking.net
  • MFGG
  • Gaming Reinvented