Help : how to get nice 6502 syntax colouring on Notepad++ ?
Moderator: Moderators
Help : how to get nice 6502 syntax colouring on Notepad++ ?
Everything is in the title. I am not too bad at programming computers but I suck at using other people's programs.
I know I somehow managed to make my own plugin for that years ago on an old version but now I couldn't port it to my new computers after reinstallation of Windows, so I have no idea how I made it and it seems all the menus/etc... has changed since then anyways.
I know I somehow managed to make my own plugin for that years ago on an old version but now I couldn't port it to my new computers after reinstallation of Windows, so I have no idea how I made it and it seems all the menus/etc... has changed since then anyways.
Re: Help : how to get nice 6502 syntax colouring on Notepad+
Something wrong with Microsoft Visual Studio?
Re: Help : how to get nice 6502 syntax colouring on Notepad+
It's big, bloated and overkill for 6502 code?WedNESday wrote:Something wrong with Microsoft Visual Studio?
Anyway, my old Notepad++ syntax file still works with more recent versions. I simply put my userDefineLang.xml file into %APPDATA%/Notepad++.
Re: Help : how to get nice 6502 syntax colouring on Notepad+
Oh thanks, I didn't know it had to be in that location ! I tried Notepad++'s own folder, but that didn't work.
Well there's no links to your configuration file, but there is one to TheFox321's.
And I made it working but I have the following isses :
1) I don't like the font he's using it's way too big and it's not a monospace font (ok this is probably very easy to change manually)
2) I have to manually go to Language -> fox6502 every. single. time. Cannot it be made automatically for .asm files ?
Well there's no links to your configuration file, but there is one to TheFox321's.
And I made it working but I have the following isses :
2) I have to manually go to Language -> fox6502 every. single. time. Cannot it be made automatically for .asm files ?
Re: Help : how to get nice 6502 syntax colouring on Notepad+
I'm attaching it to this message, in case you want to check it out. I made it according to my own needs, so you might disagree with some of my choices.Bregalad wrote:Well there's no links to your configuration file
Mine does that. Apparently there's an "ext" attribute you can use to associate the language definition to a file extension.I have to manually go to Language -> fox6502 every. single. time. Cannot it be made automatically for .asm files ?
- Attachments
-
- userDefineLang.zip
- (971 Bytes) Downloaded 147 times
Re: Help : how to get nice 6502 syntax colouring on Notepad+
I don't know what people think, but may I suggest using a different extension than .asm, e.g. .6502 or something like that? With different assembly languages around, I find that using separate extensions for each CPU is a good idea (e.g. for 68000 and Z80 I use .68k and .z80 respectively)
Re: Help : how to get nice 6502 syntax colouring on Notepad+
It's pretty easy to create custom syntax colorings for Notepad++, especially if you base them on an existing syntax definition. Just go to "Language" -> "Define your language" menu. The new "user defined language" feature is also documented fairly well.
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: fo.aspekt.fi
Re: Help : how to get nice 6502 syntax colouring on Notepad+
Thank you very much Tokumaru, your syntax files makes my sources very beautiful. And it's better than the default X86 assembly skin that is loaded with .asm files.
Re: Help : how to get nice 6502 syntax colouring on Notepad+
One thing I'd like to suggest, which has helped me out a great deal with organizing my source code, was to define some "folders" (as my version of notepad++ calls it).
In C (for example), you can have something like:
and most IDEs allow you to collapse what's between the { }.
Notepad++ lets you define what constitutes as the start and end of a collapsable block of code, and when defining my 6502 highlighting, I defined it as ";bs" and ";be".
So my assembly looks like this:
and that allows me to collapse chunks of code like loops and subroutines, and because ;bs and ;be are interpreted as comments by the assembler, they don't interfere with anything. You can define it however you want, I just chose bs and be because "block start" and "block end". Derp.
In C (for example), you can have something like:
Code: Select all
int butt() {
an
amazing
amount
of
code
}Notepad++ lets you define what constitutes as the start and end of a collapsable block of code, and when defining my 6502 highlighting, I defined it as ";bs" and ";be".
So my assembly looks like this:
Code: Select all
routine_for_butts: ;bs
A
BUNCH
OF
OPCODES
butt_loop: ;bs
HERE'S
SOME
MORE
CODE
BNE butt_loop
;be
TIME
TO
CLEAN
UP
RTS
;be
Re: Help : how to get nice 6502 syntax colouring on Notepad+
Heh. I do the same thing. Except I didn't know there was a way to make them collapsible. I usually just used the find matching brace hotkey (ctrl+B) to skip around.
But I should probably make them folders too.
Code: Select all
div7:;{
sta <reserved1F
lsr a
lsr a
lsr a
adc <reserved1F
ror a
lsr a
lsr a
adc <reserved1F
ror a
lsr a
lsr a
rts;}
Re: Help : how to get nice 6502 syntax colouring on Notepad+
I highly recommend it; having them as actual folders makes it much easier.
Re: Help : how to get nice 6502 syntax colouring on Notepad+
For ca65 users it's quite natural to define them for .proc/.endproc and .scope/.endscope. I never thought about using special comments for them, but I guess that works just as well.Drag wrote:I defined it as ";bs" and ";be".
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: fo.aspekt.fi