Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

patheffects.SimpleLineShadow calling non-existentget_foreground method from GraphicsContextBase #28793

Open
@wsidl

Description

@wsidl

Summary

Source documentation shares that ifshadow_color is None, the rho value would be applied to the original color:

https://matplotlib.org/stable/api/patheffects_api.html#matplotlib.patheffects.SimpleLineShadow

Expected Behaviour

Usingoffset=(0, 0), shadow_color=None, rho=0.6, was looking to explore if a guassian blue would take place to generate a wide, feathered line following the pattern of a gaussian distribution.

Resulting Behaviour

Code fails with:

  File "/project/path/.venv/lib/python3.11/site-packages/matplotlib/patheffects.py", line 336, in draw_path    r, g, b = (gc0.get_foreground() or (1., 1., 1.))[:3]               ^^^^^^^^^^^^^^^^^^AttributeError: 'GraphicsContextBase' object has no attribute 'get_foreground'. Did you mean: 'set_foreground'?

Related line in repo:

r,g,b= (gc0.get_foreground()or (1.,1.,1.))[:3]

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp