Page 4 of 5
Re: X16 Edit - a text editor
Posted: Tue Dec 19, 2023 5:53 am
by Stefan
ahenry3068 wrote: ↑Mon Dec 18, 2023 11:09 pm
So is there an updated ROM somewhere ?
(also with BASLOAD
)..
MooinLemur asked me a week ago if the editor master branch was ready to be pulled into the Kernal. I think it is now. I don’t know when he has time to look at this though.
As to BASLOAD, it’s getting to a point where we could at least think about merging it into the Kernal. But I have no ETA on when to expect it. I need to discuss that with MooingLemur as well.
Re: X16 Edit - a text editor
Posted: Tue Dec 19, 2023 7:44 am
by ahenry3068
Stefan wrote: ↑Tue Dec 19, 2023 5:53 am
ahenry3068 wrote: ↑Mon Dec 18, 2023 11:09 pm
So is there an updated ROM somewhere ?
(also with BASLOAD
)..
MooinLemur asked me a week ago if the editor master branch was ready to be pulled into the Kernal. I think it is now. I don’t know when he has time to look at this though.
As to BASLOAD, it’s getting to a point where we could at least think about merging it into the Kernal. But I have no ETA on when to expect it. I need to discuss that with MooingLemur as well.
Do you have a trial build then ?
Re: X16 Edit - a text editor
Posted: Tue Dec 19, 2023 4:01 pm
by Martin Schmalenbach
ahenry3068 wrote: ↑Tue Dec 19, 2023 7:44 am
Do you have a trial build then ?
Good question - I for one would love to help test it.
My pascal compiler is not trivial code in terms of size or complexity, and is in sore need of making use of all the rumoured features of the latest version of BASLOAD!
Re: X16 Edit - a text editor
Posted: Tue Dec 19, 2023 4:04 pm
by Martin Schmalenbach
Stefan wrote: ↑Tue Dec 19, 2023 5:43 am
Martin Schmalenbach wrote: ↑Mon Dec 18, 2023 10:30 pm
As I understand it, invoking the editor from outside the editor is now quite easy to do - looking forward to experimenting with it!
Yes, it’s pretty easy. Just let me know if you run into problems.
Is there a way to open a file in the editor at a specific line? It would be a nice feature to go from a compiler error message straight to the offending line of source code - it would be more like a simple integrated development environment.
I guess syntax highlighting is too much to ask for right now?
Re: X16 Edit - a text editor
Posted: Tue Dec 19, 2023 5:33 pm
by Stefan
Martin Schmalenbach wrote: ↑Mon Dec 18, 2023 10:30 pm
Is there a way to open a file in the editor at a specific line? It would be a nice feature to go from a compiler error message straight to the offending line of source code - it would be more like a simple integrated development environment.
I guess syntax highlighting is too much to ask for right now?
There is currently no way to go to a specific line when you start the editor. But it would be quite easy to do. I’ll keep that in mind.
Syntax highlighting would require a lot of redesign. The program was not at all built with that in mind.
Re: X16 Edit - a text editor
Posted: Wed Dec 20, 2023 11:02 pm
by Martin Schmalenbach
Stefan wrote: ↑Tue Dec 19, 2023 5:33 pm
Martin Schmalenbach wrote: ↑Mon Dec 18, 2023 10:30 pm
Is there a way to open a file in the editor at a specific line? It would be a nice feature to go from a compiler error message straight to the offending line of source code - it would be more like a simple integrated development environment.
I guess syntax highlighting is too much to ask for right now?
There is currently no way to go to a specific line when you start the editor. But it would be quite easy to do. I’ll keep that in mind.
Syntax highlighting would require a lot of redesign. The program was not at all built with that in mind.
Hi Stefan
Thanks for the update. I thought syntax highlighting would be too much of an ask!
I am interested though in being able to start the editor at a particular line in a file - I shall look forward to it in time, and realise this may not be a high priority for you just yet!
Re: X16 Edit - a text editor
Posted: Thu Jan 18, 2024 12:59 am
by Karl Hultland
I saw mentioned in a thread that the X16 Edit used parts of the Zero page memory but I found no more info what addresses I should keep out of if I want to use the editor from my own code.
Re: X16 Edit - a text editor
Posted: Thu Jan 18, 2024 6:49 am
by Stefan
Hi,
The short answer is that you should not need to think about that.
The long answer is that the editor uses the following address ranges:
- The next version also 0x9c00 to 0x9eff
These memory locations are copied to banked RAM on startup and restored when you exit the editor. The memory restore routine is, however, not executed if you exit the editor with Ctrl+Alt+Del.
The editor uses the part of banked RAM that is assigned when it's started. The EDIT command assigns banks 10 to 255. If you're integrating the editor with your own program, you can freely decide what RAM banks the editor is allowed to use.
Re: X16 Edit - a text editor
Posted: Mon Feb 05, 2024 3:40 pm
by unartic
Hi Stefan!
I have found a sort-of bug.
I'm calling the rom based version from assembly.
If I have the filename to be edited at $0444 and call x16edit, I get an error that the file is not found. Looking at memory it seems x16edit is using the $04xx region aswell and probably first uses it, before reading or copying the filename.
I think this is somehting you might want to address as probably many application wil use de $04xx region in the future and some might store the filename in $04xx before calling x16edit.
Re: X16 Edit - a text editor
Posted: Mon Feb 05, 2024 6:11 pm
by TomXP411
unartic wrote: ↑Mon Feb 05, 2024 3:40 pm
Hi Stefan!
I have found a sort-of bug.
I'm calling the rom based version from assembly.
If I have the filename to be edited at $0444 and call x16edit, I get an error that the file is not found. Looking at memory it seems x16edit is using the $04xx region aswell and probably first uses it, before reading or copying the filename.
I think this is somehting you might want to address as probably many application will use de $04xx region in the future and some might store the filename in $04xx before calling x16edit.
I don't think this is something that needs "fixing", so much as better documentation. I'll add a note to our Docs Issues to not just ad EDIT and BASLOAD to the docs, but to note the parts of memory that EDIT will hammer when it starts. (It's got to work somewhere, after all...)