? Alternate Program Editor (DEMO) ● SmileBASIC Source

Sign In

Register
*Usernames are case-sensitive
Forgot my password
Creep into the Halloween / Horror Programming Contest (Deadline Extended)

Alternate Program Editor (DEMO)

Submitted
Updated
Author
MZ952
Public Key
REMOVED
Min. Compat.
All
Version
Demonstration
Rating
7 votes
Description Load the PRG "FORMAT2" into slot 2 for this to work, sorry forgot to add this. Also, you must have some code in Slot 1 (you can load boguscode into it) so that it doesnt try to manipulate code that doesnt exist. Program currently undergoing major revision, expect the Beta in a couple weeks. Current date: 4/11/16 As the program is in its early production phases, the amount of usable features is limited. However, there are many planned features i will list and by releasing this demo and getting the feel of my program, i hope that some may contribute some ideas they wish to see in it. The idea behind this is to create a full fledged replacement for the original code editor SmileBASIC uses. This is challenging enough, due to all the features present in the original. I am ultimately coding this for myself to use, so it has got to be better than the original. Here are the features and aspects: Alternate minimalistic keyboard, with features necessary for programming. Viewing code on dual screens Touch screen functionality for purposes such as highlighting code, drag and drop, scoll, on screen utilities other than keyboard, et cetera Onscreen calculator for swift, painless number crunching Onscreen note taking (apart from code), can be typed or hand drawn (schematic purposes). A never before seen form of syntax highlighting which can denote loops and conditional statements. Can type code in all RGB colors and Multiple Text Sizes. A toolbar expandable on the lower screen which you can access all the sub-applications like notes, TXT viewer and so on Smart cursor movement Compacting code into labeled folders which can be expandable and manipulated (organization purposes). A command index similar to the one on the default keyboard for speedy typing Select, Cut, Copy and Paste (a necessity). A terminal for executing some code (will most likely run the code you type in a different slot, then return to the main program) An intuitive way for finding that RGB color you want (like a color wheel), most likely a sub-program on the toolbar. Double viewing screen mode (removes keyboard completely, viewing code on two screens), probably mapped to R button or something. A separate double viewing mode where you see even more code on the bottom screen, but are equipped with a smaller keyboard. Unlimited code slots Viewer for graphical images A copy and paste clipboard, for copying and pasting more than a single element of code. Those are my ideas this far. Now, if you avid coders have any suggestions, i'm completely open to them. I'm sure you have a few things you'd change about the smilebasic code editor if you could. A few of you may be concerned about the program running into errors and you losing the portion of code you've worked on. Another feature i plan is an autosave feature, which will slowly export code to a program slot and being imperceptible to the user (when exporting massive amounts of code from the editor, a tremendous delay is caused as the loop runs). I will also map the total export feature to a button or button combination for ease. My program uses line wrapping, each line may be only 40 characters long. You can easily import a program you're working on by loading it into slot 1 and running my program (which should be in slot 0) My program has a simple (but not for very long) form of metadata it uses for things like colors and text size, it is loaded into slot 2. Because my program uses the print function, trying to avoid printing bugs when printing CHR$(10) can be tricky, so, when you import the code into the editor, all instances of CHR$(10) are removed, as well as the text being wrapped 40 characters long. The ENTER character is replaced with CHR$(294), which, in the code editor, functions the same as the enter key. It basically tells the exporting algorithm where to break to the next line of code when un-wrapping the code. My point: make sure you don't have CHR$(294) in your program (its not a commonly used character). Conventional syntax highlighting, as you know it, is most likely not going to be fully implemented. Possibly to an extent, but nothing like the original. You can type text in different sizes and all RGB colors, though it should be known that overuse of this feature does cause graphical artifacts on the console. It may look weird, but no erroring. As of now, i have not completed the keyboard, it only types the letter A (as a debugging test) EDITS: The top screen and the bottom screen will soon act as totally separate, editable screens. You can toggle the two screens using the R button. It will basically allow you to be at two places inside the code at a time. New graphics engine, eliminating most if not all graphical artifacts. Planning more complicated touch capabilities for editing code. Keyboard completed, missing characters will be added to the accessible tool bar. Sound effects added. X Deletes lines A Enters a line B Backspaces in the current line Y Exports (does not work/will error) Stick for fast movement Many improvements for typing text. I cannot stress enough how this application uses line wrapping, to end a line and begin a new one, you must have the CHR$(294) at the end of it, which is provided on the keyboard. If you, for example, type an entire program without any of these characters, your entire program will be exported as a single line of code. Also note that the cursor edits the characters behind it, not the character it seems to be on. In the beta version, the tool bar will be loaded with its minor applications, and a rough version of syntax highlighting should be usable, as well as functional exporting.
Categories
Keywords
46 Comment(s) Simeon Simeon Scholar Received for knowing a great deal about programming topics Achievements Amazing Page Hidden Achievements Drawing I like to draw! Hobbies Yeah I really look forward to this concept being pushed further, I would love a new keyboard layout and design, if a fully compatible keyboard like this gets made, then I can make a clone of the program editor that implements the keyboard, then SmileBASIC will get a whole lot more customizable MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Expect a beta release in less than a week. Simeon Simeon Scholar Received for knowing a great deal about programming topics Achievements Amazing Page Hidden Achievements Drawing I like to draw! Hobbies Oh awesome! snail_ snail_ Helper Received for being very helpful around SmileBASIC Source Achievements Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength OSP Contest 1 Contest Participant I participated in the first SmileBASIC Source OSP Contest! I personally believe a program like this would be great with some kind of IME or even the ability to replace the entire keyboard. Bonus points if programmers can implement their own input methods. https://smilebasicsource.com/forum?ftid=931 bump MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies It appears people actually like this idea. I have a lot developed towards this kind of program, and I believe I will continue it to a wholly finished program. However, this particular program is completely dead. The code is far outdated, and I will be removing the key soon. mia mia Night Person I like the quiet night and sleep late. Express Yourself Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Video Games I like to play video games! Hobbies How interesting. I considered creating something this has, an alternative keyboard, in SmileBASIC's predecessor. I never got around to actually trying to make one, I think. Miopasid Miopasid Is this project dead? MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies *Sigh* Yes, this version is deceased. I've made many of versions unpublished after this one with some very fine features. I've been very unproductive with programming lately. I'll see to it completing my latest version however. It's about time I put this project under wraps. Simeon Simeon Scholar Received for knowing a great deal about programming topics Achievements Amazing Page Hidden Achievements Drawing I like to draw! Hobbies Aw you should try to finish the keyboard This has so much potential I can't believe I didn't see this post until 8 months later :\ You did a good job though MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Oh! But it is finished! Perhaps I should let loose a demonstration of it. The keyboard I've created is fully customizable, has key animations, and can be translated, resized and oriented across the screen. Not to mention it uses no sprites. A2D_apps A2D_apps Minecraft Is Awesome! I love Minecraft! Express Yourself Zelda Is Awesome! I love The Legend Of Zelda! Express Yourself Pokemon Is Awesome! I love Pokemon! Express Yourself hey um can i use this A2D_apps A2D_apps Minecraft Is Awesome! I love Minecraft! Express Yourself Zelda Is Awesome! I love The Legend Of Zelda! Express Yourself Pokemon Is Awesome! I love Pokemon! Express Yourself in quicktool + TheV360 TheV360 April Fool's 2017 Contest Winner I won the SmileBASICSource April Fool's 2017 Contest! Programming Contest First Day Joined on the very first day of SmileBASIC Source Website Night Person I like the quiet night and sleep late. Express Yourself It's unfinished and buggy right now, the developer hasn't even finished the keyboard yet. Also, please remember that there is an edit button on your posts AnswerXOX AnswerXOX Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Great Page Hidden Achievements Pokemon Is Awesome! I love Pokemon! Express Yourself And the beta never came :P walorskia walorskia Is this useful? MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Useful? For what? What context? I'm not sure what you mean. raimondz raimondz First Week Joined in the very first week of SmileBASIC Source Website Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Night Person I like the quiet night and sleep late. Express Yourself I tried to run it on a O3DS but it crash when it start up(It say Subscript out of range in 0:327) Minxrod Minxrod Summer 2016 Contest Participant I participated in the SmileBASIC Source Summer 2016 Contest! Programming Contest Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Pokemon Is Awesome! I love Pokemon! Express Yourself Add code to SLOT 1. It fixed it for me ;) raimondz raimondz First Week Joined in the very first week of SmileBASIC Source Website Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Night Person I like the quiet night and sleep late. Express Yourself It worked, thanks Minxrod Minxrod Summer 2016 Contest Participant I participated in the SmileBASIC Source Summer 2016 Contest! Programming Contest Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Pokemon Is Awesome! I love Pokemon! Express Yourself Ok: I downloaded, ran program, pressed down on circle pad and it crashed immediately. This is a bug I think...? EDIT: Ran a few more times, still just crashes no matter if I touch a key or push a button. EDIT 2:Added some random code to sloot 1 and it worked, it just can't start empty I guess. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Yes i am aware of the syntax error at 3 sixty something, i meant to remove the key (which i am doing now). To get it to work, you have to basically put this in the beginning of the code: LOAD"PRG2:FORMAT2":LOAD"PRG1:BOGUSCODE" i forgot this. i am completely redoing this program, the code is too sloppy for me and im afraid it will lead to further bugs. Going to improve upon its structure and its means by which it prints its graphics. Sorry about that by the way, i tested it before i uploaded it but i completely forgot that i already had those two prg's in those slots, and my program didnt load them. AnswerXOX AnswerXOX Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Great Page Hidden Achievements Pokemon Is Awesome! I love Pokemon! Express Yourself You can always just do PRGEDIT 1:PRGSET CHR$(13) :P That would be one enter, then it would be code, bam, empty code too MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies I've managed a syntax highlighter, but there is one major issue. As i had predicted, adding a syntax highlighter would slow down the program and make it stutter. With syntax highlighting, the program is no longer as smooth, and the more syntax sensitive words you use, the more lag the system will experience as you transverse your code. I'm left with two options: 1) Use a higher vsync (which will slow the system, but it manages to somewhat hide the graphical blemishes) and limit the amount of syntax sensitive characters to only the necessities. or 2) Say "screw it", have all the syntax possible, and have a very poor looking code editor. Now, i prefer the first option, as i am designing this for my own use as well, so i must ask you coders, what are the bare necessities for syntax highlighting? Try to make a list. (Edit): Also, don't worry those who want to use this for other languages besides SB, i have this setup specifically for different syntax languages. The syntax data is stored as data under a label "@syndata", which the program reads upon startup.You can write as many of your own syntax sensitive words into the data label. (Edit 2): Holy crap i just had an awesome idea and it works. I've rid the system of the lag when moving and transversing code by simply this: If the user offers no input to the system for a certain amount of time, it then draws the syntax highlights. So, you wont be able to see the highlighting when moving around but if you don't touch the screen or anything for half a second or so it is drawn. Unclesporky Unclesporky One recommendation I would have is user-configured button functions. Bugs me so much that B and X do nothing in the default editor. You've chosen some good functions for them, but one thing I've found myself really wanting is spacebar on one of the buttons, when I'm going through and indenting a block of code. Another button function that might be nice is holding down a button and pressing left and right to select code, then releasing the button immediately copies...maybe then pushing the same button again could paste, freeing it up for copy again, or alternatively a second button could be assigned as a dedicated paste. Optionally at the user's discretion , of course. You could even use R and L as modifiers if you hold them down...hold R and press left and right to select, while holding R press A to copy, B to paste, X to cut etc. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Yes! Intuitive use of the buttons is definitely a good idea! Right now, the only way to change the button functions would be to go into the code and change it manually, but i hope (eventually) to have total and free manipulation and customization of this program. I mean everything, down to the keyboard. bluemonkey1111 bluemonkey1111 Pokemon Is Awesome! I love Pokemon! Express Yourself Avatar Taboo I didn't change my avatar for 180 days Website Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength Won't let me on Smilebasic Source on my 2DS why? bluemonkey1111 bluemonkey1111 Pokemon Is Awesome! I love Pokemon! Express Yourself Avatar Taboo I didn't change my avatar for 180 days Website Beginner Programmer I'm just starting out! I'm still trying to grasp the basics. Programming Strength I like it! Guzzler Guzzler First Week Joined in the very first week of SmileBASIC Source Website Drawing I like to draw! Hobbies Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength I like the concept. blizord blizord Whenever I tap the touch screen it types "A". Edit: Oops, should have read the description. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Haha yeah, ive got a functioning keyboard and i'm updating the demo shortly. 12Me21 12Me21 Admin Syntax Highlighter Received for creating the code syntax highlighter on SBS Syntax highlighting it relatively simple compared to some of the other things you're doing just remember that things like BGMPLAY 1ACLS are valid (I would recommend making a list of characters that ARE allowed before and after each type of command) for example, before functions (purple by default), there can be numbers, parenthesis, etc, and after can be -, and some others; you'll need to do some testing. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies i experimented with highlighting before. ive found that scanning all the text it displays on the screen and matching everything to its corresponding highlight causes runtime delays. lag. I've further tested an idea where i have a rendering algorithm find all the syntax highlighted stuff in the chunk of imported code, and keep tabs on them (their Y coordinates) as the code gets altered, though it is prone to its bugs. The upside to it is that it only has to track if new at the cursor position syntax has been typed or old syntax has been erased. Lumage Lumage Head Admin Day Person I like the warm sunshine and wake up early! Express Yourself Gardening I like to garden! Hobbies Touhou Project Is Awesome! I love Touhou Project! Express Yourself ooooo OOOOOOOO Looks like you've got a pretty big list of plans already, but here are some thoughts:
  1. -Configurable highlighting schemes -- Such that if I want to write Lowerdash or, heck, even C in this, I can and still be able to see.
  2. -Automatic indentation
  3. -Do um. Do something about those fonts, please.
  4. -Consider making it a Smiletool. Then you can both access all the files they might want and also not waste slots.
  5. -An "export minified" feature, to save a few bytes for upload.
MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Automatic indentation is a good idea, i can incorporate it when i begin syntax highlighting, though it may be tricky, as a line of code can only be 40 characters long onscreen, until exported. Good idea nevertheless. I'm uncertain what you mean behind configurable highlighting schemes. If lowerdash or C are compilers, they should be able to compile exported code into legal SB code. I think you are saying have my program use a syntax highlighting for other programming languages. If so, that may not be possible, this is centered around the SmileBASIC language. Maybe in the far future i can allow syntax highlighting plugins that users themselves can easily write. thats far though. Can you elaborate on "export minified"? 12Me21 12Me21 Admin Syntax Highlighter Received for creating the code syntax highlighter on SBS that means removing extra spaces and line breaks, and shortening variable names, I think. You might want to look at my automatic indenter. it's not PERFECT, but it's very good at detecting commands (could also be reused for syntax highlighting) MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Removing extra spaces and linebreaks. My code originally did this and i removed the feature.. Haha. well, i can do this, yeah. Might create some kind of settings page for all this crap, to toggle on/off. Lumage Lumage Head Admin Day Person I like the warm sunshine and wake up early! Express Yourself Gardening I like to garden! Hobbies Touhou Project Is Awesome! I love Touhou Project! Express Yourself removal of spacing characters and comments, variable shortening. Anything to make the program as small as possible without really changing the actual instructions. Also, while Lowerdash can compile into SB code, the point is that you want to write it in non-SB. The trouble is that the NORMAL editor doesn't recognize languages other than SmileBASIC, so when writing for those others you don't get syntax highlighting. Since you have this editor, it makes sense to make up for that. I think it was LEX that was of particular interest for language syntax work. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Ah, i see. Should these different syntax highlightings be similar in manner to SB's (Highlighting particular commands or phrases), i think it can be accomplished. Since i see the demand for Syntax Highlighting, i guess i should consider implementing it fully. Maybe, the user can write DATA at a specific label to define which commands to highlight and what colors to highlight them in. What i'm really focusing on is my idea of syntax highlighting, which would help the user better see the flow of their code on the graphic interface. (edit): As my program isn't quite built around changing individual character's colors, how would you feel if the syntax highlighting took place on the graphic screen by drawing a filled box behind the command with whatever color it does? Otherwise, i would need to revise GREATLY my text drawing system, and i could not guarantee an artifact-less presentation while using it. SB doesn't seem to handle loads of graphics being erased and redrawn frequently well. Lumage Lumage Head Admin Day Person I like the warm sunshine and wake up early! Express Yourself Gardening I like to garden! Hobbies Touhou Project Is Awesome! I love Touhou Project! Express Yourself I'll do you one better: Do the back-highlighting, but then make an inverted font so it just shows through. That'd be fast. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies Has someone already made an inverted font? That seems like a lot of work. DrZog DrZog Wouldn't an inverted font be just f(x)=~x ? Doesn't seem to be any trouble. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies uh no, unfortunately its not a concern of an inverted equation. It's a concern of literally designing an inverted font. (Your normal font has solid pixels making up the character, while this inverted font has solid pixels filling the space around the character, leaving a 'hollow' version of the character inside). Get it? Lumage Lumage Head Admin Day Person I like the warm sunshine and wake up early! Express Yourself Gardening I like to garden! Hobbies Touhou Project Is Awesome! I love Touhou Project! Express Yourself I'm not sure I see the problem Even though the default font isn't great, it's still readable doing this. You could do the same to any font, it doesn't have to be "designed" for this. MZ952 MZ952 Intermediate Programmer I can make programs, but I still have trouble here and there. Programming Strength Drawing I like to draw! Hobbies Reading I like to read books! Hobbies What is that? I'm afraid i do not know much of anything about fonts. the only way i know how to create a font is to use FONTDEF and manually type in the font code. Lumage Lumage Head Admin Day Person I like the warm sunshine and wake up early! Express Yourself Gardening I like to garden! Hobbies Touhou Project Is Awesome! I love Touhou Project! Express Yourself I changed the transparency to white and the white characters to transparent, then put color beneath it. I think the problem is that you're forgetting that the font sheet is a GRP just like everything else. http://smilebasic.com/en/reference/#file Go through and filter it like you would any other image, then load it into GRPF. snail_ snail_ Helper Received for being very helpful around SmileBASIC Source Achievements Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength OSP Contest 1 Contest Participant I participated in the first SmileBASIC Source OSP Contest! Or you could just COLOR 0,#TWHITE