_getSurroundingLines now skips empty lines