How does zrender: center text in rect?

question:

has not been using zrender for long. As shown in the figure, text and rect are the same group, doing everything possible to center the word and wrap lines beyond the width . It"s not good to set textWidth in new zrender.Text "s style, nor is it good to set textWidth in new zrender.Rect. Where can I limit the width of the text? Rect has width

Jun.28,2021
Insert \ n


attribute textoffset: [XMagi y] into the


character and try

Menu