How QRegularExpression can be passed to Qt::MatchRegularExpression
问题 I am trying this sample code that I found which is really really good. I am also trying to figure out the same thing to find an item and scroll to it, but this time I wanted to match the the string which has the EXACT WORD "cat" . Example matches: cat tom cat dog and cat super cat To make it very simple I am just trying to match an exact word in a string. Take this sample code as an example: import re s= "1 tom cat" s2 = "2 thundercat" if re.search(r'\bcat\b',s2): print("There is an EXACT