0

I am using QT::MatchExactly in my QStandardItemModel in the findItems method. I wanted to know is there anyway to turn it into case insensitive ? Currently i have something like this:

mymodel->findItems("abc",Qt::MatchExactly,0);
4

1 回答 1

1

使用Qt::MatchFixedString

mymodel->findItems("abc", Qt::MatchFixedString, 0);

最后一个参数已经默认为 0,顺便说一句,所以你可以写:

mymodel->findItems("abc", Qt::MatchFixedString);
于 2013-07-19T16:08:54.283 回答