modified the pretty printer to sort the cells of a bag according to the their order in user-declared configuration