Skip to content

Commit

Permalink
made spanannotation @t textclass aware (thanks to @kosloot for pointi…
Browse files Browse the repository at this point in the history
…ng it out)
  • Loading branch information
proycon committed Oct 19, 2017
1 parent cc597ee commit b020284
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pynlpl/formats/folia.py
Original file line number Diff line number Diff line change
Expand Up @@ -4288,8 +4288,8 @@ def xml(self, attribs = None,elements = None, skipchildren = False):
if isinstance(child, Word) or isinstance(child, Morpheme) or isinstance(child, Phoneme):
#Include REFERENCES to word items instead of word items themselves
attribs['{' + NSFOLIA + '}id'] = child.id
if child.PRINTABLE and child.hastext():
attribs['{' + NSFOLIA + '}t'] = child.text()
if child.PRINTABLE and child.hastext(self.textclass):
attribs['{' + NSFOLIA + '}t'] = child.text(self.textclass)
e.append( E.wref(**attribs) )
elif not (isinstance(child, Feature) and child.SUBSET): #Don't add pre-defined features, they are already added as attributes
e.append( child.xml() )
Expand Down

0 comments on commit b020284

Please sign in to comment.