How do I set the correct size for a WidgetLayer
?
#363
Unanswered
cutehackers
asked this question in
Q&A
Replies: 1 comment
-
In that case, you need to calculate the required scale factor to ensure your widget has the correct size. For example, if your widget should have a width of WidgetLayer(
widget: widget,
scale: 5,
), |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is it possible to add custom widget to the image editor? Currently I adding a custom widget to editor and I found that the width of the widget is initially set by StickerEditConfig.initWidth * initScale. This makes the widget is way smaller when it's drawn to the editor, which I didn't intend to. so I'm wondering if there's a way to add custom widgets gracefully. thanks in advance.
fyi, I was trying to add custom widget using WidgetLayer but failed because I failed to set the initial width of that. width or height may be different for each widget.
Beta Was this translation helpful? Give feedback.
All reactions