we have to delete node 4 in the pic posted by you. right?
you are saying "if we delete node 4 our heap doesn't remain an almost complete binary tree. So it is violating heap property."
I am saying that we don't need to delete the node 4 directly. We can follow the following steps and actually can delete a node from heap even that is in middle:
1. Exchange the node to be deleted with the last node of the heap. here node 4 will be exchanged with node5.
2. reduce heap size by 1. thus node 4 is being deleted
3 Now apply max or min heapify on node 5.
Why can't we do this and delete the required node?
Here heap property is also being preserved.