Ultimate Amiga

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2   Go Down

Author Topic: AMOS Pro 2: New feature suggestions List  (Read 17624 times)

0 Members and 2 Guests are viewing this topic.

Lonewolf10

  • AMOS Extensions Developer
  • AMOS Dev
  • A2000
  • *****
  • Karma: 3
  • Offline Offline
  • Gender: Male
  • Posts: 618
    • http://www.aliensrcooluk.com
AMOS Pro 2: New feature suggestions List
« on: January 19, 2013, 09:35:59 PM »

Hi,

Just starting this thread as I can't seem to find one that would be appropriate for the following suggestions. Feel free to add your suggestions or feedback.

*** NB:  AGA, TOME and bugs are discussed in other threads ***


 - The ability to view a list of all labels within a program via editor menu
 - The ability to view a list of all Procedures in a program via editor menu
« Last Edit: January 22, 2013, 12:48:05 AM by MadAngus »
Logged

MadAngus

  • There is no spoon.
  • Site Admin
  • A500
  • ****
  • Karma: 5
  • Offline Offline
  • Gender: Male
  • Posts: 497
  • AMOS Docs / AIAB Dev
    • AIAB (Amiga In A Box)
Re: AMOS Pro 2: New feature suggestions
« Reply #1 on: January 22, 2013, 12:09:31 AM »

Hi,

Just starting this thread as I can't seem to find one that would be appropriate for the following suggestions. Feel free to add your suggestions or feedback.

The Feature requests and bug reports board (This board) is for just that ;).

As there isn't a list of features thread we can use this thread as a place to list them, but no discussion.

Please create a new separate discussion thread for each feature.

Logged
My shadow says otherwise.

Umpal

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 37
  • Programming and graphic
Re: AMOS Pro 2: New feature suggestions
« Reply #2 on: March 28, 2016, 02:22:07 PM »

I don't know how about you guys but I miss a lot Syntax Highlighting feature in AMOS Editor.
This is how it could look (don't mind colors, it's just an example and the palette could be adjustable):



And compared side by side:

Logged

bruceuncle

  • AMOS Dev
  • A500
  • *****
  • Karma: 6
  • Offline Offline
  • Gender: Male
  • Posts: 425
  • WINUAE Amiga User
Re: AMOS Pro 2: New feature suggestions List
« Reply #3 on: March 28, 2016, 04:18:59 PM »

I'm using my phone so I'll reply in full tomorrow. I worked on this while I was in hospital and in physio, and it's very possible.  Downside is that it slows the editor display down by a factor of three!  The editor cunningly arranges matters so it only has to write text to one biplane, which is why the editor is quick.  So slow Amigas would probably choke a bit on an eight colour display using all three biplanes.

Looks good.
Logged
Repeat after me ...  "The AMOS Pro architecture is complex but it is not complicated."

SamuraiCrow

  • compile-time wierdo
  • Forum Mod
  • A1200
  • *****
  • Karma: 5
  • Offline Offline
  • Gender: Male
  • Posts: 946
  • Compile-time wierdo
Re: AMOS Pro 2: New feature suggestions List
« Reply #4 on: March 28, 2016, 04:29:45 PM »

Using the Copper list to scroll each line of text would work well for 3 bitplanes.  All that is needed is a y-unlimited tile scrolling algorithm like in the Amos remake of Horace Goes Skiing.
« Last Edit: March 28, 2016, 05:44:49 PM by SamuraiCrow »
Logged

Umpal

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 37
  • Programming and graphic
Re: AMOS Pro 2: New feature suggestions List
« Reply #5 on: March 28, 2016, 06:54:20 PM »

I worked on this while I was in hospital and in physio, and it's very possible.

You, sir, just made my day  ;D

Quote
Downside is that it slows the editor display down by a factor of three!

Fine by me! We can safely assume that nobody's using a non expanded Amiga for coding nowadays ;)
I will ask all my family to vote for such feature if it helps ;D

Using the Copper list to scroll each line of text would work well for 3 bitplanes.  All that is needed is a y-unlimited tile scrolling algorithm like in the Amos remake of Horace Goes Skiing.

Sounds fantastic but if it requires a whole new routine for the editor then I guess it's too complicated and time consumer. I've read some posts and I see you're involved in fixing the sources too so I keep my thumbs up for éxito in this matter. Will see what Uncle says tomorrow as it seems he already have something in his pot
« Last Edit: March 28, 2016, 07:34:32 PM by Umpal »
Logged

Umpal

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 37
  • Programming and graphic
Re: AMOS Pro 2: New feature suggestions List
« Reply #6 on: March 28, 2016, 10:16:14 PM »

I would embrace another upgrade to actual AMOS Pro 2.xx: Instruction Select Case.



