Feature request for dedicated Eraser Tool

This is a bit of a tangent but a behavior that could potentially improve the workflow for me: If the eraser mode is meaningless in the context of the current tool (transform tool for example) then pressing the eraser preset shortcut (say Shift+C) would switch you to the freehand brush tool automatically. Currently you have to press B, then Shift+C for it to work.

Bullseye. Imagine “eraser mode” or “eraser preset brush” is another tool, then just press it and you get what you want. switching is much simpler and clearer. It’s all down to it being a “mode” or “preset”, and not a tool. They are different switching logic.

No.

What I’d like is:

  1. Activate the Eraser brush (tag) with a dedicated hotkey
  2. Decouple eraser mode for erasers invoked with the hotkey, if I need eraser mode, I would only use it for brushes. Decoupling from eraser mode allows me to change the current tool to the brush tool. I don’t want the eraser hotkey to affect any other tools (e.g. rectangle tool).
  3. A dedicated brush history, so I can recall an eraser with a hotkey and a brush with another
  4. If I change to an eraser brush or a paint brush from the brush docker, this should not affect the brush history in the eraser or paint stack respectively (e.g. don’t remember erasers in the brush history and don’t remember paint brushes in the eraser brush history).

Any method that does less than the above 4 makes it harder to toggle a paint brush or eraser brush by hotkey.

2 Likes

I only really need 1 thing that i realize.

To be able to jump straight to eraser from other tool.

Right now to go there its;

  • press B → press E (if the brush is not in eraser mode) or
  • press B (if the brush is already in eraser mode/ or eraser mode is activated) or
  • press B → select Eraser brush

Sometimes your just in [for example] selection , or guides , or fill tool and you notice something you wanna erase jumping straight to erase without going to brush is convenient.


This is what I thought while thinking how to do that ;
Some sort of steps.

Pressing Eraser Tool Shortcut should execute the following;

1.a Switch to brush immediately [if there is no dedicated eraser yet]

2.a No Eraser Preset List

  • Ensure the brush preset is in eraser mode;

2.b if With Eraser Preset List

  • Switch to last active eraser preset
  • Ensure the last active eraser preset is in eraser mode;
  1. Erase.

  2. Going back to other tools , last previous mode should be back.

That’s pretty much it to mine.


I tried code a quick extension with the jump to (brush + erase mode) to a hot key, to see if that fits what i want. Just to find out erase_action is a toggle lol. TBH its close to what I need - just need to make sure its in eraser. :sweat_smile:

3 Likes

The ‘Toggle Eraser Preset’ does just that, apart from switching to the brush tool. If it could do that, it would be close to what most people want, I think.

1 Like

I think that first part is really the crucial 1 and essentially what makes it kinda like a tool.
When a tool is invoke you switch to it immediately no matter what you are using.
If an action can be provided for it. I think that’s about what half of us need.

1 Like

After trying out the new “Toggle Eraser Preset”, I feel like it’s missing one key change to make it work the way people here want it to work.

Right now all it does is toggle between presets, be it set in eraser mode or paint mode and without its own icon on the toolbar there’s no feedback whether you’re actually using the “Eraser Preset” or not. For example you could use preset A as your paint brush and for “Eraser Preset” also set preset A and don’t toggle erase mode for it, toggling between 2 slots will work but neither will be an “eraser” and you’ll lose track which is which (unless you set “Toggle Eraser Preset” icon on toolbar, which is currently same as “Set eraser mode” one so that may also be an issue).

To address this issue, one way would be to force “Set erase mode” to “Toggle Eraser Preset” so that when you toggle to “Eraser Preset” it always forces erase mode and doesn’t allow turning it off. Similarly toggling the “Eraser Preset” off could ensure the erase mode is off whenever you toggle back to normal preset from “Eraser Preset” but still allow manually setting erase mode if you wish so.

