On Wednesday 23 April 2008, Richter Huang wrote:
> Hi,
>
> I wrote a python-fu script for my private use that may enable me
> one-button-filter-applying during painting with brush. The script
> is thus; It firstly gets the current brushes' size, sets it as the
> radius of gaussian blur and applies blur, so that it may work
> non-interractively but it adjust itself flexiblly according to the
> painting condition.
> But there's a problem. The procedure "gimp-brush-get-info" dosen't
> provide me with the actual brushes' size, since there's a option
> "Scale" in Tool Options dialog and I frequently change it. In
> addition I mainly use self-made pipe-brushes, which you cannot
> adjust within Brush Editor dialog.
>
> Then, I came to two solutions of this problem:
> a) Getting the status of "Scale" in a certain way
> b) Reading lines from preserved preferences (text files) in
> "tool-options" directory with python
>
> Choosing "a", I will have to know the right way how I can get the
> status. But I have entirely no idea though I read GIMP-Python
> Documentation; http://www.gimp.org/docs/python/index.html
> On the other hand "b" is an achievable way. But, files in
> "tool-options" directory are not seamlessly refreshed. They seem to
> be the just preservation of the last session of GIMP and I cannot
> refresh them except when the GIMP is completely quited or when
> "Save Tool Options Now" is clicked through "Toolbox > FIle >
> Preferencese > Tool Options".
>
> Won't you please help me if you have any ideas about these two
> issues, how I can get the status "Scale" in tool options or how I
> can print the current status on certain files when I like?
> I'm sorry I know too little because I'm not any sort of coders.
>

Hi there,

as you have noted, currently the PDB API lacks some recent paint brush 
(and other tools) parameters (like jutter and scale). There is 
currently no work around this, as you have perceived. 

Unfortunatelly the only thng I can think of right now is for your 
python-fu script to pop-up a self-created gtk+ dialog (non mandatroy, 
no modal), with an input field, wher one can type in the brush 
scale,, and keep the value in this field in a persistent file of its 
own between invocations.

Regards,

        js
        -><-


> Sincerely,
> Richter
> _______________________________________________
> Gimp-user mailing list
> Gimp-user@lists.XCF.Berkeley.EDU
> https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user


_______________________________________________
Gimp-user mailing list
Gimp-user@lists.XCF.Berkeley.EDU
https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user

Reply via email to