[calligra] krita: save mirror, erase, composite op and mirror settings to presets

Silvio Heinrich plassy at web.de
Sun May 29 18:33:27 CEST 2011


On 05/29/2011 08:08 AM, Cyrille Berger Skott wrote:
> I do agree with Silvio that is confusing for users. However, lets work on
> suggestion for improvement :)
>
> What I am thinking is that the opacity and composite ops mode should be also
> visible in the editor. And then the toolbar should be perceived for users as
> shortcut to access the most common brush options (ie scale, opacity, composite
> op).
>
> And I do think that if we do like this it should work nicely for users.
>
> As for the broken presets, I suggest opening a bug report with an attached
> presets.

Ok, this sounds like the best idea to me :)
Lets resume what we want:

1. Saving blending mode, texture and  gradient to a preset
2. Making the controls in the toolbar to shortcuts of the options in the 
preset editor
3. Make it possible to show a dynamic brush outline while the pen is 
hovering over the tablet


Now a few suggestions.
1. That would involve creating a few new paintOpOptions... that is GUI 
stuff.

2. I think we need to enhance the KisPaintOpSettings interface a bit.
We should be able to ask if common paintOpOptions are present.
Like if the preset really has a opacity option and what value it has 
(not the dynamic value since we get this only while painting).
We could an use it like:
if(setting->hasOption("opacity"))
     setting->getValue<qreal>("opacity");

Then when a preset is changed we ask for this standard options.
For example if the preset has no opacity option we would just disable 
the opacity slider in the toolbar.

3. Right now the paintOp needed for doing the actual painting is created 
in the moment
the user clicks on the canvas in the KisPainter::setPaintOpPreset(...) 
method.
I would like to create the PaintOp outside the tools just after the user 
loads different preset.
Then this paintOp is passed to the current Tool and the tool will pass 
it to the painter.
Then we could add a virtual method to the KisPaintOp interface, maybe:

// returns false if no if the paintOp doesn't create a brush outline
virtual bool calculateBrushOutline(QPainterPath& resultingPath, const 
KisPaintInformation& info);

Since the paintOp would be around all the time (not only while painting) 
we can have a dynamic brush
outline even while hovering.
The only thing I don't know right now is where we should store the 
paintOp (since it isn't created on demand anymore).
Maybe in the document? or in the canvas?




More information about the kimageshop mailing list