We are trying to draw some text with a conduit on a detailed view in a page layout. For this we want to draw the text always in the same height that it looks like a technical drawing. But when the detail view has a paper - model scaling other than 1:1 we cannot retrieve the right transformation.
What we have done so far to draw a 2mm height text on a detail view with 1:1 scaling:
Get view transformation to orient the text always horizontal and in view direction
ON_3dVector y = vp.VP().CameraUp();
ON_3dVector z = vp.VP().CameraDirection(); z.Reverse();
ON_3dVector x = ON_CrossProduct(y, z);
w2s_neu.Rotation(ON_3dVector::XAxis, ON_3dVector::YAxis, ON_3dVector::ZAxis, x, y, z);
Get text scale
scalePos.Scale(posTextHeight * corr, posTextHeight * corr, posTextHeight * corr);
Get point translation
Set model transformation of the viewport
dp.GetRhinoVP().SetModelXform(trans * scalePos * w2s_neu);
dp.DrawString(ON_Plane(ON_3dPoint(0.1, 0.1, 0), ON_3dVector::ZAxis), ON_Color(0, 0, 0), rt);
If i now change the scaling of the detail view the text size also changes accordingly which is not wanted!
My question: how can i retrieve the paper - model scaling of the detail view which i am currently draw on?