resolve references ("Fig #" -> "Fig 1")