viewtopic.php?f=56&t=66091
But I did eventually succeed in consistently reproducing the effect reasonably closely.
So I then attempted to record it with the following script. But it failed, not creating the second edge.
Code: Select all
from JascApp import *
# See post at https://forum.corel.com/EN/viewtopic.php?f=56&t=66091
# And then at
# Place the selection and then run the script
# BUT, unlike the manual recording, this doesn't add the black edge
def ScriptProperties():
return {
'Author': u'Terry',
'Copyright': u'',
'Description': u'',
'Host': u'Paint Shop Pro',
'Host Version': u'8.10'
}
def Do(Environment):
# EnableOptimizedScriptUndo
App.Do( Environment, 'EnableOptimizedScriptUndo', {
})
# MoveSelection
App.Do( Environment, 'MoveSelection', {
'Offset': (9,-8),
'ClearSource': App.Constants.Boolean.true,
'GeneralSettings': {
'ExecutionMode': App.Constants.ExecutionMode.Default,
'AutoActionMode': App.Constants.AutoActionMode.Match
}
})
# DefloatSelection
App.Do( Environment, 'DefloatSelection', {
'GeneralSettings': {
'ExecutionMode': App.Constants.ExecutionMode.Default,
'AutoActionMode': App.Constants.AutoActionMode.Match
}
})
# MoveSelection
App.Do( Environment, 'MoveSelection', {
'Offset': (-11,3),
'ClearSource': App.Constants.Boolean.true,
'GeneralSettings': {
'ExecutionMode': App.Constants.ExecutionMode.Default,
'AutoActionMode': App.Constants.AutoActionMode.Match
}
})
# SelectNone
App.Do( Environment, 'SelectNone', {
'GeneralSettings': {
'ExecutionMode': App.Constants.ExecutionMode.Default,
'AutoActionMode': App.Constants.AutoActionMode.Match
}
})
I then saw that in both cases the script is not recording the important step of swapping black and white in Materials. The second script had a line containing 255, 255, 255 and changing that to 0, 0, 0 fixed it. But why did the script not capture the swap in either recording?
