Page 1 of 1

Block creation problem/anomaly

Posted: Fri Dec 20, 2019 2:28 pm
by Panchdara
Before I make a bug report, 1st) Thanks Andrew for 3.24. Always great to see QCAD being actively maintained. Thanks for addressing the block hatch issue.

I am working with some blocks and I am probably doing it all wrong, but there seems to be yet another issue: please see attached. I highlight 2 problems in the same video.

First issue is nesting same named block in a new block. I keep same reference point. The initial named block is deleted.
Second issue is when I create same named block with different reference point.

If you agree this an error, I'll write a more detailed explanation. If it's by design then I've probably lost the plot (pun intended)

Best regards

Re: Block creation problem

Posted: Fri Dec 20, 2019 3:04 pm
by andrew
Hmm.. what is the idea here?

So there's a block "block 1". Then we are creating a new block also called "block 1" which contains a reference to "block 1". This leads to a recursive block hierarchy. I.e. a "block 1" which contains a reference to "block 1" (aka itself). QCAD seems to behave as expected when complaining about recursive blocks.

Re: Block creation problem/anomaly

Posted: Fri Dec 20, 2019 3:17 pm
by Panchdara
Hi. Yes, absolutely a recursive block reference. (If you first explode block 1 then all works well). However, what I recorded just seems unusual (ie allowed the block 1 to be reused...?) The second issue is to see the multiple circles thrown across the screen.

So, could possible be handled a little better? You are the boss, but what if, IF the new named block contains a block with the same name, then that block (that has been previously named) could be either 1) exploded and placed in the new block, or 2) renamed and inserted into the new block (that seems awkward). Or just remove the ability to create a block with the same name as a previously named block?

Anyway, the behavior seems weird especially in the second case when multiple circles are added to the block.

Best regards and thanks for your continued support.

Re: Block creation problem

Posted: Fri Dec 20, 2019 10:11 pm
by andrew
Yes, I suppose it could be handled differently. I think it's a user error though. Ultimately, the user is driving QCAD and there are many ways to create such recursive block dependencies.

The offset circles are QCAD's attempt to render the recursive block. It stops after a number of iterations to prevent itself from crashing (i.e. rendering forever).