Show
Ignore:
Timestamp:
02/23/08 07:17:21 (4 years ago)
Author:
erik
Message:

Fix: if a psHintValues object is initialised without a parent, it should not try to load the lib.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/robofab/Lib/robofab/objects/objectsRF.py

    r36 r40  
    6565                # read the data from the font.lib, it won't be anywhere else 
    6666                BasePostScriptFontHintValues.__init__(self) 
    67                 data = aFont.lib.get(postScriptHintDataLibKey) 
     67                data = None 
     68                if aFont is not None: 
     69                        self.setParent(aFont) 
     70                        data = aFont.lib.get(postScriptHintDataLibKey) 
    6871                if data is not None: 
    6972                        self.fromDict(data) 
    70                 if aFont is not None: 
    71                         self.setParent(aFont) 
    7273 
    7374def getPostScriptHintDataFromLib(aFont, fontLib):