Features
Supports both DBText and MText
Accurate bounding box with adjustable margin (offsetFactor)
Handles arbitrary text rotation (0–360°)
Honors text's normal vector and alignment
Works in model space or paper space
Automatically inherits layer, color, linetype, and lineweight of the text