From c08ae1c53295bf6b92bbdba00f5489c79f565579 Mon Sep 17 00:00:00 2001 From: Martin Baeuml Date: Wed, 8 Jun 2011 12:41:58 +0200 Subject: [PATCH] add InvalidArgumentException, fixes #15 --- sloth/core/exceptions.py | 4 ++++ sloth/gui/annotationscene.py | 1 + 2 files changed, 5 insertions(+) diff --git a/sloth/core/exceptions.py b/sloth/core/exceptions.py index d820040..e1a5109 100644 --- a/sloth/core/exceptions.py +++ b/sloth/core/exceptions.py @@ -9,3 +9,7 @@ class ImproperlyConfigured(Exception): class NotImplementedException(Exception): """This function/method/class has not been implemented yet.""" pass + +class InvalidArgumentException(Exception): + """The argument is invalid.""" + pass diff --git a/sloth/gui/annotationscene.py b/sloth/gui/annotationscene.py index a6d9f69..5941198 100644 --- a/sloth/gui/annotationscene.py +++ b/sloth/gui/annotationscene.py @@ -3,6 +3,7 @@ from PyQt4.QtGui import * from PyQt4.QtCore import * from sloth.items import * from sloth.annotations.model import TypeRole, ImageRole +from sloth.core.exceptions import InvalidArgumentException import math import okapy from okapy.guiqt.utilities import toQImage