Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
KDevelop
KDevelop
Commits
43857a23
Commit
43857a23
authored
Sep 22, 2021
by
Igor Kushnir
Browse files
Share the list returned by AStylePlugin::predefinedStyles()
Creating all predefined styles in every function call is inefficient.
parent
2cd07174
Changes
1
Hide whitespace changes
Inline
Side-by-side
plugins/astyle/astyle_plugin.cpp
View file @
43857a23
...
...
@@ -272,7 +272,7 @@ SourceFormatterStyle predefinedStyle(const QString& name, const QString& caption
QVector
<
SourceFormatterStyle
>
AStylePlugin
::
predefinedStyles
()
const
{
return
{
static
const
QVector
<
SourceFormatterStyle
>
list
=
{
predefinedStyle
(
QStringLiteral
(
"ANSI"
)),
predefinedStyle
(
QStringLiteral
(
"GNU"
)),
predefinedStyle
(
QStringLiteral
(
"Java"
)),
...
...
@@ -286,6 +286,7 @@ QVector<SourceFormatterStyle> AStylePlugin::predefinedStyles() const
predefinedStyle
(
QStringLiteral
(
"KDELibs"
),
QStringLiteral
(
"KDE Frameworks"
)),
predefinedStyle
(
QStringLiteral
(
"Qt"
)),
};
return
list
;
}
SettingsWidget
*
AStylePlugin
::
editStyleWidget
(
const
QMimeType
&
mime
)
const
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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