Skip to content

Commit

Permalink
Fix loose character; sorry
Browse files Browse the repository at this point in the history
  • Loading branch information
jnothman committed Apr 9, 2017
1 parent 6d3ffc6 commit 6ff8a46
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion pandas/formats/excel.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ def build_xlstyle(self, props):
'fill': self.build_fill(props),
'font': self.build_font(props),
}
# TODO: support number format
# TODO: handle cell width and height: needs support in pandas.io.excel

def remove_none(d):
Expand Down Expand Up @@ -207,6 +208,16 @@ def build_font(self, props):
assert size.endswith('pt')
size = float(size[:-2])

# TODO:
# re.search(r'''(?x)
# (
# "(?:[^"]|\\")+"
# |
# '(?:[^']|\\')+'
# |
# [^'"]+
# )(?=,|\s*$)
# ''')
font_names = [name.strip()
for name in props.get('font-family', '').split(',')
if name.strip()]
Expand Down Expand Up @@ -237,7 +248,7 @@ def build_font(self, props):
'italic': self.ITALIC_MAP.get(props.get('font-style')),
'underline': ('single' if
decoration is not None and
'underline' in decoration`
'underline' in decoration
else None),
'strike': (None if decoration is None
else 'line-through' in decoration),
Expand Down

0 comments on commit 6ff8a46

Please sign in to comment.