Skip to content

Commit

Permalink
Merge pull request #317 from Vauxoo/15.0
Browse files Browse the repository at this point in the history
Syncing from upstream Vauxoo/addons-vauxoo (15.0)
  • Loading branch information
bt-admin authored Jan 25, 2024
2 parents bfb4ef8 + b8fcca0 commit 2bdc153
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion controller_report_xls/reports/report_xls.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ def get_odoo_style(html, style, node):
styleclass = get_css_style(style_element.text, class_style)
style.update(dict(item.split(":") for item in text_adapt(styleclass).split(";") if item != ""))
if node.attrib.get("style", False):
style.update(dict(item.split(":") for item in node.attrib.get("style").split(";") if item != ""))
style_nodes = [style_node.strip() for style_node in node.attrib.get("style").split(";") if style_node.strip()]
style.update(dict(item.split(":", 1) for item in style_nodes))
return style


Expand Down
4 changes: 2 additions & 2 deletions controller_report_xls/reports/xfstyle.py
Original file line number Diff line number Diff line change
Expand Up @@ -291,8 +291,8 @@ def get_font_height(height):
factor = 1.5
elif height == "XX-LARGE":
factor = 2
new_size = float(size * factor * 20)
return new_size
# NOTE: Rounding without decimals because the expected `height` needs to be an `integer` value
return round(size * factor * 20)


def get_horizontal_align(halign, align):
Expand Down

0 comments on commit 2bdc153

Please sign in to comment.