aboutsummaryrefslogtreecommitdiff
path: root/src/toolkit/frame.py
diff options
context:
space:
mode:
authorBrianna2017-08-10 16:16:07 -0400
committerGitHub2017-08-10 16:16:07 -0400
commitc5a0c9b364f6d6228a3027b5668915a838c1ba95 (patch)
treef04e4117c133a539a87ffcae00d0cd66fa1517f4 /src/toolkit/frame.py
parent2603c639254d8ab8e87e201613d123da367cae21 (diff)
parent1c4afc96d69789f16284c067ffd7098dc7b2ca70 (diff)
Merge pull request #55 from djfun/logging
using the builtin logging module
Diffstat (limited to 'src/toolkit/frame.py')
-rw-r--r--src/toolkit/frame.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/toolkit/frame.py b/src/toolkit/frame.py
index 7e83d58..02f9229 100644
--- a/src/toolkit/frame.py
+++ b/src/toolkit/frame.py
@@ -7,10 +7,14 @@ from PIL.ImageQt import ImageQt
import sys
import os
import math
+import logging
import core
+log = logging.getLogger('AVP.Toolkit.Frame')
+
+
class FramePainter(QtGui.QPainter):
'''
A QPainter for a blank frame, which can be converted into a
@@ -79,6 +83,7 @@ def FloodFrame(width, height, RgbaTuple):
@defaultSize
def BlankFrame(width, height):
'''The base frame used by each component to start drawing.'''
+ log.debug('Creating new %s*%s blank frame' % (width, height))
return FloodFrame(width, height, (0, 0, 0, 0))
@@ -88,6 +93,7 @@ def Checkerboard(width, height):
A checkerboard to represent transparency to the user.
TODO: Would be cool to generate this image with numpy instead.
'''
+ log.debug('Creating new %s*%s checkerboard' % (width, height))
image = FloodFrame(1920, 1080, (0, 0, 0, 0))
image.paste(Image.open(
os.path.join(core.Core.wd, "background.png")),