This would eliminate a looot of If conditions. Is it difficult to implement? I mean for you guys. What do you think about it?
Logged

SamuraiCrow

  • compile-time wierdo
  • Forum Mod
  • A1200
  • *****
  • Karma: 5
  • Offline Offline
  • Gender: Male
  • Posts: 946
  • Compile-time wierdo
Re: AMOS Pro 2: New feature suggestions List
« Reply #7 on: March 28, 2016, 10:47:24 PM »

I think the new features should mainly go into the version 3 branch.  2.1 has been declared as a bug-fix release.
Logged

Umpal

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 37
  • Programming and graphic
Re: AMOS Pro 2: New feature suggestions List
« Reply #8 on: March 29, 2016, 01:24:22 AM »

You are right, I agree. Fixes first! But for the other hand... If something could be quite easy to introduce and really useful then I would give it a go before because, let's be honest, version 3 is not going to happen very soon. Correct me, but introducing one by one feature is much easier than making a whole bunch of instructions that need a lot of internal and then beta testing, and then fixing and then... Of course all is possible but we, especially you guys doing this wonderful stuff, are limited by time. Just my cent. I wish you the best on this project with all my heart.
Logged

bruceuncle

  • AMOS Dev
  • A500
  • *****
  • Karma: 6
  • Offline Offline
  • Gender: Male
  • Posts: 425
  • WINUAE Amiga User
Re: AMOS Pro 2: New feature suggestions List
« Reply #9 on: March 29, 2016, 02:38:55 AM »

I'm using my phone so I'll reply in full tomorrow. I worked on this while I was in hospital and in physio, and it's very possible.
The text you see on the editor's screen gets there from a buffer.  The buffer uses fixed length text lines, each 256 bytes long.  So the code can find any cursor position by multiplying the Y coord by 256 (shift eight bits to the left).  By increasing each line to 512 bytes, the second 256 bytes can hold the colour of each character.  Simply offset 256 bytes from a character (eg. 256(An)) to get a character's colour.

The colour bytes can be written into the buffer during the Detokenise process.  This takes a line of AMOS Basic Tokens and converts them back to text for display on the screen.  When it processes each token, the token's type is obviously known and the appropriate colour byte(s) can be derived.  The available types are:

Keywords     AMOS Basic instructions, punctuation, math and logic symbols.
Names     The names the programmer has given to Variables, Labels and Procedures.  It is not possible to split these up and use a different colour for each as Detokenise() doesn't 'know' the context until the program is Verified (the Test and Run process).
Numeric Literals   Any integer, single, double, hexadecimal and binary numbers in the code.
Text Literals     Any text enclosed in single or double quotes.
Comments     Any text following a Rem or '.

A colour also needs to be defined for the inverted display of selected text (blocks).

When time comes to print to the screen, the function just needs to check if chroma-coding is switched on and use modified routines to do the work.  This involves inserting appropriate 'escape' sequences into the text each time the colour bytes change value.  So the output has to be buffered (using the general purpose Buffer(A5)) then printed as a text string.  This is much faster than doing it character by character to the screen.  There are a few places where single characters are output to the screen (eg. as you type stuff in) which would default to the Keywords colour.  The chroma-coding would occur as you move off the current line, in the same way that AMOS 'corrects' text case and spacing now when you move off a line.

I did a mockup of what it could look like a while back (program attached) that looks like this:



The stuff at the top of screen was just to see what standard palette colours look like.  Modify the AMOS code to try different colours.

In addition, the text case for Keywords and Names is already implemented in AMOS Pro.  The settings are in the editor config file (DtkMaj1 and DtkMaj2) but not currently editable.  So they're fixed as mixed-case for Keywords and upper-case for Names.  The options are mixed-case, upper-case or lower-case.  So you could have Keywords in upper-case and Names in lower-case if they were made editable (see 'prrof of concept' below).

There's also seven longwords of free space available for 'future use' (thanks François!) so storing the chroma-coding settings is no problem - one byte each:

Ed_Chroma_Keyword
Ed_Chroma_Name
Ed_Chroma_Number
Ed_Chroma_String
Ed_Chroma_Remark
Ed_Chroma_BlockColour
Ed_Chroma_Flag


The flag is used to switch chroma-coding on and off as not everyone likes to use it.

I did a 'proof of concept' for the DBL code needed to write a dialogue to edit all this (file also attached - excuse the messy, this was just to see if it was feasible - it is  ;) ).  It looks like this:



And with a dropdown for the colour selection:



The layout and design leave a lot to be desired, but this was just to prove it's possible.  It's one thing to work out how to implement chroma-coding and another thing altogether to enable the user to set it up!  I would move the dropdown buttons to the right of each colour and drop the dialogue down there rather than over the colours as in the above.  Also, there's no labels for the text case three-state buttons (I just wanted to see if three-state was possible).  I envisaged a sample window on the right to display what the result looks like - would have to be a machine code program to get the necessary speed.  Anyway, these are just musings.

I've attached the AMOS progs that produced the above screens.  You'll also need the attached AMOSPro_Default_Resource.Abk file to replace the original in the APSystem directory of your AMOS installation.  It contains the images for the multi-state buttons and some revised DBL code for the file selector.

The Select Case you speculate on is just not feasible without major code changes.  It's a structural instruction (like Do ... Loop and If ... Then ... End If) that needs offsets inserted during Test and Run and would require major changes to the Verify() code.  Any changes that affect program structure are almost impossible  :(

Now, back to the bugs as this is all enhancement and not fixes!  And now I'm recovering and more active, I want to get stuff out there instead of just talking about it. ;D
Logged
Repeat after me ...  "The AMOS Pro architecture is complex but it is not complicated."

Umpal

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 37
  • Programming and graphic
Re: AMOS Pro 2: New feature suggestions List
« Reply #10 on: March 29, 2016, 04:53:44 AM »

I'm speechless! It's something I didn't expect or at least not so fast. I know it's not done yet but from my post this morning to what you say and present is just amazing. I played with your code like a kid back in 1982 with River Raid. Let me express it this way:



The available types are:

Keywords     AMOS Basic instructions, punctuation, math and logic symbols.
Names     The names the programmer has given to Variables, Labels and Procedures.  It is not possible to split these up and use a different colour for each as Detokenise() doesn't 'know' the context until the program is Verified (the Test and Run process).
Numeric Literals   Any integer, single, double, hexadecimal and binary numbers in the code.
Text Literals     Any text enclosed in single or double quotes.
Comments     Any text following a Rem or '.

I went too far with the numbers of colors on my mockup but of course I was aware of certain limitation. Even if it's five as listed above, I and many others will be super happy (I couldn't resist and I posted info about it on Polish forum ppa.pl - naturally my joy has been shared  ;D).

Quote
The stuff at the top of screen was just to see what standard palette colours look like.  Modify the AMOS code to try different colours.

Yes, I did that and I spent on it more time than on any other game recently  ;D

Quote
In addition, the text case for Keywords and Names is already implemented in AMOS Pro.
There's also seven longwords of free space available for 'future use' (thanks François!)

I join in those thanks!

Quote
And with a dropdown for the colour selection:

Wouldn't it be more user friendly and nicer for the eye if instead of dropdown list you added a line of colour boxes in a row? It would give the user a complete view of all colors and selection made. Just an idea, I'll accept whatever it be, even if I had to hex-edit all the values  ;D

I'm very positive and can't wait to see the result!

Quote
The Select Case you speculate on is just not feasible without major code changes.  It's a structural instruction (like Do ... Loop and If ... Then ... End If) that needs offsets inserted during Test and Run and would require major changes to the Verify() code.  Any changes that affect program structure are almost impossible  :(

No worries. I'm not surprised. Deep inside I knew it won't be easy so let it be, if accepted, as a v 3.0 feature.

Quote
Now, back to the bugs as this is all enhancement and not fixes!  And now I'm recovering and more active, I want to get stuff out there instead of just talking about it. ;D

Sticking here for any update.
Logged

PerspexSphinx

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 4
  • Generic Amiga User
Re: AMOS Pro 2: New feature suggestions List
« Reply #11 on: April 11, 2016, 08:37:51 PM »

Colour syntax highlighting in Amos really would be most useful and helpful. Your demo is a tantalizing glimpse, please make this an implemented feature.

Great stuff!
Logged

PerspexSphinx

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 4
  • Generic Amiga User
Re: AMOS Pro 2: New feature suggestions List
« Reply #12 on: April 11, 2016, 08:48:35 PM »

Oops, didn't mean too post twice... I'm just excited I guess.
Logged

SamuraiCrow

  • compile-time wierdo
  • Forum Mod
  • A1200
  • *****
  • Karma: 5
  • Offline Offline
  • Gender: Male
  • Posts: 946
  • Compile-time wierdo
Re: AMOS Pro 2: New feature suggestions List
« Reply #13 on: April 12, 2016, 06:18:48 AM »

Oops, didn't mean too post twice... I'm just excited I guess.
I fixed it.
Logged

Umpal

  • A600
  • *
  • Karma: 0
  • Offline Offline
  • Gender: Male
  • Posts: 37
  • Programming and graphic
Re: AMOS Pro 2: New feature suggestions List
« Reply #14 on: April 12, 2016, 09:53:55 PM »

@bruceuncle, any update regarding the Syntax Highlighting? Not pressing, just curious.
Logged
Pages: [1] 2   Go Up
 

TinyPortal 2.2.2 © 2005-2022