Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

g2 如何给画布背景色,下载图片时背景色是透明的,使用theme无作用 #2484

Closed
git-csy opened this issue May 21, 2020 · 8 comments
Assignees

Comments

@git-csy
Copy link

git-csy commented May 21, 2020

  • G2 Version:
  • Platform:
  • Mini Showcase(like screenshots):
  • CodePen Link:
@git-csy git-csy changed the title g g2 如何给画布背景色,下载图片时背景色是透明的,使用theme无作用 May 21, 2020
@git-csy
Copy link
Author

git-csy commented May 21, 2020

企业微信截图_15900607623106
主题还是存在部分问题吧

@Sai0514
Copy link
Contributor

Sai0514 commented Jun 28, 2020

同问,并且theme目前只有‘dark’生效,background也是加在div上面,似乎并不是绘制在canvas上面的?

@hustcc
Copy link
Member

hustcc commented Sep 18, 2020

4.1已经改成不用 css 了,可以导出黑色背景了。

@hustcc hustcc closed this as completed Sep 18, 2020
@Arco1ris
Copy link

Arco1ris commented Jun 22, 2022

如果渲染的时候配置了 slider,下载的时候,slider 及其周边还是透明的(修改 slider 背景色也只改变了 slider 本身的背景色,它的周边还是透明色),只有上面坐标轴区域是 theme 配置的背景色。截图是下载后的图片
截屏2022-06-22 下午3 02 03

@Arco1ris
Copy link

@hustcc 请问这种情况应如何处理

@hustcc
Copy link
Member

hustcc commented Jun 22, 2022

slider 没有使用 theme 中的背景色是这个意思嘛?

@Arco1ris
Copy link

slider 没有使用 theme 中的背景色是这个意思嘛?

是的

@hustcc
Copy link
Member

hustcc commented Jun 22, 2022

主题中的 background 是印象 view,理论上 view 的大小是包含 slider 区域的,这个我们排查下。 ref #3299

@antvis antvis locked and limited conversation to collaborators May 29, 2023
@hustcc hustcc converted this issue into discussion #5112 May 29, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →