<div class="gmail_quote">On Fri, Sep 4, 2009 at 10:31 PM, Dmitry Kazakov <span dir="ltr"><<a href="mailto:dimula73@gmail.com">dimula73@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi again, All!<br><br>There are some more troubles. This time they are with effect masks.<br><br>The problem is: we simply CAN'T add any selection with a selection<br>tool or paint something with a freehand tool on ANY MASK.<br>
</blockquote><div><br>Can you explain what you expect? When I select something on a transparency mask e.g with retangular selection I can paint inside the selection with the normal brush.<br>I don't see the problem.<br>
<br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">The reason is we use explicit conversion of the node to KisLayer* type<br>in these tools.<br>
<br>kis_tool_freehand.cc:282<br><br> if (!m_paintIncremental) {<br><br> KisIndirectPaintingSupport* layer;<br> if ((layer = dynamic_cast<KisIndirectPaintingSupport*>(currentNode().data()))) {<br>
// Hack for the painting of single-layered layers using indirect painting,<br> // because the group layer would not have a correctly synched cache (<br> // because of an optimization that would happen, having this layer as<br>
// projection).<br> KisLayerSP l = layer->layer();<br>...<br><br>kis_selection_tool_helper.h:33<br><br>class KRITAUI_EXPORT KisSelectionToolHelper<br>{<br>public:<br><br>...<br><br>private:<br> KisCanvas2* m_canvas;<br>
KisImageSP m_image;<br> KisLayerSP m_layer;<br> QString m_name;<br>};<br><br><br>I don't see any clear solution for this. And more than that, I'm afraid some <br>other tools can use the same conversion inside themselves.<br>
<br>The only solution i see is to derieve filter masks from<br>KisIndirectPaintingSupport and make some workaround with layer()<br>method...<br>Don't know really...<br><br>Do you have any ideas?<br clear="all"><br>-- <br>
<font color="#888888">
Dmitry Kazakov<br>
</font><br>_______________________________________________<br>
kimageshop mailing list<br>
<a href="mailto:kimageshop@kde.org">kimageshop@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/kimageshop" target="_blank">https://mail.kde.org/mailman/listinfo/kimageshop</a><br>
<br></blockquote></div><br>