For my GSoC project I've been working on the rule toggle so I created a setting that bans a rule for the whole image.��

But I'm thinking that some of you might want to disable a certain rule for all the following images too.

Hence my question: how to save a setting programatically so that the same setting would immediately work for the next image as well?

For now I only know how to do it manually but I need a more elegant way to do this:
Inline images 2

Any help or advice would be much appreciated.

Regards,
Myroslava.