Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Kate
Commits
dd02fef6
Commit
dd02fef6
authored
Dec 29, 2021
by
Volker Krause
Browse files
Remove QStringRef leftovers
parent
a26904dd
Changes
5
Hide whitespace changes
Inline
Side-by-side
addons/symbolviewer/ecma_parser.cpp
View file @
dd02fef6
...
...
@@ -237,7 +237,7 @@ void KatePluginSymbolViewerView::parseEcmaSymbols(void)
}
// (look for functions)
// look for QML id: ....
if
(
stripped
.
mid
Ref
(
c
,
3
)
==
QLatin1String
(
"id:"
))
{
if
(
QStringView
(
stripped
)
.
mid
(
c
,
3
)
==
QLatin1String
(
"id:"
))
{
c
+=
3
;
identifier
.
clear
();
// parse the id name
...
...
addons/symbolviewer/fortran_parser.cpp
View file @
dd02fef6
...
...
@@ -114,7 +114,7 @@ void KatePluginSymbolViewerView::parseFortranSymbols(void)
}
if
(
m_macro
->
isChecked
())
// not really a macro, but a subroutines
{
stripped
+=
currline
.
right
Ref
(
currline
.
length
());
stripped
+=
QStringView
(
currline
)
.
right
(
currline
.
length
());
stripped
=
stripped
.
simplified
();
stripped
.
remove
(
QLatin1Char
(
'*'
));
stripped
.
remove
(
QLatin1Char
(
'+'
));
...
...
@@ -190,7 +190,7 @@ void KatePluginSymbolViewerView::parseFortranSymbols(void)
// Functions
else
if
(
block
==
3
)
{
if
(
m_func
->
isChecked
())
{
stripped
+=
currline
.
right
Ref
(
currline
.
length
());
stripped
+=
QStringView
(
currline
)
.
right
(
currline
.
length
());
stripped
=
stripped
.
trimmed
();
stripped
.
remove
(
QLatin1String
(
"function"
));
stripped
.
remove
(
QLatin1Char
(
'*'
));
...
...
addons/tabswitcher/tabswitcherfilesmodel.cpp
View file @
dd02fef6
...
...
@@ -62,7 +62,7 @@ QString longestCommonPrefix(std::vector<QString> const &strs)
for
(
size_t
i
=
1
;
i
<
strs
.
size
();
i
++
)
{
if
(
strs
[
i
][
pos
]
!=
strs
[
i
-
1
][
pos
])
{
// we found a mis-match
// reverse search to find path separator
const
int
sepIndex
=
strs
.
front
().
left
Ref
(
pos
).
lastIndexOf
(
QLatin1Char
(
'/'
));
const
int
sepIndex
=
QStringView
(
strs
.
front
()
)
.
left
(
pos
).
lastIndexOf
(
QLatin1Char
(
'/'
));
if
(
sepIndex
>=
0
)
{
pos
=
sepIndex
+
1
;
}
...
...
kate/katecommandbar.cpp
View file @
dd02fef6
...
...
@@ -57,7 +57,7 @@ protected:
int
score
=
0
;
const
auto
idx
=
sourceModel
()
->
index
(
sourceRow
,
0
,
sourceParent
);
const
QString
string
=
idx
.
data
().
toString
();
const
QStringView
actionName
=
string
.
split
Ref
(
QLatin1Char
(
':'
)).
at
(
1
);
const
QStringView
actionName
=
QStringView
(
string
)
.
split
(
QLatin1Char
(
':'
)).
at
(
1
);
const
bool
res
=
kfts
::
fuzzy_match
(
m_pattern
,
actionName
.
trimmed
(),
score
);
sourceModel
()
->
setData
(
idx
,
score
,
CommandModel
::
Score
);
return
res
;
...
...
kate/quickopen/katequickopen.cpp
View file @
dd02fef6
...
...
@@ -161,7 +161,7 @@ public:
int
pos
=
m_filterString
.
lastIndexOf
(
QLatin1Char
(
'/'
));
if
(
pos
>
-
1
)
{
++
pos
;
auto
pattern
=
m_filterString
.
mid
Ref
(
pos
);
auto
pattern
=
QStringView
(
m_filterString
)
.
mid
(
pos
);
auto
nameFormats
=
kfts
::
get_fuzzy_match_formats
(
pattern
,
name
,
0
,
fmt
);
formats
.
append
(
nameFormats
);
}
else
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment