frdgCanvas - My own custom drawing software

frdgCanvas is a drawing software made with Python that uses GTK3 for the GUI and Pygame for the drawing canvas.

2024-08-05

frdgCanvas image

This is a personal project I took up during the summer of 2024. It took over 4 days to create.

The software comes with a brush that draws basic shapes to simulate a pen, an eraser, a mode for creating pixel art and a directory for you to create your own brushes.

Downloads

Download Windows installer (.exe)
You can access the custom brushes directory at %appdata%/frdgCanvas/brushes

Download Linux executable
You can access the custom brushes directory at ~/.config/frdgCanvas/brushes

Download my custom brushes (.zip)
I've made some of my own custom brushes, download and extract this archive, then install the .frdgbrush files within the software.


Documentation

If you have any questions about the software that aren't answered here, feel free to contact me!

Installation

The precompiled executables and directory for brushes are highlighted on the Downloads part. The Windows installer will automatically create a desktop shortcut for you, but the Linux option only comes with the executable.

Building

If your system isn't x86 Windows or Linux, you can instead compile the program to work on your system or run the Python script without compiling.

Clone the repository and install python3 requirements:
git clone https://github.com/ashprids/frdgCanvas.git
pip install -r requirements.txt

And then, if you wish to build an executable:
python3 build/build.py

The executable can be found in the newly created 'dist' directory in build/.

Usage

When you open the program, the New Project UI will appear. From here, you have a few options:

Create
  • Project Name. Must only contain alphanumeric characters.
  • Canvas size. The width and height of the canvas in pixels.
  • Background colour.
  • Fullscreen. Makes the canvas the size of your display.

Grid Mode
  • Grid mode. Turns the canvas into a grid of squares, and uses pixels instead of brushes.
  • Pixel size. The visual size of each pixel in the grid.
  • Grid colour. The colour of the grid, can be turned off after creation.
  • Larger pixel size to canvas size ratios result in poor performance, this feature is not optimized!

Install
  • Install brush. Select a .frdgbrush file and it'll be installed!

For more information, hover over any of the options in the UI.

In the canvas, you can press CTRL + Z to undo the last action, and Right Click to erase. All of the options in your project are self-explanatory.

Custom Brushes

Custom brushes (.frdgbrush) are zip archives that contain a properties.json file and any textures. With the custom brushes provided, you can see the structure of the properties.json file.

Here's the full properties.json file structure, with explanations:
{
"name": "Charcoal",
"author": "fridge",
"description": "A charcoal stick brush.",

"textureAmount": 4,
"useColour": true,
"rotate": false,
"drawLine": false,
"lineSize": -24
}

  • textureAmount is the amount of textures for the brush. If there's 1 texture, the texture should be called texture.png, otherwise they're numbered (texture1.png, texture2.png, etc.) The texture is randomly chosen on each stroke.
  • useColour is whether the brush uses the colour of the brush or not. If false, the brush will use the colour of the texture. When true, use a white texture for best results.
  • rotate is whether the brush rotates randomly on each stroke.
  • drawLine is whether the brush draws a line between the last and current position.
  • lineSize is the size of the line drawn if drawLine is true. Values are relative to the brush size.

If this seems confusing, you can refer to the brushes I've made.

To create a .frdgbrush file, simply zip the properties.json file and any textures together, and rename the file to the name of the brush as stated in properties.txt (IMPORTANT!). Change the file extension to .frdgbrush.
end of page