Hi,
Is it possible to get the size in pixels of entities in a drawing as if they were projected on a screen when using the js api?
More precisely what I'm trying to achieve is to zoom an RBox on the entire view port and then calculate its pixel size and the pixel size of all of the entities contained inside that RBox.
Thanks,
Yair
Calculate size of entities in pixels
Moderator: andrew
Forum rules
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
Always indicate your operating system and QCAD version.
Attach drawing files and screenshots.
Post one question per topic.
Re: Calculate size of entities in pixels
You can convert between vector measurements and screen measurements (pixels) using the map functions in RGraphicsView (mapToView, mapDistanceToView, mapFromView, mapDistanceFromView).