From 24cc46a1e288447710eec269b7975ee05a2383dc Mon Sep 17 00:00:00 2001
From: Paul McCarthy <pauld.mccarthy@gmail.com>
Date: Mon, 17 Mar 2014 13:14:37 +0000
Subject: [PATCH] String properties, if set to '', will report a value of
 'None'.

---
 tkprop/properties.py | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/tkprop/properties.py b/tkprop/properties.py
index 6a4ba4d32..df907af6c 100644
--- a/tkprop/properties.py
+++ b/tkprop/properties.py
@@ -412,6 +412,12 @@ class String(PropertyBase):
         kwargs['default'] = kwargs.get('default', '')
         PropertyBase.__init__(self, _StringVar, **kwargs)
 
+    def __get__(self, instance, owner):
+        val = PropertyBase.__get__(self, instance, owner)
+
+        if val == '': return None
+        return val
+
         
     def validate(self, instance, value):
 
-- 
GitLab