Skip to content

Commit

Permalink
Merge pull request #18 from kba/layouttag-type
Browse files Browse the repository at this point in the history
LayoutTagManager: Use explicit whitelist of TYPEd ALTO regions, #17
  • Loading branch information
kba authored Aug 3, 2021
2 parents d61c29d + 270760b commit 1201d08
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ocrd_page_to_alto/styles.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ def __init__(self, alto_version):
def set_alto_tag_from_type(self, reg_alto, reg_page):
typ = reg_page.get_type() if hasattr(reg_page, 'get_type') else None
if typ:
if hasattr(reg_alto, 'TYPE'):
if reg_alto.tag in ['ComposedBlock', 'Illustration']:
reg_alto.set('TYPE', typ)
reg_alto.set('TAGREFS', self.get_id(label=typ))

0 comments on commit 1201d08

Please sign in to comment.