View CAD files in WebViewer

Product: WebViewer

Product Version: Lastest WebViewer Server trial version

I just want to confirm if DWG files become static (cannot rotate) in the WebViewer?

I have setup the WebViewer Server to handle DWG files, when I open it locally the drawing is static, I cannot rotate it. Is it expected?

By the feature list, I thought I was going to be able to rotate the drawings (DWG, DWF, DXF files) using the WebViewer.

Hello, I’m Ron, an automated tech support bot :robot:

While you wait for one of our customer support representatives to get back to you, please check out some of these documentation pages:

Guides:APIs:Forums:

Hello Edson,

By rotation do you mean rotation of the page within the document (for use in other viewers as well), or do you mean just a visual rotation within WebViewer?

If by rotation you mean a rotation of the document page itself, unfortunately, this is not supported for any files other than PDFs.

If you mean visual rotation this is supported and can be done through the header bar in UI to rotate all pages.
image

The UI to rotate the individual pages is coming in the next release (soon) but it can still be done in the code using the Core API.
Here is a code snippet and some relevant APIs

    const { UI, Core } = instance;
    const { documentViewer, annotationManager } = Core;

    documentViewer.rotateClockwise([1]); // Rotate page 1 clockwise 90 deg

setPageRotations
rotateClockwise

Let me know if there are any issues.

Best Regards,
Ahmad Moaaz
Software Developer
PDFTron Systems, Inc.
www.pdftron.com