If you are changing the text dynamically and the widget with the text is getting longer, you must be resizing it with Set Size, correct? After that action, just use a Move ‘MyLabel’ action. You can refer to a widget and its properties by using a local variable in in the fx Edit Text dialog. Common widget properties include .x, .y, .left, .right, .top, .bottom which can help you place widgets relative to other widgets. For example,
Move MyLabel to ([[LVAR1.right + 10]], [[LVAR1.top]])
…where LVAR1 is a local variable pointing a widget, like, ‘MyTitle’. This should place ‘MyLabel’ to the right of ‘MyTitle’ with a 10px margin, and top-aligned.
The best approach I’ve found to automate this is to create a dynamic panel out of the widget or selection of widgets (and keep the default “Fit to Content” setting for the dynamic panel.) In this dynamic panel’s OnResize event, create a Move action, such as:
Move MyLabel to ([[This.right + 10]], [[This.top]])
If you use a widget’s *OnLoad event, then it would work only once–when the page is loaded. (Although you could trigger it later using a Fire Event action.) Using a count of characters would only work for fixed-width fonts, like Courier New or System. It doesn’t work for proportional fonts as each character has different widths. But, if you are using a fixed-width font you can get the character count of the text on any widget using the “length of widget value” option or a local variable call with [[LVAR1.length]] where “LVAR1” is the “text on widget”.
Here is a link to a thread from a few years back with this same issue, only moving an image widget instead of a text label widget. Would certainly work for your issue though.
Since you are dealing with text only (in both your title and label widgets) another possible solution would be to just include both text strings in one widget. Use the “rich text” option in the Set Text action to change the font properties of the title portion and the label portion.