Skip to content

Headless get_window_extent or equivalent #5916

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Immortalin opened this issue Jan 26, 2016 · 2 comments
Closed

Headless get_window_extent or equivalent #5916

Immortalin opened this issue Jan 26, 2016 · 2 comments

Comments

@Immortalin
Copy link

Is it possible to call get_window_extent headlessly? In a third party library, it is currently failing because it requires a renderer but the output is actually a headless html file so there is no way to determine the boundaries at runtime. Refer (plotly/plotly.py#381)

@tacaswell
Copy link
Member

You can use the Agg backend which does not require a gui framework, but you will need to trigger a draw before you try to access the window extent. There are some number we really do not know until the first time the figure gets drawn.

What backend are you using?

@Immortalin
Copy link
Author

@tacaswell I am using Agg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants