are there any assemblers that allow you to write code in columns?

The place for codemasters or beginners to talk about programming any language for the Spectrum.
Post Reply
User avatar
777
Manic Miner
Posts: 534
Joined: Fri Jun 26, 2020 11:23 am
Location: sw uk

are there any assemblers that allow you to write code in columns?

Post by 777 »

as assembly language code is always really long, if you could have more that one column of code on the screen at once it might be easier to read?

and by assemblers i mean ones that run on a pc not a spectrum
i started programming the spectrum when i was 8 :-

1 plot rnd*255,rnd*175
2 goto 1

http://zxspeccy.great-site.net/
Alone Coder
Manic Miner
Posts: 401
Joined: Fri Jan 03, 2020 10:00 am

Re: are there any assemblers that allow you to write code in columns?

Post by Alone Coder »

I don't know ones. Assembly sources usually have long comments :)
ALASM uses 6x6 font to see more lines of code.
Image
User avatar
777
Manic Miner
Posts: 534
Joined: Fri Jun 26, 2020 11:23 am
Location: sw uk

Re: are there any assemblers that allow you to write code in columns?

Post by 777 »

it would be handy to be able to read more of the code at once, on a pc
i started programming the spectrum when i was 8 :-

1 plot rnd*255,rnd*175
2 goto 1

http://zxspeccy.great-site.net/
catmeows
Manic Miner
Posts: 720
Joined: Tue May 28, 2019 12:02 pm
Location: Prague

Re: are there any assemblers that allow you to write code in columns?

Post by catmeows »

Well, many editors allow code folding. And some assemblers allow multiple instructions on line.
Proud owner of Didaktik M
User avatar
Morkin
Bugaboo
Posts: 3325
Joined: Mon Nov 13, 2017 8:50 am
Location: Bristol, UK

Re: are there any assemblers that allow you to write code in columns?

Post by Morkin »

Visual Studio Code you can right-click on a tab at the top > "split right" to create new columns.

Doesn't scroll multiple columns together but might be useful if you want to keep your eyes on/update multiple routines at once, e.g. one near the start of your code, one near the end.
My Speccy site: thirdharmoniser.com
User avatar
777
Manic Miner
Posts: 534
Joined: Fri Jun 26, 2020 11:23 am
Location: sw uk

Re: are there any assemblers that allow you to write code in columns?

Post by 777 »

does that mean the column 1 has the fist piece of code and column 2 is a continuation of that code, etc? thats what i want...
i started programming the spectrum when i was 8 :-

1 plot rnd*255,rnd*175
2 goto 1

http://zxspeccy.great-site.net/
User avatar
Morkin
Bugaboo
Posts: 3325
Joined: Mon Nov 13, 2017 8:50 am
Location: Bristol, UK

Re: are there any assemblers that allow you to write code in columns?

Post by Morkin »

777 wrote: Sat Nov 06, 2021 1:03 am does that mean the column 1 has the fist piece of code and column 2 is a continuation of that code, etc? thats what i want...
Ah right - so if you scrolled in one window/column the other would scroll too? Nah, it doesn't do that.

With modern editors you tend to get quick ways of jumping around, like with VS code there's a preview over on the right so you can quickly jump down thousands of lines of code instantly. Bit easier to get to a particular place than, say, the built-in assembler in Spin at least.

I assume there are developers here who might have suggestions on dealing with long code listings in their dev environments, as I guess dealing with long listings isn't restricted to Speccy/assembly.
My Speccy site: thirdharmoniser.com
zxcygnus
Drutt
Posts: 32
Joined: Mon Aug 24, 2020 3:11 pm
Contact:

Re: are there any assemblers that allow you to write code in columns?

Post by zxcygnus »

Or you can just use plain text editor KWRITE (or KATE) which is part of any Linux distribution with K Desktop Environment.

There are at least two XML files with definition for syntax highlighting. One very old from me (i am still using it with compiler AS) and one newer and better is part of assembler sjasmplus.
https://cygnus.speccy.cz/popis_syntaxhi ... r-kate.php
https://github.com/z00m128/sjasmplus/bl ... z80-sj.xml

On screenshot is color scheme "Solarized (light)"
Image

I like much more lightweight editors, Visual Studio feels like bloatware for me. But it is just my personal preference.
https://cygnus.speccy.cz/ - mostly harmless user of ZX Spectrum 128k +2, Betadisk with TRDOS 5.05cz or DivIDE with ESXDOS
User avatar
Stefan
Manic Miner
Posts: 829
Joined: Mon Nov 13, 2017 9:51 pm
Location: Belgium
Contact:

Re: are there any assemblers that allow you to write code in columns?

Post by Stefan »

777 wrote: Fri Nov 05, 2021 3:05 pm as assembly language code is always really long, if you could have more that one column of code on the screen at once it might be easier to read?
No, I would not find it easier to read, instead of flowing through the code I would have to keep bobbing my head up to get to the top of the next column, doing the reverse when needing to track back a few lines.

I did have a monitor in portrait mode for code for a while which I found quite pleasant.
User avatar
Bedazzle
Manic Miner
Posts: 310
Joined: Sun Mar 24, 2019 9:03 am

Re: are there any assemblers that allow you to write code in columns?

Post by Bedazzle »

Stefan wrote: Sat Nov 06, 2021 11:00 am I did have a monitor in portrait mode for code for a while which I found quite pleasant.
Portrait for coding is a must. :)
User avatar
Joefish
Rick Dangerous
Posts: 2089
Joined: Tue Nov 14, 2017 10:26 am

Re: are there any assemblers that allow you to write code in columns?

Post by Joefish »

Maybe split your code into separate files, where files full of call functions, data, tables, etc. are brought into the main file with an 'include' statement, then use an editor that lets you view two files side-by-side?

I tend to convert binary data for graphics into assembly data statements, so I can edit them as text and label individual chunks of data. That really needs to be in separate files so that when I'm not tweaking it, I don't need to see it.
introspec
Dizzy
Posts: 53
Joined: Wed Jan 02, 2019 2:26 pm
Location: London
Contact:

Re: are there any assemblers that allow you to write code in columns?

Post by introspec »

777 wrote: Fri Nov 05, 2021 3:05 pm as assembly language code is always really long, if you could have more that one column of code on the screen at once it might be easier to read?

and by assemblers i mean ones that run on a pc not a spectrum
Yes, some assemblers allow having multiple commands per line, so you can use screen estate more wisely. I am using sjasmplus; you can find the assembler here: https://github.com/z00m128/sjasmplus
This is a screenshot of what such code can look like:
Image
Post Reply