So I wanted to enter the ZX81 Graphic Competition 2007. But I didn’t particularly want to type out block graphics character by character into a Basic program on an emulated ZX81 keyboard. So I wrote a ZX81 art package. In Javascript.

It does make sense – Javascript is one of the few languages you can write graphical applications in that’s truly cross-platform – as in ‘doesn’t require Windows users to install a massive runtime and a bundle of libraries’. Well, in this case we do require them to install Firefox, but come on, who’s going to object to that?

It’s dead easy to use (painting in three shades of grey is hardly rocket science after all) and it exports directly to ZX81 .P format courtesy of a neat Basic snippet from Russell Marks. So if you’re feeling artistic, give it a go – you don’t even need to download it. (But if you do, you get the additional perk of being able to supply an overlay image to trace around.)

Update (2008-07-12): Now features a handy clickable palette, as requested by Yerzmyey – so that people with less than three buttons on their mouse can use it. You’d think that a Mac user like me would have thought of that, really…

7 Responses to “ZXpaintyONE”

  1. Truck says:


    I was gonna do this, actually, and even in javascript since I’ve been doing that a lot for work – but got caught in ‘needing to learn python’ so…

    Thanks (:

  2. muriloq says:

    There is another Javascript-based ZX-81 graphics editor:


    Take a look at “Em Busca dos Tesouros”, a Brazilian Pitfall! clone for the ZX-81:

  3. F6 says:

    Thanks for this, Matt! Amazing! But will it blend? :-P

  4. Sir Morris says:


    Score 100!

  5. Thunor says:

    Very useful, and even more so after I slightly modified function dataAsHex() so that it writes 32 columns of 24 rows of comma delimited hex values into the textarea instead of a continuous stream of digits. This makes it trivial to import into source code and it also enables inserting/deleting rows/columns by hand. Luckily the load function accepts this formatted data without modification.

    In zxpaintyone_v2:

    Insert this as line 257:
    savedata += ‘\n0x’;

    Insert this as line 265:
    if (x != 62) savedata += ‘,0x’;


  6. nitrofurano says:

    i found a bug from the generated .p files when we used quotes character ( chr$(11) ), since string variables seems to not accept them easily – the solution is (and the code below is flexible enough to create a slideshow, if people want…):

    10 CLS
    12 CLEAR

    100 FAST
    101 PRINT AT 0,0;”0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF”
    102 GO SUB 9990
    103 PRINT AT 0,0;”0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF”
    104 PRINT “0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF”
    105 PRINT “0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF”
    106 SLOW
    107 PAUSE 4E4

    9990 LET D=1+PEEK 16396+256*PEEK 16397
    9991 FOR F=0 TO 63
    9992 LET G=F+704
    9993 POKE D+G+INT(G/32),PEEK(D+F+INT(F/32))
    9994 NEXT F
    9995 RETURN

  7. Martin says:

    And here is another zx81 javascript screen editor http://editor.zx-gaming.co.uk

Leave a Reply