mirror of
https://github.com/xram64/6502-npp-syntax.git
synced 2024-12-03 21:49:35 +00:00
Notepad++ Syntax Highlighting for 6502 Assembly (and NESASM)
65026502-assemblyapple-iiapple-iieappleiiatari-2600atari2600c64commodore-64commodore64highlightingnesnesasmnesasm3notepad-plus-plusnotepadplusplusnppsyntax-highlighting
.gitattributes | ||
LICENSE | ||
npp_6502_general.xml | ||
npp_6502_nesasm.xml | ||
README.md |
Notepad++ Syntax Highlighting for 6502 Assembly
Introduction
I started programming an NES game in 6502 assembly but couldn't find any syntax highlighting files anywhere, so I ended up making my own.
There are two files included here:
- npp_6502_general.xml, which highlights opcodes, numbers, comments, etc. for the 6502 assembly language
- npp_6502_nesasm.xml, which does the same thing, but also highlights assembler directives and functions for NESASM3
Installation
- Download npp_6502_general.xml or npp_6502_nesasm.xml.
- In Notepad++, go to Language → User Defined Language → Define your language...
- Click Import... and select the file.
- Restart Notepad++.
- Go to Language and select 6502 Assembly to load the syntax highlighting.
- If you use a theme, go to Settings → Style Configurator and check Enable global background color to fix text display issues.
Features
- Highlights opcodes, comments, numbers, and strings
- Separate colors for integers, hex, and binary numbers
- Special highlighting for immediate addressing symbol (#)
- Special highlighting for registers (A, X, Y, S, P)
- Opcodes can be entered in upper or lower case
- Illegal opcodes are recognized and differentiated with a darker color
- Works well on most themes with darker backgrounds
Notes
I've left off the automatic extension checking for .asm
files because it would overlap with other types of assembly files, but if you'd like to make this highlighting the default for all .asm
files, just add "asm" to the Ext. box in Language → User Defined Language → Define your language...