I wonder if anyone working on this feature is aware of the plugin Threeslots which does almost exactly what I described but being a plugin it’s not accessible to everyone.
This plugin allows setting three different presets to a shortcut similarly to Ten Brushes but also ensures the “Eraser Preset” is always in erase mode and the two “Brush Presets” are always in paint mode. Another great feature of the plugin is that it “remembers” preset size and opacity.
The only thing I didn’t like about the plugin is the forcing erase mode off for the two “Brush Presets” not allowing for a quick erase mode toggle if I wish to use same preset I’m painting with without making changes to actual “Eraser Preset”. I’ve modified the last bit of the plugin code to trigger only if current_idx == 0 and that seems to work although I’m unsure if that’s the correct way to fix it. It allows me to still toggle erase mode for the two brush presets and forces erase mode for the “Eraser Preset” but manually changing one of the two brush slots to the preset that’s currently set in for eraser preset won’t trigger erase mode off until slot change happens (can still be manually turned off or simply swap between slots).

Adding the functionality of the Threeslots plugin’s “Eraser preset” to the “Toggle Eraser Preset” could potentially make both sides happy. There would be a dedicated Eraser Preset and we would still keep the Krita’s erase mode toggle functionality.

1 Like

After so many years of using Krita, I still hope this feature is made official. My ideal solution is like CSP: you can have any number of groups, each group with a shortcut, and it remembers which group you are at, and which brush is/was selected for each group. The last sentence is why it’s a better design than Photoshop’s and Krita’s default system.

Threeslot is quite similar to this, but without UI feedback telling you which slot you are using.

It’s such an elegent solution that I can’t believe it’s not more well adopted. I highly suggest every checks out how CSP manages this problem.

4 Likes

I just read the first 70 or so posts and the last 20-ish so i missed a couple of hundred in the middle. Also I know nothing of programming and don’t understand half the nuances of brush history or toggle presets etc… But…

  1. I would not change how Kritas E shortcut works for anything. Took a little time finding it (and other tools, like stamp etc) at first but I really do love it now that I’m used to it and know how to find it. For most part I love how the eraser and the brush behave the same. Only time it’s frustrating is if I do lineart with a tiny brush and need to erase.

  2. Is there a way - without a plugin - to assign a shortcut to a specific brush?
    So I could configure Krita to bring me one of the eraser brushes with pressing a key, instead of picking it by clicking on the icon for the eraser brush.

If not, or if that’s just possible with a plugin (I don’t understand how the three brushes work, and I generally don’t love plugins… I always mess things up when trying to install such stuff) that function could be neat. But I’m just a hobby painter and I work around it by making sure both the eraser brush and sketching brush are tagged in the brush box thingy so they’re within reach. A short key to a specific, large eraser brush would be nice but not important to me enough that I’d do too much work to get it (like messing with plugins or wrapping my head around all this ‘previously used brush history’ stuff… I’m too ignorant in the linguistics to understand what half of the discussion talks about)

2 Likes

@Zabbio

Is there a way - without a plugin - to assign a shortcut to a specific brush?

There is a new icon you can add to one of your toolbars. Once you select the eraser icon and then select an eraser preset, it will remember which eraser preset you last chose (whereas E simply changes your current preset to eraser blend mode).

It’s called “toggle eraser preset”

3 Likes

Oh, that sounds great. I’ll have to search the term to see how to set it up.

I think @tiar is taking a look about how much work an implementation of this will need…

According to the number of plugins trying to provide workarounds to the current Krita’s eraser implementation and how hot this topic is, I’ve the feeling whatever the solution that could be implemented, the result will be the same: user will complain that is not exactly how Photoshop works or CSP is better, or this, or that… :person_shrugging:

I whish good luck to her :muscle:

Grum999

2 Likes

I haven’t used it personally, but there’s also a plugin TenBrushes, you can find it in the menu in Scripts (sorry, I’m AFK right now and can’t look it up where exactly it is).

If I’m not mistaken, this plugin lets you assign 10 brushes to hotkeys. The hotkeys themselves can be changed in the settings, where all Krita keys are defined.

2 Likes

10 Brushes has to be activated in Krita via ‘‘Settings’’ >> ‘‘Configure Krita’’ >> ‘‘Python Plugin Manager’’, there scroll down to its entry and set the checkmark in front of it.

