[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-panel-devel
Subject:    Re: Review Request 125817: Add plugin system for Calendar events
From:       "Marco Martin" <notmart () gmail ! com>
Date:       2015-10-28 17:03:28
Message-ID: 20151028170328.14097.5788 () mimi ! kde ! org
[Download RAW message or body]

--===============0110563328086791851==
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit



> On Oct. 28, 2015, 9:15 a.m., Marco Martin wrote:
> > not much a fan of adding a public library there, but i guess there aren't many \
> > other ways. Could it be put into plasma-workspace instead?
> 
> Daniel Vrátil wrote:
> Please don't, unless you want to have Akonadi dependency in plasma-workspace. This \
> way we in KDE PIM can provide our own plugin, because having a dependency on \
> plasma-framework is not a big problem for us (unlike having a PIM dependency in \
> plasma-workspace I imagine). 
> Luca Beltrame wrote:
> +1 to what Dan said. As a contributor and a packager: plase *don't* have things \
> depend on workspace. It was a mess already in 4.x times, and caused all sorts of \
> headaches down the way. 
> Marco Martin wrote:
> the idea was that akonadi plugin would have resided in workspace as well (i think \
> an akonadi dependency in plasma-workspace is fine, like an akonadi-integration \
> under workspace/) If that can't be done, ok for adding it in plasma-framework(i \
> would already prefer a separed framework on its own tough), I'm just very very \
> stingy in adding new and forever frozen symbols, especially frozen since its first \
> release 
> Daniel Vrátil wrote:
> Note that we don't have any PIM frameworks yet, so you would create Plasma -> \
> Applications dependency. At this point it's easier for PIM team to maintain PIM \
> integration stuff in PIM repositories. 
> Since the only two users at the beginning will be the Holiday plugin and PIM, I \
> think that marking the library as "experimental" without and ABI/API guarantees is \
> perfectly fine for the first X releases, and once we see that it works well for \
> both, it can be moved to "stable". 
> Martin Gräßlin wrote:
> Overall that sounds like we need a weird repo somewhere in between which can depend \
> on both the workspace and the applications. 
> I totally see Marco's point of it's not optimal to have a new always frozen lib in \
> Plasma Frameworks and I also see that it's a no-go to have Workspace depend on Apps \
> and also Apps depend on Workspace. We have three possible ways and all are kind of \
> broken ;-) Interesting things can happen. 
> Martin Klapetek wrote:
> I wasn't sure where to put it, but unless we put it in its own repo, \
> plasma-framework seems like the best-of-the-bad place, so I went with that.

exactly what will depend from it? -workspace and -applications ?


- Marco


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/125817/#review87564
-----------------------------------------------------------


On Oct. 27, 2015, 9:10 p.m., Martin Klapetek wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/125817/
> -----------------------------------------------------------
> 
> (Updated Oct. 27, 2015, 9:10 p.m.)
> 
> 
> Review request for Plasma and Daniel Vrátil.
> 
> 
> Repository: plasma-framework
> 
> 
> Description
> -------
> 
> This adds a simple plugin interface that can be subclassed
> and provide events integration with Plasma Calendar applet.
> 
> It's asynchronous and I've kept it deliberately simple.
> For now the Calendar tells the plugins which date range
> is being displayed, the plugins load the data and then
> emit the dataReady() signal containing the events.
> 
> The events are stored in a multihash for quick access
> by the Calendar's agenda part but also for overall
> easy-to-use (eg. in teh model data()).
> 
> The event data is stored in EventData class, which has
> a pretty self-explanatory members, except perhaps the
> "isMinor" one. The intention with this is to support
> namedays, where in some countries the calendars have
> different name every day. This is just a minor holiday
> and as such should not mark the calendar grid, otherwise
> the whole grid would be in a different color.
> 
> Putting the interface here might raise the question of
> depending on plasma-framework, but plugins provided by
> KDE can go to plasma-workspace and other 3rd party ones
> would just have to live with it. I don't think it will
> be a problem but if it turns out it is, we can rethink
> the placement.
> 
> 
> Diffs
> -----
> 
> src/declarativeimports/calendar/CMakeLists.txt 40ead91 
> src/declarativeimports/calendar/calendarplugin.cpp bafe80c 
> src/declarativeimports/calendar/daysmodel.h a5bdac9 
> src/declarativeimports/calendar/daysmodel.cpp 2d059a8 
> src/declarativeimports/calendar/eventdatadecorator.h PRE-CREATION 
> src/declarativeimports/calendar/eventdatadecorator.cpp PRE-CREATION 
> src/declarativeimports/calendar/plasmacalendarintegration/CMakeLists.txt \
> PRE-CREATION  src/declarativeimports/calendar/plasmacalendarintegration/PlasmaCalendarIntegrationConfig.cmake.in \
> PRE-CREATION  src/declarativeimports/calendar/plasmacalendarintegration/calendareventsplugin.h \
> PRE-CREATION  src/declarativeimports/calendar/plasmacalendarintegration/calendareventsplugin.cpp \
> PRE-CREATION  
> Diff: https://git.reviewboard.kde.org/r/125817/diff/
> 
> 
> Testing
> -------
> 
> I have a simple KHolidays based plugin written (patch should be up later today)
> and patches in the Calendar applet.
> 
> Everything works as expected:
> * the days are marked as containing an event
> * the agenda part displays details of that event (name)
> 
> 
> Thanks,
> 
> Martin Klapetek
> 
> 


--===============0110563328086791851==
MIME-Version: 1.0
Content-Type: text/html; charset="utf-8"
Content-Transfer-Encoding: 8bit




<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="12" style="border: 1px #c9c399 \
solid; border-radius: 6px; -moz-border-radius: 6px; -webkit-border-radius: 6px;">  \
<tr>  <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="https://git.reviewboard.kde.org/r/125817/">https://git.reviewboard.kde.org/r/125817/</a>
  </td>
    </tr>
   </table>
   <br />





<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <p style="margin-top: 0;">On October 28th, 2015, 9:15 a.m. UTC, <b>Marco \
Martin</b> wrote:</p>  <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;">  <pre style="white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;"><p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">not much a fan of adding a public library there, but i \
guess there aren't many other ways. Could it be put into plasma-workspace \
instead?</p></pre>  </blockquote>




 <p>On October 28th, 2015, 9:43 a.m. UTC, <b>Daniel Vrátil</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
inherit;">Please don't, unless you want to have Akonadi dependency in \
plasma-workspace. This way we in KDE PIM can provide our own plugin, because having a \
dependency on plasma-framework is not a big problem for us (unlike having a PIM \
dependency in plasma-workspace I imagine).</p></pre>  </blockquote>





 <p>On October 28th, 2015, 9:57 a.m. UTC, <b>Luca Beltrame</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">+1 to \
what Dan said. As a contributor and a packager: plase <em style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
normal;">don't</em> have things depend on workspace. It was a mess already in 4.x \
times, and caused all sorts of headaches down the way.</p></pre>  </blockquote>





 <p>On October 28th, 2015, 11:04 a.m. UTC, <b>Marco Martin</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">the \
idea was that akonadi plugin would have resided in workspace as well (i think an \
akonadi dependency in plasma-workspace is fine, like an akonadi-integration under \
workspace/) If that can't be done, ok for adding it in plasma-framework(i would \
already prefer a separed framework on its own tough), I'm just very very stingy in \
adding new and forever frozen symbols, especially frozen since its first \
release</p></pre>  </blockquote>





 <p>On October 28th, 2015, 11:11 a.m. UTC, <b>Daniel Vrátil</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">Note \
that we don't have any PIM frameworks yet, so you would create Plasma -&gt; \
Applications dependency. At this point it's easier for PIM team to maintain PIM \
integration stuff in PIM repositories.</p> <p style="padding: 0;text-rendering: \
inherit;margin: 0;line-height: inherit;white-space: inherit;">Since the only two \
users at the beginning will be the Holiday plugin and PIM, I think that marking the \
library as "experimental" without and ABI/API guarantees is perfectly fine for the \
first X releases, and once we see that it works well for both, it can be moved to \
"stable".</p></pre>  </blockquote>





 <p>On October 28th, 2015, 11:58 a.m. UTC, <b>Martin Gräßlin</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
inherit;">Overall that sounds like we need a weird repo somewhere in between which \
can depend on both the workspace and the applications.</p> <p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">I \
totally see Marco's point of it's not optimal to have a new always frozen lib in \
Plasma Frameworks and I also see that it's a no-go to have Workspace depend on Apps \
and also Apps depend on Workspace. We have three possible ways and all are kind of \
broken ;-) Interesting things can happen.</p></pre>  </blockquote>





 <p>On October 28th, 2015, 1:44 p.m. UTC, <b>Martin Klapetek</b> wrote:</p>
 <blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;">  <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">I \
wasn't sure where to put it, but unless we put it in its own repo, plasma-framework \
seems like the best-of-the-bad place, so I went with that.</p></pre>  </blockquote>








</blockquote>

<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: \
0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: \
inherit;">exactly what will depend from it? -workspace and -applications ?</p></pre> \
<br />










<p>- Marco</p>


<br />
<p>On October 27th, 2015, 9:10 p.m. UTC, Martin Klapetek wrote:</p>








<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="12" style="border: \
1px #888a85 solid; border-radius: 6px; -moz-border-radius: 6px; \
-webkit-border-radius: 6px;">  <tr>
  <td>

<div>Review request for Plasma and Daniel Vrátil.</div>
<div>By Martin Klapetek.</div>


<p style="color: grey;"><i>Updated Oct. 27, 2015, 9:10 p.m.</i></p>









<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt;">Repository: </b>
plasma-framework
</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </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;"><p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">This adds a simple plugin interface that can be \
subclassed and provide events integration with Plasma Calendar applet.</p>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">It's asynchronous and I've kept it deliberately \
simple. For now the Calendar tells the plugins which date range
is being displayed, the plugins load the data and then
emit the dataReady() signal containing the events.</p>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">The events are stored in a multihash for quick access \
by the Calendar's agenda part but also for overall easy-to-use (eg. in teh model \
data()).</p> <p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">The event data is stored in EventData class, which has \
a pretty self-explanatory members, except perhaps the "isMinor" one. The intention \
with this is to support namedays, where in some countries the calendars have
different name every day. This is just a minor holiday
and as such should not mark the calendar grid, otherwise
the whole grid would be in a different color.</p>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: \
inherit;white-space: inherit;">Putting the interface here might raise the question of \
depending on plasma-framework, but plugins provided by KDE can go to plasma-workspace \
and other 3rd party ones would just have to live with it. I don't think it will
be a problem but if it turns out it is, we can rethink
the placement.</p></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;">I have a simple KHolidays based plugin written (patch should be up later \
today) and patches in the Calendar applet.

Everything works as expected:
* the days are marked as containing an event
* the agenda part displays details of that event (name)</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>src/declarativeimports/calendar/CMakeLists.txt <span style="color: \
grey">(40ead91)</span></li>

 <li>src/declarativeimports/calendar/calendarplugin.cpp <span style="color: \
grey">(bafe80c)</span></li>

 <li>src/declarativeimports/calendar/daysmodel.h <span style="color: \
grey">(a5bdac9)</span></li>

 <li>src/declarativeimports/calendar/daysmodel.cpp <span style="color: \
grey">(2d059a8)</span></li>

 <li>src/declarativeimports/calendar/eventdatadecorator.h <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>src/declarativeimports/calendar/eventdatadecorator.cpp <span style="color: \
grey">(PRE-CREATION)</span></li>

 <li>src/declarativeimports/calendar/plasmacalendarintegration/CMakeLists.txt <span \
style="color: grey">(PRE-CREATION)</span></li>

 <li>src/declarativeimports/calendar/plasmacalendarintegration/PlasmaCalendarIntegrationConfig.cmake.in \
<span style="color: grey">(PRE-CREATION)</span></li>

 <li>src/declarativeimports/calendar/plasmacalendarintegration/calendareventsplugin.h \
<span style="color: grey">(PRE-CREATION)</span></li>

 <li>src/declarativeimports/calendar/plasmacalendarintegration/calendareventsplugin.cpp \
<span style="color: grey">(PRE-CREATION)</span></li>

</ul>

<p><a href="https://git.reviewboard.kde.org/r/125817/diff/" style="margin-left: \
3em;">View Diff</a></p>






  </td>
 </tr>
</table>







  </div>
 </body>
</html>


--===============0110563328086791851==--


[Attachment #3 (text/plain)]

_______________________________________________
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic