Code: Select all
Qt::CaseSensitivity sens = noCase ? Qt::CaseInsensitive : Qt::CaseSensitive;
bool retVal = false;
int rslt = 0;
if ( column < 1 )
{
rslt = a.compare( b, sens );
}
else
{
int pos = column - 1;
QStringView aView( a.midView( pos ) );
QStringView bView( b.midView( pos ) );
rslt = aView.compare( bView, sens );
Code: Select all
home/roland/sf_projects/reddiamond/src/edtbasewidget.cpp: In lambda function:
/home/roland/sf_projects/reddiamond/src/edtbasewidget.cpp:3591:47: error: no matching function for call to ‘Cs::QStringView<QString8>::compare(QStringView&, Qt::CaseSensitivity&)’
3591 | rslt = aView.compare( bView, sens );
| ^
In file included from /usr/lib/cs_lib/include/QtCore/qstringview.h:29,
from /usr/lib/cs_lib/include/QtCore/qstring8.h:34,
from /usr/lib/cs_lib/include/QtCore/csmeta_internal_1.h:28,
from /usr/lib/cs_lib/include/QtCore/csmeta.h:28,
https://www.copperspice.com/docs/cs_api/class_qstringview.html
That should work.