Align rviz marker text
I'm making rviz markers by following the ROS wiki docs for rviz markers. I'm working with the TEXT_VIEW_FACING
type of marker. By default, the text is centered on marker.pose.position
, but I'd really like to left-align the text.
I'd do this by adding half its width to the y-position, but I don't know the marker's width. I could compute it from number of characters and average character width, but rviz uses a variable-width font, so that's only an approximation.
Is there a good way to cleanly align rviz marker text?