QCAD Bugtracker

  • Status Assigned
  • Percent Complete
    0%
  • Task Type Feature Request
  • Category QCAD (main)
  • Assigned To
    Andrew
  • Operating System All
  • Severity Very Low
  • Priority Defer
  • Reported Version 3.21.2
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: QCAD Bugtracker
Opened by Husky - 23.07.2018
Last edited by Andrew - 23.07.2018

FS#1788 - Allow snapping to reference point of a block reference

I know this was reported and fixed before ...

https://www.qcad.org/bugtracker/index.php?do=details&task_id=843

... but it looks like we have the issue now back with some kind of variation.

If I use the test drawing which I posted in 2013 ( FS#843 ) it works still as expected after it was fixed.

If I create a new block it won’t work in a new drawing nor in the old test drawing - no chance to snap to the Block Reference.

Edit: New Test drawing:

Admin
Andrew commented on 23.07.2018 18:49

The problem is that there is no entity close to the reference point of that block. QCAD does not even consider looking at that block reference if the mouse pointer hovers close to the reference point since there's nothing there..

I'll defer this for now until I have a good idea how to solve this.. perhaps a separate snap or something.

Husky commented on 23.07.2018 19:22

Thanks for the explanation but frankly I don't understand what you are trying to tell me.
It was working before - it broke - and is now a Feature request and not a bug?

QCAD does not even consider looking at that block reference if the mouse pointer hovers close to the reference point since there's nothing there.. «

What means "there is nothing there"? QCAD was able to find something (Block reference) in drawings which are created in older QCAD Versions ...

Admin
Andrew commented on 23.07.2018 20:13

This would have worked in old versions when QCAD would only snap to the reference point of the block reference but not to reference points of entities in the block. You would then simply move the mouse close to any visible part of the block reference and it would snap to the reference point of the block ref, not the reference point of the entity inside the block.

It's a bit difficult to explain why the file "reference snap test.dxf" works and "can't snap to block reference point.dxf" doesn't, but it has nothing to do with the QCAD version. In a nutshell, the diagonal line in "reference snap test.dxf" makes it work because its bounding box contains the reference point, so QCAD 'finds' the block reference when the user hovers the mouse pointer close to it. "can't snap to block reference point.dxf" has only bounding boxes which do not contain the reference point, so there's no chance for QCAD to even find the block reference when user hovers close to the reference point.

Bottom line: as counter intuitive as this may seem, this is expected behaviour with the current implementation of reference point snapping and there's no easy way around this. All entity lookup is based on bounding boxes in QCAD which is essential for performance (through a spatial index).

Hope this makes at least some sense now ;)

Husky commented on 24.07.2018 02:16

Thanks for taking the time to explain it again and believe it or not - I understood it now. ;))

My first thought was that maybe there is a way to put automatically an additional bounding box covering the whole block which will consequently cover at least all "Free" Reference Points inside a Block ... but I'm sure that isn't that easy.
Anyway - I still think that is an very important snap and it would be nice to get one day a solution.

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing