Compact Brush Toggler

Some like to use this plugin, I am one of them, but it does not come with a guarantee of functionality. Try it out to see if it meets your needs, if you don’t like it, you can deactivate it, or delete it completely, as you like.
To delete it completely, you would have to go to ‘‘Settings’’ >> ‘‘Manage Resources …’’ >> ‘‘Open Resource Folder’’, to open Krita’s resource folder in explorer, then with explorer open, quit Krita, then in the ‘‘pykrita’’ folder, delete the whole subfolder ‘‘compactbrushtoggler’’ and the file ‘‘compactbrushtoggler.desktop’’. The next time Krita is started, it will no longer exist.

Let’s see what @kaichi1342 say’s.

Michelist

it’s usable, the only issue is that glitch of occasionally resetting the size or the opacity to last use. Which i found also happen to some other krita action / like a certain action in the pop up pallete also trigger that. [so that one is pretty deep in krita code, so a fix to that will need to be an MR.]

Other than that, i haven’t found any issue that can contribute to any other significant problem in using the plugin. I have use it since I made it. I kinda can’t see going back to time where i don’t have this.

A couple of other regular also uses it.

if you are on linux, i only tested it successfully on Linux Mint.

it also can be slow on some system, if you have a ram of atleast 16gb - its smooth and the penalty of its tree walking is kinda mitigated.

if the occasional resetting size / opacity is a big issue ; then i suggest to not use this.
if you can get over that ; then its good to go.

as an assurance - it has not cause a single crash in my laptop or my pc. :sweat_smile:

My suggestion is try it on some sketch work and see if the said issue will bother you.

honestly that brush suddenly resetting is still a bother. :disappointed:
i ran out of idea how to fix it in python side of thing.

I know that it can happen, and I’m okay with it.
Software these days is complex, Krita is an amalgamation of code developed from an at least for me unknown number of coders, and then you have to add all those who develop plugins, like you, and all that happened over decades if you look at the very beginning of Krita.
Okay, the name Krita is not that old, but that has other reasons.

For me, this is normal behavior, this is not a software with a multi-million-dollar background that allows to hone and “smoothen” the code by hordes of coders eliminating the hiccups, so I’m okay with it, with what I got. I’m loving Krita for this, I love to fiddle around and reach my goals, although it has all these little things where others complain about, Krita it has its own charm. So what!

Michelist

Yeah , I know the complexity.
What I mean is in programming side - it kinda bugs me that i run out of option of fixing it. It’s more of a I wish i can resolve it right now. :sweat_smile:

I can and have live with krita quirks and recently really been enjoying drawing with it - in my phone. It works real well as on the go sketchbook :3

1 Like

Any chance you can put, or could it be possible to put the mypaint brush size bar inside the compact brush toggler?
because I want to avoid using the topbar size changer due to this bug

1 Like

Hello - Sorry for the late reply. I noted this but i feel will bloat the existing one.
Though I thought of maybe making a separate plugin that contains sliders that are not [flow, opacity, size]

i’m personally thinking of adding fade to that, then this. Do you have any suggestion of what other brush engine slider that will be good to add to it?

Your call, I’d be happy with anything that helps with the bug, as long as you feel up to it.

1 Like

Well, apparently the plugin doesn’t work on linux.

i have it working on mint… but i have no success on other distro it tested to have it work on reasonable performance [its too slow]

In my case, it’s not that it’s slow, but that it simply doesn’t work, it seems that the buttons are disabled.

P.S: I’m on Fedora.

Ah that’s unfortunate. I still could not figure that out.

on my fedora (i run it out of vm though)

it looks like this.

Is there any other script you are running, if you can list them out. I’ll try to replicate them to see what exactly causing the problem.

1 Like

Sure, I’m just using Imagine Board, KanvasBuddy, Shortcut Composer, and Scratchpad.

1 Like

Is this software for Win 11 too?

It is a plugin for Krita, it works on Linux, macOS and also on Windows, including Windows 11, as far as I know.

Michelist

1 Like

This throws errors with 5.2 rc ? Any plans for updating it for 5.2?

thanks

Yeah when i have time for it. I have not downloaded the rc yet.
I will probably in weekend or two - i usually do plugin stuff on my dayoff. :face_holding_back_tears:

thank you for reporting.

2 Likes

Good evening, i’ve downloade rc2 and can’t seem to trigger an error. I’m having a different issue separate from the plugin.

can you send a screen shot/ video recording of the issue and system specification and OS info?

1 Like

Hi, just like the tittle says, after I upgraded the latest version of Krita Compact brush toggler stopped working, I’m using PopOS, and I was starting to get used to Krita and suddenly this happened.

For me being able to toggle on and off opacity, size and other features is a big part of my workflow that I miss a lot on Krita so I’d appreciate if you can help to fix this.

This is the error I get:

AttributeError
Python 3.11.5: /usr/bin/python3
Tue Oct 17 15:31:03 2023

A problem occurred in a Python script. Here is the sequence of
function calls leading up to the error, in the order they occurred.

/home/“my user”/.var/app/org.kde.krita/data/krita/pykrita/compactbrushtoggler/compactbrushtoggler.py in loadBrushInfo(self=<compactbrushtoggler.compactbrushtoggler.CompactBrushToggler object>)
259 if(cur_brush.name() != self.last_brush):
260 self.last_brush = cur_brush.name()
261 self.loadState()
262
263
self = <compactbrushtoggler.compactbrushtoggler.CompactBrushToggler object>
self.loadState = <bound method CompactBrushToggler.loadState of <…compactbrushtoggler.CompactBrushToggler object>>

/home/“my user”/.var/app/org.kde.krita/data/krita/pykrita/compactbrushtoggler/compactbrushtoggler.py in loadState(self=<compactbrushtoggler.compactbrushtoggler.CompactBrushToggler object>)
610 def loadState(self):
611 editor = self.get_brush_editor()
612 option_widget_container = editor.findChild(QWidget, ‘frmOptionWidgetContainer’)
613
614
option_widget_container undefined
editor = None
editor.findChild undefined
global QWidget = <class ‘PyQt5.QtWidgets.QWidget’>
AttributeError: ‘NoneType’ object has no attribute ‘findChild’
cause = None
class = <class ‘AttributeError’>
context = None
delattr = <method-wrapper ‘delattr’ of AttributeError object>
dict = {}
dir =
doc = ‘Attribute not found.’
eq = <method-wrapper ‘eq’ of AttributeError object>
format =
ge = <method-wrapper ‘ge’ of AttributeError object>
getattribute = <method-wrapper ‘getattribute’ of AttributeError object>
getstate =
gt = <method-wrapper ‘gt’ of AttributeError object>
hash = <method-wrapper ‘hash’ of AttributeError object>
init = <method-wrapper ‘init’ of AttributeError object>
init_subclass =
le = <method-wrapper ‘le’ of AttributeError object>
lt = <method-wrapper ‘lt’ of AttributeError object>
ne = <method-wrapper ‘ne’ of AttributeError object>
new =
reduce =
reduce_ex =
repr = <method-wrapper ‘repr’ of AttributeError object>
setattr = <method-wrapper ‘setattr’ of AttributeError object>
setstate =
sizeof =
str = <method-wrapper ‘str’ of AttributeError object>
subclasshook =
suppress_context = False
traceback =
add_note =
args = (“‘NoneType’ object has no attribute ‘findChild’”,)
name = ‘findChild’
obj = None
with_traceback =

The above is a description of an error in a Python program. Here is
the original traceback:

Traceback (most recent call last):
File “/home/“my user”/.var/app/org.kde.krita/data/krita/pykrita/compactbrushtoggler/compactbrushtoggler.py”, line 261, in loadBrushInfo
self.loadState()
File “/home/“mu user”/.var/app/org.kde.krita/data/krita/pykrita/compactbrushtoggler/compactbrushtoggler.py”, line 612, in loadState
option_widget_container = editor.findChild(QWidget, ‘frmOptionWidgetContainer’)
^^^^^^^^^^^^^^^^
AttributeError: ‘NoneType’ object has no attribute ‘findChild’

1 Like

:slight_smile: Hello @xkaly, and welcome back to the forum!

It would have been better to post your bug-report in the topic of the Compact brush toggler plugin, or at least to ping @kaichi1342, so @kaichi1342 will be informed about this issue.

@AhabGreybeard; @raghukamath; @sooz: Could you please merge this topic with the topic of this plugin?

Michelist

2 Likes