Clicking on color picker in py plug-in dialog gives "dll is not a valid Win32 application"
GIMP version: 2.10.10
Operating System: Windows 10 (64 bits)
Package: Installer from gimp.org
Description of the bug
When running a plug-in in GIMP v2.10.10 with a PF_COLOR parameter, the plugin script works correctly, except when clicking on the color picker widget in the plugin dialog, itt displays several Error/Warning messages, telling some dll are not valid Win32 applications.
I don't think it is a duplicate of #1438 (closed) because it's not the same version, and it doesn't throw the same error.
Reproduction
Is the bug reproducible? [Always (for me)]
Reproduction steps:
1.Put the script below in your plug-in folder
2.Run the script (Fliter -> PFCOLOR test)
3.Click on the color picker in the plugin dialog
#!/usr/bin/env python
# Dummy script to reproduce the color picker bug
# Copy plug-in file, start GIMP start plugin and click on color picker
from gimpfu import *
def fill_with_color(image, layer, thecolor, thesize):
# prepare for clean up later
prev_layer = image.active_layer
pdb.gimp_image_undo_group_start(image)
pdb.gimp_context_push()
pdb.gimp_context_set_default_colors()
# check if there is any selection
is_selection, x1, y1, x2, y2 = pdb.gimp_selection_bounds(image)
if not (is_selection):
pdb.gimp_message('There is nothing selected, create a selected region and try again.')
else:
# fill new selection with pure white color
pdb.gimp_image_select_item(image,CHANNEL_OP_REPLACE,image.active_layer)
pdb.gimp_context_set_foreground(thecolor)
pdb.gimp_edit_fill(image.active_layer,FOREGROUND_FILL)
# do clean up
pdb.gimp_context_pop()
image.active_layer = prev_layer
image.active_layer.visible = True
pdb.gimp_image_undo_group_end(image)
# pdb.gimp_displays_flush()
register(
"python_fu_test_colorpicker",
"Test Python color picker",
"Test Python color picker",
"BdR",
"BdR",
"2018",
"<Image>/Python-Fu/Test Python color picker", #Menu path
"",
[
(PF_COLOR, "thecolor", "select a color:", (0, 128, 255) ),
(PF_INT, "thesize", "Gaussian blur size:", 45)
],
[],
fill_with_color
)
main()
…
Expected result: No errors
Actual result: Some Warnings/Errors about some dlls being "not valid Win32 applications".
Additional information
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcolor-selector-cmyk.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcolor-selector-cmyk.dll': is not a valid Win32 application.
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcolor-selector-water.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcolor-selector-water.dll': is not a valid Win32 application.
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcolor-selector-wheel.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcolor-selector-wheel.dll': is not a valid Win32 application.
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcontroller-dx-dinput.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libcontroller-dx-dinput.dll': is not a valid Win32 application.
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-clip-warning.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-clip-warning.dll': is not a valid Win32 application.
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-color-blind.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-color-blind.dll': is not a valid Win32 application.
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-gamma.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-gamma.dll': is not a valid Win32 application.
PFCOLOR test-Warning: Module 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-high-contrast.dll' load error: 'c:\Program Files\GIMP 2\lib\gimp\2.0\modules\libdisplay-filter-high-contrast.dll': is not a valid Win32 application.