Archive for the ‘Handphone’ Category

link tutorial pys60 about canvas in forum nokia

import appuifw
import graphics

# Creates new image with size 50,50 and uses mode 1
# Mode 1 indicates the image is only black and white - this is required for using masks
# You can replace '1' by 'L' if you want to use a 8-bits grayscale image
mask_img = = (50, 50), mode = '1')
# Loads the mask
# Opens main image
main_img ='E:\\original.png')
# Defines canvas for using as the application body
canvas = appuifw.Canvas()
# Sets the body to canvas = canvas
# Blits the image with it's mask
canvas.blit(main_img, target=(0,0), source=(0,0), mask = mask_img)