Mon Oct 04, 2021 1:01 pm
Mon Oct 04, 2021 6:57 pm
Mon Oct 04, 2021 7:56 pm
ofnuts wrote:There are no default parameters (actually, there is one for the runmode, as a keyword parameter, as done in python for parameters with default values, but you never use it). So, yes, you have to look up parameters (in the Python console, hit the "Browse..." button and all the doc is there).
There is neither a one-to-one relationship between UI actions and API calls. Many UI actions require several API calls (the oppoiste is sometimes true, too).
Tue Oct 05, 2021 2:16 am
ecs1749 wrote:ofnuts wrote:There are no default parameters (actually, there is one for the runmode, as a keyword parameter, as done in python for parameters with default values, but you never use it). So, yes, you have to look up parameters (in the Python console, hit the "Browse..." button and all the doc is there).
There is neither a one-to-one relationship between UI actions and API calls. Many UI actions require several API calls (the oppoiste is sometimes true, too).
That makes it unnecessarily hard. I am building my own wrapper and as time go on, I will end up with my own set of "easy" wrappers.
amount=1.0
radius=0.5
myWaveletSharpen(image, drawable, amount, radius)
saturation=10
myHueSaturation(drawable,saturation)
Tue Oct 05, 2021 2:47 pm
ofnuts wrote:ecs1749 wrote:ofnuts wrote:There are no default parameters (actually, there is one for the runmode, as a keyword parameter, as done in python for parameters with default values, but you never use it). So, yes, you have to look up parameters (in the Python console, hit the "Browse..." button and all the doc is there).
There is neither a one-to-one relationship between UI actions and API calls. Many UI actions require several API calls (the oppoiste is sometimes true, too).
That makes it unnecessarily hard. I am building my own wrapper and as time go on, I will end up with my own set of "easy" wrappers.
amount=1.0
radius=0.5
myWaveletSharpen(image, drawable, amount, radius)
saturation=10
myHueSaturation(drawable,saturation)
It doesn't try to be hard but to be general. Your default values are not necessarily mine. Writing "helper" functions or defining constants for things you use often is a fairly basic concept.