There also exists an extended version of the Ten Brushes plugin, “Twenty Brushes”.
TwentyBrushes on hotkeys

I don’t want to skim through this topic again, but I think @Grum999’s Buli Brush Switch belongs to the Plugins aiming to help here, but it offers much more functions, is a versatile tool.
Buli Brush Switch

Also @EyeOdin’s Eraser Shift plugin seem to aim at the same target.

As well as @Daishishi’s [Proof of Concept] Plugin as Eraser Tool (PET).

The next candidate, JoannesJ’s “Krita Direct Eraser” unfortunately the old KDE-Forum is taken down or was moved to an unknown location, but you can get it from my cloud including copies of the forum pages where it was presented:

Another versatile plugin, what should be of use here is @Lucifer’s Ten Brush Slots I guess.
Ten Brush Slots

And then there are very probably also all those private solutions unknown to me or this forum…

Michelist

3 Likes

Because Clip Studio Paint’s solution seems to be a popular one, I’ll try to explain how exactly “Sub Tools” work there in hopes it’ll help developers better understand what Krita is currently missing to achieve what people want.

In CSP, unlike in Krita, “Freehand Brush Tool” is split into different categories such as Pen, Eraser, Brush, Airbrush, Pencil, etc… which are exact same tool just each category has its own shortcut. While in Krita we have one shortcut for Freehand Brush Tool, be it eraser or any other paint brush.

As CSP has these different categories of freehand tool it also allows user to set custom Icon per “Sub Tool” (preset in Krita). Sub Tools are simply presets that can be grouped into a Sub Tool Group that is then called by any chosen “category” shortcut. (You can also have a paint brush sub tool group on “Eraser” tool shortcut if you desire so)

Just like in Krita, the CSP’s “Eraser” Sub Tool (preset) is simply a drawing preset that uses “Erase” brush blending mode, but you can set Icon to eraser, or any available tool Icon.

The Output process here is a tool (like Gradient, Eyedropper, Move, Select, etc) where “Direct draw” is a Freehand Brush. The Input process is a sub category of each “Output process”, here Direct draw can be “Input” as Brush, Pen, Eraser, Fill, Figure (circle, rectangle), etc. where both Brush and Eraser are same, just Eraser sets Blending mode to Erase while Brush sets it to Normal by default. (But can be changed at any time)

Also just like in Krita, CSP too has the ability to toggle between paint and transparency (Erase mode toggle in Krita), where you simply paint with transparency, and any sub tool can toggle that. The difference here being that Krita stores this per preset while CSP has a global toggle. Per preset is better imo.

This exact same categorization can already be achieved in Krita with the use of Shortcut Composer. Where you can group all “Eraser” presets that use blending mode “Erase” onto one Pie Menu (shortcut), all “Pencils” onto another Pie (shortcut), all “Basic” paint brushes onto next and so on.

Examples
Krita with Shortcut Composer Pie Menus:

CSP Sub Tool menu:


Both approaches are very similar but Pie Menus being a plugin aren’t accessible to everyone.

If Krita wanted to offer similar experience natively, first step would be to allow user to set custom Icon per preset (Eraser, Brush, Airbrush, Blend etc) which would be set in brush editor and for feedback shown in place of Freehand Brush Tool slot. Then next step would be a native approach to preset groups (either by tag or manual) on more than one shortcut. (Similar to how Shortcut Composer Pie Menus work)

I hope this wasn’t too long to read, and don’t get me wrong, I’m not in any way trying to say that CSP is better than Krita as I natively use Krita. CSP simply does this categorization more naturally as it allows user to have these sub “toolboxes” to sort their presets (you need an eraser you hit one shortcut, you need a brush you hit another, you need a blender you hit another and each “toolbox” remembers last preset you picked from it).

7 Likes

Thank you very much. I did try to promote CSP’s solution but I couldn’t explain it clearly as you did.

By the way adopting this approach doesn’t mean we have to abandon the current ‘E’'s function.

CSP subtool = a system to manage and select brushes
Krita ‘E’ = a shortcut to set the selected brush’s blend mode to Eraser.

They are completely orthogonal.

