RISC OS 3.7 User Guide


Paint Tutorial


This tutorial section shows you how to use Paint to produce a small, simple picture, made up of two flowers in diagonal corners. In fact you'll only need to paint one flower, you can then copy it and re-colour it:

You can then use the Pinboard application to repeat this picture all over your screen producing a 'wallpaper' type background:

The tutorial is not designed to show you how to use all the Paint tools - in fact it only uses a few - but to give you a general idea of how the application works.

All of Paint's tools are described in detail in the Paint reference section on page 297.

Start Paint

Start Paint by double-clicking on the Paint icon. As with other RISC OS applications, Paint's icon appears on the icon bar.

Note: Before you start this tutorial, change to a 16-colour square-pixel screen mode such as 800x600 (if you don't know how to do this, see page 13).

Create a new sprite

1 Click on the Paint icon on the icon bar.

This displays the Create new sprite and Sprite file windows.

2 Delete the existing name newsprite (using the Delete key) and type in the name for your sprite: Flowers.

3 Change both the Width and the Height of the sprite to be 80.

4 Make sure the Mask box is ticked.

5 Click on OK and your new (blank) sprite is created.

You should now have four Paint windows on your screen:

Drag the tools window and the colours window to the right of your screen, and drag the Sprite file window to the bottom left of your screen. Leave the sprite window in the middle of the screen.

Zoom in

The sprite you've just created is very small. To help you see what you're doing, click Menu on the sprite window and change the Zoom factor to 8:1 (see page 305 for more on zooming):

The blank sprite will now fill most of your screen, and at this magnification a grid is superimposed over the painting area. Each square in the grid represents one pixel.

Create the first flower petal

1 Choose the Use sprite as brush tool from the Paint tools window (click on it).

The bottom of the tools window will expand to display an area where you can define the type of paint brush you want to use and its size. The default brush type is a circle.

2 Reduce the brush size by changing the X scale and Y scale boxes to 1:2, and then click on OK.

3 The first flower will be dark blue: Click on the dark blue colour in the Colours window.

That colour will be highlighted and overlaid with the number 8 (to signify that this is colour 8 out of a palette of 16 colours).

4 Move the pointer into the sprite window. You'll notice that the pointer is now attached to the centre of a circle. Move the pointer to the approximate position shown below and click. A solid, dark blue circle will appear:

Note: If you accidentally remove either the colours window or the tools window from your screen you can restore them by pressing Menu over the sprite window, and choosing Paint/Show colours or Paint/Show tools.

Save your sprite for the first time

Now is a good time to save your sprite:

1 Click Menu over the Sprite file window (not the sprite window).

2 Change the name in the Paint/Save/Save as dialogue box to Flower.

The name of the sprite file appears in the Title bar of the sprite file window.

Note: You should save your work frequently as you proceed. You can then return to the last step if you go wrong. This is an especially good idea with Paint, since with some of the tools you can easily make mistakes. Unlike Draw, you can't undo your work in Paint.

Paint the next three petals

Move the pointer to the centres of the three other circles shown below and click. Don't worry if your circles are in slightly different positions:

Tip: If you've put a circle in the wrong position don't despair, change the colour to white then paint over the incorrect circle. You can then change the colour back to blue and redo the circle.

Save your work again

Once you're satisfied with your four petals, save your work again before you go on: Just click Menu over the Sprite file window (not the sprite window) and choose Save. You don't need to supply a name this time.

Create the middle of the flower

You need a smaller brush to paint the middle of the flower:

3 Change the X scale and Y scale boxes in the Paint tools window to 1:4.

4 Select yellow (colour 9) from the Colours window.

5 Paint a small circle in the centre of your four petals:

Touch up the centre of the flower

If you find that there are one or two white pixels still in the centre of the flower, you can turn them into dark blue pixels:

1 Choose the Set/Clear pixels tool from the tools window (the icon for this looks like the tip of a pencil).

2 Choose dark blue as your current colour.

3 Click Select over any white pixels inside your flower.

Save your work again at this point.

Paint the stem

The final step in creating the flower is to paint in a green stem:

1 Choose light green (colour 10) from the Colours window.

2 Choose the Set/Clear pixels tool from the tools window (you may already be using this tool if you did any touching up).

3 Paint the pixels beneath the flower to look like a stem (click on each pixel in turn).

If you click over one pixel, only that pixel will be coloured. If you drag the pointer while holding down Select button, each pixel it moves over will be coloured:

Tip: If you make any mistakes, click Adjust to change the incorrect green pixels back into white ones.

This is another good point to save your work before going on.

Create the second flower

The second flower goes in the bottom right corner of the sprite. However, you don't have to paint a new flower; you can copy the one you've just made:

1 Go into the Zoom dialogue box and slightly reduce the magnification factor, then click on the Toggle size icon (in the top right corner of the sprite window) to display the entire sprite.

2 Choose the Copy block tool and make sure the Local option is switched on at the bottom of the tools window.

3 Position the pointer at the top left corner of the flower.

4 Hold down Select, drag the mouse to the bottom right corner of the flower and release Select. A light blue rectangle will show the block of pixels that you have copied.

5 Move the pointer to the bottom right corner of the sprite window and click.

The light blue rectangle will be replaced by a copy of the flower.

Modify the second flower

There are two changes you can make to the second flower to make it clearly different from the first one; change the colour of its petals and centre, and trace around the petals.

Change the colour of the flower

1 Choose the Replace colour tool.

2 Choose red (colour 11) from the Colours window.

3 Move the pointer over any part of the yellow centre of the flower and click.

The centre will become red.

4 Choose yellow (colour 9) from the colours window.

5 Move over any part of the blue petals and click. All the blue pixels that touch each other will be instantly changed to yellow pixels.

Trace around the petals

The final change to make to the second flower is to trace around the edge of the petals to give it more impact:

1 Choose orange (colour 14) from the colours window.

2 Choose the Set/Clear pixels tool.

3 Carefully trace around the outermost yellow pixels of the flower replacing them with orange:

You can click on each pixel individually, or drag the pointer round the edge of the petals in one go.

Change the background colour

The white background will be too stark when you use the flowers to cover your entire screen, so:

1 Choose the Replace colour tool, and switch the Global option on (at the bottom of the Tools window).

2 Choose cream (colour 12) from the Colours window.

3 Move to any white pixel in the sprite and click.

The entire background of the sprite will be changed to cream.

Your sprite is now finished, so save it and then close the file.

Turn the sprite into a backdrop

You're now ready to wallpaper your screen with your flower sprite.

1 Drag your sprite file (called Flower) from its directory and drop it anywhere on the desktop background.

Its icon will 'stick' to the desktop background.

2 Click Menu over this icon.

The Pinboard menu will appear.

3 Choose Make backdrop/Tiled from this menu:

4 Your whole screen will now be tiled with your sprite:

You've finished this part of the tutorial. Take a breather. The next two sections (before the Paint reference section on page 297) show you some advanced tricks you can use.

Painting with a sprite

This section, and the next, show you how to create some special effects in Paint. Here's how to use a whole sprite as a brush tool, to produce interesting patterns:

1 Open the sprite file called Flower.

2 Now click on Paint's icon bar icon and create a sprite, 400 pixels by 300.

3 In the tools window, choose the Use sprite as brush tool.

4 Delete the default name circle, and type in the name of a sprite (in this case - flower).

(The sprite file containing the sprite you want to use as a brush must be open.)

5 If Shape is switched on, switch it off.

6 Click on OK.

7 You can now paint using the sprite as a paintbrush. Clicking once paints a single sprite, and dragging the brush produces a snakelike effect of sprites:

Painting with the mask of a sprite

This section tells you how to use a special colour (a mask) to make parts of a sprite transparent:

1 Make sure the sprite file Flower is open.

2 Click Menu over the Sprite file window and copy your flower sprite - give it the name flower2:

3 Open flower2, choose Edit/Adjust size from the main menu, and change the width of the sprite to 40 pixels.

This will chop off the right half of the sprite leaving only the flower in the top left half of the sprite.

4 Now, if it's not already ticked, choose Edit/Mask from the main menu to create a mask colour.

5 Choose the Replace colour tool and click on the Global button.

6 Choose the transparent colour (colour T) at the very bottom left of the Colours window - you might need to extend the Colours window down a bit to see it.

7 Click on the background of the sprite to fill it with the transparent colour.

8 Close the sprite by clicking on the close icon.

9 Click on Paint's icon bar icon and create a new sprite (don't forget to click on OK).

10 In the tools window, select the Use sprite as brush tool.

11 Delete the default name and type in the name of the sprite you just created - flower2.

12 If Shape is switched on, switch it off and click on OK.

13 You can now paint individual flowers, which will have a transparent background colour:

You have now completed the Paint tutorial. Save the files you've just created, if you want, or just quit Paint.

The rest of the chapter is a reference section describing the basic elements of Paint, the tools in detail, and how to customise Paint so that it always starts up the way you prefer it.


RISC OS 3.7 User Guide - 22 JAN 1997