Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/PIL/ImageDraw.py
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ def getink(fill: _Ink | None) -> int:
return fill_ink
return ink

def draw_text(ink, stroke_width=0, stroke_offset=None) -> None:
def draw_text(ink, stroke_width=0) -> None:
mode = self.fontmode
if stroke_width == 0 and embedded_color:
mode = "RGBA"
Expand Down Expand Up @@ -664,8 +664,6 @@ def draw_text(ink, stroke_width=0, stroke_offset=None) -> None:
)
except TypeError:
mask = font.getmask(text)
if stroke_offset:
coord = [coord[0] + stroke_offset[0], coord[1] + stroke_offset[1]]
if mode == "RGBA":
# font.getmask2(mode="RGBA") returns color in RGB bands and mask in A
# extract mask and set text alpha
Expand Down