Skip to content

Commit

Permalink
Draft: rename svg parameter to fillspaces (lowercase)
Browse files Browse the repository at this point in the history
  • Loading branch information
vocx-fc authored and yorikvanhavre committed Sep 9, 2020
1 parent b835e5f commit 5cf799d
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 11 deletions.
2 changes: 1 addition & 1 deletion src/Mod/Arch/ArchSectionPlane.py
Expand Up @@ -562,7 +562,7 @@ def getSVG(source,
color=lineColor,
techdraw=techdraw,
rotation=rotation,
fillSpaces=fillSpaces)
fillspaces=fillSpaces)
if not techdraw:
svg += '</g>'

Expand Down
24 changes: 14 additions & 10 deletions src/Mod/Draft/draftfunctions/svg.py
Expand Up @@ -707,7 +707,7 @@ def get_svg(obj,
scale=1, linewidth=0.35, fontsize=12,
fillstyle="shape color", direction=None, linestyle=None,
color=None, linespacing=None, techdraw=False, rotation=0,
fillSpaces=False, override=True):
fillspaces=False, override=True):
"""Return a string containing an SVG representation of the object.
Paramaeters
Expand Down Expand Up @@ -748,7 +748,7 @@ def get_svg(obj,
rotation: float, optional
It defaults to 0.
fillSpaces: bool, optional
fillspaces: bool, optional
It defaults to `False`.
override: bool, optional
Expand All @@ -765,7 +765,7 @@ def get_svg(obj,
scale, linewidth, fontsize,
fillstyle, direction, linestyle,
color, linespacing, techdraw,
rotation, fillSpaces, override)
rotation, fillspaces, override)
return svg

pathdata = []
Expand Down Expand Up @@ -1224,7 +1224,7 @@ def get_svg(obj,

if App.GuiUp:
vobj = obj.ViewObject
if fillSpaces and hasattr(obj, "Proxy"):
if fillspaces and hasattr(obj, "Proxy"):
if not hasattr(obj.Proxy, "face"):
obj.Proxy.getArea(obj, notouch=True)
if hasattr(obj.Proxy, "face"):
Expand Down Expand Up @@ -1373,15 +1373,19 @@ def get_svg(obj,

def getSVG(obj,
scale=1, linewidth=0.35, fontsize=12,
fillstyle="shape color", direction=None, linestyle=None,
color=None, linespacing=None, techdraw=False, rotation=0,
fillstyle="shape color", direction=None,
linestyle=None,
color=None, linespacing=None,
techdraw=False, rotation=0,
fillSpaces=False, override=True):
"""Return SVG string of the object. DEPRECATED. Use 'get_svg'."""
utils.use_instead("get_svg")
return get_svg(obj,
scale, linewidth, fontsize,
fillstyle, direction, linestyle,
color, linespacing, techdraw, rotation,
fillSpaces, override)
scale=scale, linewidth=linewidth, fontsize=fontsize,
fillstyle=fillstyle, direction=direction,
linestyle=linestyle,
color=color, linespacing=linespacing,
techdraw=techdraw, rotation=rotation,
fillspaces=fillSpaces, override=override)

## @}

0 comments on commit 5cf799d

Please sign in to comment.