KisViewPlugin design problem

Cyrille Berger cberger at cberger.net
Thu May 7 19:07:58 UTC 2015


Hi,

While working on the python plugin, I realized that we had a problem with the 
view plugins, when you open a new window, they don't show their actions in the 
new window, I reported it as https://bugs.kde.org/show_bug.cgi?id=347332 , and 
thinking I could be lazy and let someone else to figure out how to solve it. 
But thinking about it, I realized that I would need a proper fix for the python 
plugin...

So I have been thinking about solutions for the problem.

Since most KisViewPlugin implementations are tightly bound to a single 
KisViewManager. The easiest would be to have the view plugins be a 
KisViewPluginFactory that creates a KisViewPlugin. And every time we create a 
new window, we can use the KisViewPluginFactory to create a KisViewPlugin 
instance.

Since the name KisViewPlugin would be a bit inadequate, I would also suggest 
to rename it to KisViewExtension(Factory), but that might a bit of a too big 
change to do with the transition to Qt/KF5.

What do you think?

-- 
Cyrille Berger Skott


More information about the kimageshop mailing list