2 Likes

As I have mentioned in the post above, CSP has both too, you can set a shortcut to E for “Switch drawing color and transparent color” which will do exactly what Krita’s Eraser toggle does, just globally instead of per preset.

Having both a dedicated shortcut for eraser preset group and a per preset toggle is a good thing. This allows you to temporary turn a painting brush into an eraser for specific situations where you may want to quickly erase with same brush you’re painting with without changing your current eraser in eraser shortcut.

Edit:
Even Photoshop has both, pressing a shortcut any brush in use can toggle to paint with transparency. I guess people there wanted what Krita and CSP had :stuck_out_tongue:

1 Like

If I interpret what you say correctly, in CSP you have subcategories, like

,

and

Than I see no difference in the current implementation of the presets krita already has.

You can choose in the brush-preset your favorite brush to draw with, then switch to the eraser-preset and select your favorite eraser and erase.

The selection of the eraser or brush is exactly the same.

CSP has 5 presets or so, while krita has 2. Ok I’ll take 3 more then.

But kritas presets are more powerful, as you don’t have to be restricted to the brush tool. You can select a selection tool for the eraser-preset and switch between brush and selection :exploding_head:

So I still see no need to implement an extra tool for the eraser.

Maybe the pop-up palette could also reference an other tag, when in eraser-preset, but that would be an other request. :thinking:

So what I extract from this whole discussion is, that more presets would be nice and that each preset should be configurable to tags and not to the whole range of tools… :face_with_raised_eyebrow:

As I have explained yes both are the same in what an Eraser preset is. Simply a preset that uses Erase blending mode, same as Krita.

The only difference is that Krita’s eraser preset is still a “Freehand Brush” while CSP can have it use an Eraser icon, which shows up in toolbox and appears to be a “dedicated eraser tool”.

Exactly this, if all people want is what CSP does then all that’s missing is ability to change Tool Icon per preset. If Freehand Brush Tool’s icon could change depending on what preset Icon is set to that alone would give an illusion of a different tool. (exactly what CSP does).

CSP has 7 shortcuts that are all “Freehand brush tool” in disguise, just each has different Icon by default. (Again as I said you can have any Icon on any shortcut, you can have same preset on any shortcut, 7 Erasers? sure, 7 erasers with different Tool icons too)
Krita’s “eraser preset” shortcut gives no feedback and if you happen to turn erase mode on for both you’ve no idea which is which slot anymore.

This is not necessarily true as both are very equal in what you can do with presets. You can erase with selection, fill tool or whatever in CSP too. (I mean you can create a sub tool that draws a ruler (assistant) using a freehand selection…) Even brush engine is fairly equal, things are just at different places.

This alone would be a good start. Remember tag for slot in use (Eraser shortcut or Brush shortcut). As currently with Krita’s approach, you always choose preset from a single tag group. If you have erasers in one tag and paint brushes in another you have to change tag each time you’re choosing new preset for each “tool”. In CSP each of those 7 shortcuts can have any number of preset groups (tags) (tabs in sub tool menu) and any number of presets within each group (tag).

In short, personally I’m more than happy with Pie Menus from Shortcut Composer as this allows exactly that, extra shortcuts for Freehand Brush where each can have its own group of presets to choose from. (Erasing with one, Painting with another and smudging with a 3rd preset using 3 shortcuts)
But that’s a plugin and not what Krita allows natively.

There seems to be an misunderstanding on what CSP’s implementation exactly is and what the “Sub Tools” actually are so I simply shared personal experience. Although CSP has an unlimited free trial and anyone can test and see what exactly is going on there and what people are trying to achieve here in Krita.

3 Likes

I put the “toggle eraser preset” in my toolbar now, and assigned it a hot key.
It does exactly what I want; pressing the key gives me an eraser of the right size regardless of what brush I have, pressing again get my brush back. A new icon tells me if it’s engaged (just like the E icon but in a different spot) and I could click that icon instead of a short key.

While E still sets to eraser mode on the brush Im using like it always did.

So… Now I don’t know what exactly others are still lacking. But I’m happy. :slight_smile:

2 Likes