Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In-block Dimension cannot be displayed #75

Open
FishOrBear opened this issue Apr 12, 2023 · 2 comments
Open

In-block Dimension cannot be displayed #75

FishOrBear opened this issue Apr 12, 2023 · 2 comments

Comments

@FishOrBear
Copy link
Contributor

block.zip
in autocad
Double-click the edit block, save it, and it will be displayed

@tarikjabiri
Copy link
Member

Please can you provide some code example

@FishOrBear
Copy link
Contributor Author

FishOrBear commented Apr 13, 2023

        let dxf = new DxfWriter;

        let block = dxf.addBlock("test");

        let f1 = {
            x: 1524.2424242424242,
            y: -18,
            z: 1470.6390303028093
        };

        let f2 = {
            x: 1524.2424242424242,
            y: -18,
            z: 270.63903030280926,
        };

        let opt: LinearDimOptions = {
            extrusion: {
                x: 0,
                y: -1,
                z: 0
            },
            middlePoint: {
                x: 1693.1677672727274,
                y: 870.6390303028093,
                z: 18
            },
            definitionPoint: {
                x: 1693.1677672727274,
                y: -18,
                z: 870.6390303028093
            },
            angle: 270
        };

        block.addEntity(new LinearDimension(f1, f2, opt));
        block.addLine({ x: 0, y: 0, z: 0 }, { x: 100, y: 0, z: 0 });

        dxf.addInsert("test", { x: 0, y: 0, z: 0 });

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants