BCGControlBar Pro for MFC
virtual BOOL CBCGPEditCtrl::CanRemoveMarker ( CBCGPEditMarker pMarker) const

Called by the framework when it's about to remove a marker.

Should return TRUE if the marker can be removed; otherwise FALSE.

This function is called by the edit control when it's about to remove a marker as a result of deleted string. You should override this function in a derived class in case you need some type of markers be constant. For example, you want to make the line number 3 highlighted in any case. You can override CanRemoveMarker, check for the marker type (CBCGPEditMarker::m_dwMarkerType) and if the marker line (CBCGPEditMarker::m_nLine) is 3 return FALSE.

pMarkerPoints to the marker to be removed.