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
PIM
KDE PIM Add-ons
Commits
8981fb3d
Commit
8981fb3d
authored
Aug 18, 2021
by
Laurent Montel
😁
Browse files
Allow to configure grammar plugins
parent
2407d85b
Pipeline
#75512
passed with stage
in 54 minutes and 16 seconds
Changes
9
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
8981fb3d
...
...
@@ -63,7 +63,7 @@ find_package(KF5GuiAddons ${KF5_MIN_VERSION} CONFIG REQUIRED)
set
(
MAILCOMMON_LIB_VERSION
"5.18.40"
)
set
(
GRAVATAR_LIB_VERSION
"5.18.40"
)
set
(
PIMCOMMON_LIB_VERSION
"5.18.4
0
"
)
set
(
PIMCOMMON_LIB_VERSION
"5.18.4
1
"
)
set
(
GRANTLEETHEME_LIB_VERSION
"5.18.40"
)
set
(
CALENDARSUPPORT_LIB_VERSION
"5.18.40"
)
set
(
EVENTVIEW_LIB_VERSION
"5.18.40"
)
...
...
kmail/grammarplugins/grammalecte/plugin/grammalecteinterface.cpp
View file @
8981fb3d
...
...
@@ -26,6 +26,9 @@ GrammalecteInterface::GrammalecteInterface(KActionCollection *ac, QWidget *paren
connect
(
mGrammarResultWidget
,
&
GrammalecteResultWidget
::
replaceText
,
this
,
&
GrammalecteInterface
::
slotReplaceText
);
connect
(
mGrammarResultWidget
,
&
GrammalecteResultWidget
::
checkAgain
,
this
,
&
GrammalecteInterface
::
checkAgain
);
connect
(
mGrammarResultWidget
,
&
GrammalecteResultWidget
::
closeChecker
,
this
,
&
GrammalecteInterface
::
closeChecker
);
connect
(
mGrammarResultWidget
,
&
GrammalecteResultWidget
::
configure
,
this
,
[
this
]()
{
Q_EMIT
configure
(
parentWidget
());
});
layout
->
addWidget
(
mGrammarResultWidget
);
createAction
(
ac
);
...
...
kmail/grammarplugins/grammarcommon/grammarresulttextedit.cpp
View file @
8981fb3d
...
...
@@ -133,6 +133,9 @@ void GrammarResultTextEdit::contextMenuEvent(QContextMenuEvent *event)
QAction
*
checkAgainAct
=
popup
->
addAction
(
QIcon
::
fromTheme
(
QStringLiteral
(
"view-refresh"
)),
i18n
(
"Check Again"
));
connect
(
checkAgainAct
,
&
QAction
::
triggered
,
this
,
&
GrammarResultTextEdit
::
checkAgain
);
popup
->
addSeparator
();
QAction
*
configureAct
=
popup
->
addAction
(
QIcon
::
fromTheme
(
QStringLiteral
(
"settings-configure"
)),
i18n
(
"Configure..."
));
connect
(
configureAct
,
&
QAction
::
triggered
,
this
,
&
GrammarResultTextEdit
::
configure
);
popup
->
addSeparator
();
QAction
*
closeAct
=
KStandardAction
::
close
(
this
,
&
GrammarResultTextEdit
::
closeChecker
,
this
);
closeAct
->
setShortcut
({});
popup
->
addAction
(
closeAct
);
...
...
kmail/grammarplugins/grammarcommon/grammarresulttextedit.h
View file @
8981fb3d
...
...
@@ -31,6 +31,7 @@ Q_SIGNALS:
void
replaceText
(
const
MessageComposer
::
PluginGrammarAction
&
act
);
void
checkAgain
();
void
closeChecker
();
void
configure
();
private:
Q_DISABLE_COPY
(
GrammarResultTextEdit
)
...
...
kmail/grammarplugins/grammarcommon/grammarresultwidget.cpp
View file @
8981fb3d
...
...
@@ -39,6 +39,7 @@ GrammarResultWidget::GrammarResultWidget(QWidget *parent)
connect
(
mResult
,
&
GrammarResultTextEdit
::
replaceText
,
this
,
&
GrammarResultWidget
::
replaceText
);
connect
(
mResult
,
&
GrammarResultTextEdit
::
checkAgain
,
this
,
&
GrammarResultWidget
::
checkAgain
);
connect
(
mResult
,
&
GrammarResultTextEdit
::
closeChecker
,
this
,
&
GrammarResultWidget
::
closeChecker
);
connect
(
mResult
,
&
GrammarResultTextEdit
::
configure
,
this
,
&
GrammarResultWidget
::
configure
);
mainLayout
->
addWidget
(
mResult
);
}
...
...
kmail/grammarplugins/grammarcommon/grammarresultwidget.h
View file @
8981fb3d
...
...
@@ -28,6 +28,7 @@ Q_SIGNALS:
void
replaceText
(
const
MessageComposer
::
PluginGrammarAction
&
act
);
void
checkAgain
();
void
closeChecker
();
void
configure
();
protected:
virtual
void
addExtraWidget
();
...
...
kmail/grammarplugins/languagetool/plugin/languagetoolinterface.cpp
View file @
8981fb3d
...
...
@@ -27,6 +27,9 @@ LanguageToolInterface::LanguageToolInterface(KActionCollection *ac, QWidget *par
connect
(
mGrammarResultWidget
,
&
LanguageToolResultWidget
::
replaceText
,
this
,
&
LanguageToolInterface
::
slotReplaceText
);
connect
(
mGrammarResultWidget
,
&
LanguageToolResultWidget
::
checkAgain
,
this
,
&
LanguageToolInterface
::
checkAgain
);
connect
(
mGrammarResultWidget
,
&
LanguageToolResultWidget
::
closeChecker
,
this
,
&
LanguageToolInterface
::
closeChecker
);
connect
(
mGrammarResultWidget
,
&
LanguageToolResultWidget
::
configure
,
this
,
[
this
]()
{
Q_EMIT
configure
(
parentWidget
());
});
layout
->
addWidget
(
mGrammarResultWidget
);
createAction
(
ac
);
...
...
kmail/grammarplugins/languagetool/plugin/languagetoolinterface.h
View file @
8981fb3d
...
...
@@ -15,7 +15,7 @@ public:
explicit
LanguageToolInterface
(
KActionCollection
*
ac
,
QWidget
*
parent
=
nullptr
);
~
LanguageToolInterface
()
override
;
KToggleAction
*
action
()
const
override
;
Q_REQUIRED_RESULT
KToggleAction
*
action
()
const
override
;
private:
Q_DISABLE_COPY
(
LanguageToolInterface
)
...
...
kmail/grammarplugins/languagetool/plugin/languagetoolplugin.cpp
View file @
8981fb3d
...
...
@@ -31,6 +31,7 @@ PimCommon::CustomToolsViewInterface *LanguageToolPlugin::createView(KActionColle
connect
(
view
,
&
LanguageToolInterface
::
toolsWasClosed
,
parent
,
&
PimCommon
::
CustomToolsWidgetNg
::
slotToolsWasClosed
);
connect
(
view
,
&
LanguageToolInterface
::
insertText
,
parent
,
&
PimCommon
::
CustomToolsWidgetNg
::
insertText
);
connect
(
view
,
&
LanguageToolInterface
::
activateView
,
parent
,
&
PimCommon
::
CustomToolsWidgetNg
::
slotActivateView
);
connect
(
view
,
&
LanguageToolInterface
::
configure
,
this
,
&
LanguageToolPlugin
::
showConfigureDialog
);
return
view
;
}
...
...
Write
Preview
Supports
Markdown
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