Skip to content

[ENH]: add_collection(..., autolim=True) should update view limits as well #29957

@timhoffm

Description

@timhoffm

Problem

Axes.add_collection() has the parameter autolim, which updates Axes.dataLim, however it does not update Axes.viewLim. This requires an explicit ax.autoscale_view() - or when using it internally, we use the lazy ax._request_autoscale_view.

Proposed solution

Axes.add_collection(..., autolim=True) should itself call ax._request_autoscale_view(). If we opt into limits handling, this should possibly include the view limits as well. Requireing an extra call from users is cumbersome. Also since ax._request_autoscale_view() is private, users can only call the eager ax.autoscale_view().

Todo: Investigate how to make this work correctly for 3D, which seems to use a dedicated auto_scale_xyz().

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

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy