Sincere love for men is the greatest result of love for the Lord of Heaven. This is what is meant by the expression "Humanity is the love of man." If a man does not love his fellowmen, how can one tell that he sincerely respects the Lord on High? The love of man is no feigned love since it must result in the feeding of the hungry, in the giving of drink to the thirsty, in the clothing of those without clothes, and in the provision of places to live for the homeless. Love has compassion for and comforts those who experience troubles; it instructs the ignorant, corrects the wrongdoers, forgives those who humiliate me, buries the dead, and dares not to forget to pray to the Sovereign on High for all men, living or dead. Therefore, in former times in the West, there was a certain man who went to inquire of a sage what he must do to be good. The answer was: "Love the Lord of Heaven and do as you wish." What the sage meant was that if a man chose to follow this wise advice, he would, as a matter of course, be unable to take the wrong path.
[Matteo Ricci, The True Meaning of the Lord of Heaven, Lancashire and Hu Kuo-chen, trs., Menard, ed., Institute of Jesuit Sources (Boston: 2016), Chapter 7, section 477, p. 313.]
The first quotation is from Mencius, the second a slight paraphrase of Augustine. In the works of mercy, Ricci doesn't here mention visiting the sick, visiting the imprisoned, counseling the doubtful, and bearing wrongs patiently; but it's possible that visiting the sick and counseling the doubtful may be taken to be directly implied. The other two are much more closely related to problems that the Chinese scholar interlocutor is having with this aspect of Christian doctrine; they will go on next to discuss what it could possibly mean to love a bad person.