joycewang
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-13-2016
01:07 AM
Scene Graph XML: dynamic width of a Label
Is there any way to get the dynamic width of a Label in Scene Graph XML? I'm asked to provide a dynamic focus box around a label and need to know the dynamic width.
Normally I just use roFont.GetOneLineWidth(), but it seems roFont cannot be used in Scene Graph XML. Is there any properties in Label that I can get it's width or some other approaches?
Sample code would be great helpful. thanks in advance.
Normally I just use roFont.GetOneLineWidth(), but it seems roFont cannot be used in Scene Graph XML. Is there any properties in Label that I can get it's width or some other approaches?
Sample code would be great helpful. thanks in advance.
2 REPLIES 2
MediaDev
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-13-2016
09:35 PM
Re: Scene Graph XML: dynamic width of a Label
Please try using boundingRect() after the label is set.
Regards
Media dev
Regards
Media dev
youssefsherif
Streaming Star
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-20-2022
12:52 AM
Re: Scene Graph XML: dynamic width of a Label
how can i do that?