changeset 132:25b7c1f20949

Adapted pycaptcha to get fonts in /Tmp/allfonts local folder
author boulanni <nicolas_boulanger@hotmail.com>
date Sat, 20 Feb 2010 02:06:38 -0500
parents 5c79a2557f2f
children a4e5128ef2cb
files pycaptcha/Captcha/Visual/Text.py pycaptcha/Captcha/data/fonts/allfonts
diffstat 2 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/pycaptcha/Captcha/Visual/Text.py	Fri Feb 19 08:43:10 2010 -0500
+++ b/pycaptcha/Captcha/Visual/Text.py	Sat Feb 20 02:06:38 2010 -0500
@@ -18,7 +18,7 @@
        If any of the given files are directories, all *.ttf found
        in that directory will be added.
        """
-    extensions = [".ttf"]
+    extensions = [".ttf", ".TTF"]
     basePath = "fonts"
 
 # arguments variables a modifier pour mettre le chemin vers les fontes.
@@ -39,7 +39,7 @@
         return (fileName, size)
 
 # Predefined font factories
-defaultFontFactory = FontFactory(25, "vera", "others")
+defaultFontFactory = FontFactory(25, "allfonts")
 #defaultFontFactory = FontFactory((30, 40), "vera")
 
 class TextLayer(Visual.Layer):
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/pycaptcha/Captcha/data/fonts/allfonts	Sat Feb 20 02:06:38 2010 -0500
@@ -0,0 +1,1 @@
+/Tmp/allfonts
\ No newline at end of file