[prev in list] [next in list] [prev in thread] [next in thread]
List: kwin
Subject: Re: Review Request 108975: Provide config interface for scripted effects and KWin scripts
From: Martin_Gräßlin <mgraesslin () kde ! org>
Date: 2013-02-28 8:55:13
Message-ID: 20130228085513.25758.50785 () vidsolbach ! de
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/108975/
-----------------------------------------------------------
(Updated Feb. 28, 2013, 9:55 a.m.)
Review request for kwin.
Changes
-------
adding translation support at least for scripts shipped with KWin.
Description (updated)
-------
Extract messages from scripts and scripting module
Messages in scripts are written to kwin_scripts.pot, messages in
scripting are written to kwin_scripting.pot. The cataloges are loaded in
the configuration interfaces and in main kwin.
Provide config interface for scripted effects and KWin scripts
A scripted component providing:
* ui/config.ui
* config/main.xml
can get a config interface by using the following in metadata.desktop:
X-KDE-ServiceTypes=KWin/Effect,KCModule
X-KDE-PluginKeyword=`X-KDE-PluginInfo-Name`
X-KDE-Library=kcm_kwin4_genericscripted
X-KDE-ParentComponents=`X-KDE-PluginInfo-Name`
`X-KDE-PluginInfo-Name` has to be replaced by the actual value. In case
of a KWin Script the X-KDE-ServiceTypes needs to be:
X-KDE-ServiceTypes=KWin/Script,KCModule
The GenericScriptedConfig tries to identify the package from the keyword
and creates a Plasma::ConfigLoader and loads the UI from the packaged UI
file.
Use Plasma::ConfigLoader to read config values in scripted effects
Advantage is that the default value is no longer needed and scripted
effects are anyway supposed to add a kconfigxt file.
Diffs (updated)
-----
kwin/CMakeLists.txt b5b0385035e182db166ead3ead754ab39e6ad763
kwin/kcmkwin/kwincompositing/main.cpp e802b4624c6453d6ea4ec575a5e4e69346bad758
kwin/kcmkwin/kwinscripts/module.cpp 6327d24e42a7fdc1d97329bf024d8fb590cc424a
kwin/main.cpp 9f199638fc1293e2ad0ea7b70a850da2b73b25f1
kwin/scripting/CMakeLists.txt PRE-CREATION
kwin/scripting/Messages.sh PRE-CREATION
kwin/scripting/genericscriptedconfig.h PRE-CREATION
kwin/scripting/genericscriptedconfig.cpp PRE-CREATION
kwin/scripting/scriptedeffect.h 63eb66c9708e82a5b3d384a8e5a819578bcf3a25
kwin/scripting/scriptedeffect.cpp 83650f11dc68c7047900ac66ee30a8a83c9dc924
kwin/scripts/Messages.sh PRE-CREATION
Diff: http://git.reviewboard.kde.org/r/108975/diff/
Testing
-------
tested with the scripted login effect
Thanks,
Martin Gräßlin
[Attachment #5 (text/html)]
<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;"> <tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="http://git.reviewboard.kde.org/r/108975/">http://git.reviewboard.kde.org/r/108975/</a>
</td>
</tr>
</table>
<br />
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('http://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;"> <tr>
<td>
<div>Review request for kwin.</div>
<div>By Martin Gräßlin.</div>
<p style="color: grey;"><i>Updated Feb. 28, 2013, 9:55 a.m.</i></p>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Changes</h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0"> <tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">adding translation support at least for scripts shipped with KWin.</pre> \
</td> </tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description \
(updated)</h1> <table width="100%" bgcolor="#ffffff" cellspacing="0" \
cellpadding="10" style="border: 1px solid #b8b5a0"> <tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Extract messages from scripts and scripting module
Messages in scripts are written to kwin_scripts.pot, messages in
scripting are written to kwin_scripting.pot. The cataloges are loaded in
the configuration interfaces and in main kwin.
Provide config interface for scripted effects and KWin scripts
A scripted component providing:
* ui/config.ui
* config/main.xml
can get a config interface by using the following in metadata.desktop:
X-KDE-ServiceTypes=KWin/Effect,KCModule
X-KDE-PluginKeyword=`X-KDE-PluginInfo-Name`
X-KDE-Library=kcm_kwin4_genericscripted
X-KDE-ParentComponents=`X-KDE-PluginInfo-Name`
`X-KDE-PluginInfo-Name` has to be replaced by the actual value. In case
of a KWin Script the X-KDE-ServiceTypes needs to be:
X-KDE-ServiceTypes=KWin/Script,KCModule
The GenericScriptedConfig tries to identify the package from the keyword
and creates a Plasma::ConfigLoader and loads the UI from the packaged UI
file.
Use Plasma::ConfigLoader to read config values in scripted effects
Advantage is that the default value is no longer needed and scripted
effects are anyway supposed to add a kconfigxt file.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0"> <tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">tested with the scripted login effect</pre> </td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> \
(updated)</h1> <ul style="margin-left: 3em; padding-left: 0;">
<li>kwin/CMakeLists.txt <span style="color: \
grey">(b5b0385035e182db166ead3ead754ab39e6ad763)</span></li>
<li>kwin/kcmkwin/kwincompositing/main.cpp <span style="color: \
grey">(e802b4624c6453d6ea4ec575a5e4e69346bad758)</span></li>
<li>kwin/kcmkwin/kwinscripts/module.cpp <span style="color: \
grey">(6327d24e42a7fdc1d97329bf024d8fb590cc424a)</span></li>
<li>kwin/main.cpp <span style="color: \
grey">(9f199638fc1293e2ad0ea7b70a850da2b73b25f1)</span></li>
<li>kwin/scripting/CMakeLists.txt <span style="color: \
grey">(PRE-CREATION)</span></li>
<li>kwin/scripting/Messages.sh <span style="color: grey">(PRE-CREATION)</span></li>
<li>kwin/scripting/genericscriptedconfig.h <span style="color: \
grey">(PRE-CREATION)</span></li>
<li>kwin/scripting/genericscriptedconfig.cpp <span style="color: \
grey">(PRE-CREATION)</span></li>
<li>kwin/scripting/scriptedeffect.h <span style="color: \
grey">(63eb66c9708e82a5b3d384a8e5a819578bcf3a25)</span></li>
<li>kwin/scripting/scriptedeffect.cpp <span style="color: \
grey">(83650f11dc68c7047900ac66ee30a8a83c9dc924)</span></li>
<li>kwin/scripts/Messages.sh <span style="color: grey">(PRE-CREATION)</span></li>
</ul>
<p><a href="http://git.reviewboard.kde.org/r/108975/diff/" style="margin-left: \
3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>
_______________________________________________
kwin mailing list
kwin@kde.org
https://mail.kde.org/mailman/listinfo/kwin
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic