From 305303330cf2da86a650cd54a8b582bb197b514f Mon Sep 17 00:00:00 2001 From: Jehan Date: Mon, 20 Jan 2025 20:11:14 +0100 Subject: [PATCH] app, libgimp, pdb: fix a null_ok/none_ok mixup. We had 2 flags to indicate that a PDB argument could be nullable: null_ok and none_ok. That was a huge mixup and the PDB generation code was using sometimes one, sometimes the other. Let's settle for only none_ok. This fixes a bunch of annotations. --- app/pdb/brush-select-cmds.c | 2 +- app/pdb/drawable-select-cmds.c | 2 +- app/pdb/font-select-cmds.c | 2 +- app/pdb/gradient-select-cmds.c | 2 +- app/pdb/palette-select-cmds.c | 2 +- app/pdb/pattern-select-cmds.c | 2 +- libgimp/gimp_pdb.c | 2 +- libgimp/gimpbrushselect_pdb.c | 4 ++-- libgimp/gimpbuffer_pdb.c | 2 +- libgimp/gimpdrawablefilter_pdb.c | 2 +- libgimp/gimpdrawableselect_pdb.c | 4 ++-- libgimp/gimpdynamics_pdb.c | 2 +- libgimp/gimpfonts_pdb.c | 2 +- libgimp/gimpfontselect_pdb.c | 4 ++-- libgimp/gimpgradients_pdb.c | 2 +- libgimp/gimpgradientselect_pdb.c | 4 ++-- libgimp/gimphelp_pdb.c | 2 +- libgimp/gimplayer_pdb.c | 4 ++-- libgimp/gimppalette_pdb.c | 4 ++-- libgimp/gimppalettes_pdb.c | 2 +- libgimp/gimppaletteselect_pdb.c | 4 ++-- libgimp/gimppatterns_pdb.c | 2 +- libgimp/gimppatternselect_pdb.c | 4 ++-- libgimp/gimppdb_pdb.c | 14 +++++++------- libgimp/gimpprogress_pdb.c | 4 ++-- pdb/app.pl | 4 ++-- pdb/groups/brush_select.pdb | 4 ++-- pdb/groups/buffer.pdb | 2 +- pdb/groups/drawable_filter.pdb | 2 +- pdb/groups/drawable_select.pdb | 4 ++-- pdb/groups/dynamics.pdb | 2 +- pdb/groups/font_select.pdb | 4 ++-- pdb/groups/fonts.pdb | 2 +- pdb/groups/gimp.pdb | 2 +- pdb/groups/gradient_select.pdb | 4 ++-- pdb/groups/gradients.pdb | 2 +- pdb/groups/help.pdb | 2 +- pdb/groups/layer.pdb | 4 ++-- pdb/groups/palette.pdb | 7 ++----- pdb/groups/palette_select.pdb | 4 ++-- pdb/groups/palettes.pdb | 2 +- pdb/groups/pattern_select.pdb | 4 ++-- pdb/groups/patterns.pdb | 2 +- pdb/groups/pdb.pdb | 14 +++++++------- pdb/groups/progress.pdb | 4 ++-- 45 files changed, 76 insertions(+), 79 deletions(-) diff --git a/app/pdb/brush-select-cmds.c b/app/pdb/brush-select-cmds.c index 801804e5bb..7180052c17 100644 --- a/app/pdb/brush-select-cmds.c +++ b/app/pdb/brush-select-cmds.c @@ -173,7 +173,7 @@ register_brush_select_procs (GimpPDB *pdb) gimp_param_spec_brush ("initial-brush", "initial brush", "The brush to set as the initial choice", - FALSE, + TRUE, NULL, FALSE, GIMP_PARAM_READWRITE)); diff --git a/app/pdb/drawable-select-cmds.c b/app/pdb/drawable-select-cmds.c index d5d2214232..e1e6d121b6 100644 --- a/app/pdb/drawable-select-cmds.c +++ b/app/pdb/drawable-select-cmds.c @@ -172,7 +172,7 @@ register_drawable_select_procs (GimpPDB *pdb) gimp_param_spec_drawable ("initial-drawable", "initial drawable", "The drawable to set as the initial choice", - FALSE, + TRUE, GIMP_PARAM_READWRITE | GIMP_PARAM_NO_VALIDATE)); gimp_procedure_add_argument (procedure, g_param_spec_boxed ("parent-window", diff --git a/app/pdb/font-select-cmds.c b/app/pdb/font-select-cmds.c index af36a12c43..f5c85422b0 100644 --- a/app/pdb/font-select-cmds.c +++ b/app/pdb/font-select-cmds.c @@ -175,7 +175,7 @@ register_font_select_procs (GimpPDB *pdb) gimp_param_spec_font ("initial-font", "initial font", "The name of the initial font choice.", - FALSE, + TRUE, NULL, FALSE, GIMP_PARAM_READWRITE)); diff --git a/app/pdb/gradient-select-cmds.c b/app/pdb/gradient-select-cmds.c index f6bd4ff6e9..c8444d78b2 100644 --- a/app/pdb/gradient-select-cmds.c +++ b/app/pdb/gradient-select-cmds.c @@ -179,7 +179,7 @@ register_gradient_select_procs (GimpPDB *pdb) gimp_param_spec_gradient ("initial-gradient", "initial gradient", "The initial gradient choice", - FALSE, + TRUE, NULL, FALSE, GIMP_PARAM_READWRITE)); diff --git a/app/pdb/palette-select-cmds.c b/app/pdb/palette-select-cmds.c index a46c049698..c2c17ecdbd 100644 --- a/app/pdb/palette-select-cmds.c +++ b/app/pdb/palette-select-cmds.c @@ -173,7 +173,7 @@ register_palette_select_procs (GimpPDB *pdb) gimp_param_spec_palette ("initial-palette", "initial palette", "The palette to set as the initial choice.", - FALSE, + TRUE, NULL, FALSE, GIMP_PARAM_READWRITE)); diff --git a/app/pdb/pattern-select-cmds.c b/app/pdb/pattern-select-cmds.c index b21c1d6d7e..3ec165dd69 100644 --- a/app/pdb/pattern-select-cmds.c +++ b/app/pdb/pattern-select-cmds.c @@ -173,7 +173,7 @@ register_pattern_select_procs (GimpPDB *pdb) gimp_param_spec_pattern ("initial-pattern", "initial pattern", "The pattern to set as the initial choice", - FALSE, + TRUE, NULL, FALSE, GIMP_PARAM_READWRITE)); diff --git a/libgimp/gimp_pdb.c b/libgimp/gimp_pdb.c index ba4aa05202..54ab8ce8c0 100644 --- a/libgimp/gimp_pdb.c +++ b/libgimp/gimp_pdb.c @@ -253,7 +253,7 @@ gimp_get_parasite_list (void) /** * gimp_temp_file: - * @extension: The extension the file will have. + * @extension: (nullable): The extension the file will have. * * Generates a unique temporary file. * diff --git a/libgimp/gimpbrushselect_pdb.c b/libgimp/gimpbrushselect_pdb.c index 844d309b00..d5f453d65e 100644 --- a/libgimp/gimpbrushselect_pdb.c +++ b/libgimp/gimpbrushselect_pdb.c @@ -41,8 +41,8 @@ * gimp_brushes_popup: * @brush_callback: The callback PDB proc to call when user chooses a brush. * @popup_title: Title of the brush selection dialog. - * @initial_brush: The brush to set as the initial choice. - * @parent_window: An optional parent window handle for the popup to be set transient to. + * @initial_brush: (nullable): The brush to set as the initial choice. + * @parent_window: (nullable): An optional parent window handle for the popup to be set transient to. * * Invokes the GIMP brush selection dialog. * diff --git a/libgimp/gimpbuffer_pdb.c b/libgimp/gimpbuffer_pdb.c index 4b9ef55a7f..6eb219cdb2 100644 --- a/libgimp/gimpbuffer_pdb.c +++ b/libgimp/gimpbuffer_pdb.c @@ -38,7 +38,7 @@ /** * gimp_buffers_get_name_list: - * @filter: An optional regular expression used to filter the list. + * @filter: (nullable): An optional regular expression used to filter the list. * * Retrieve a complete listing of the available buffers. * diff --git a/libgimp/gimpdrawablefilter_pdb.c b/libgimp/gimpdrawablefilter_pdb.c index 4050dcf0d3..3641ecf401 100644 --- a/libgimp/gimpdrawablefilter_pdb.c +++ b/libgimp/gimpdrawablefilter_pdb.c @@ -77,7 +77,7 @@ gimp_drawable_filter_id_is_valid (gint filter_id) * gimp_drawable_filter_new: * @drawable: The drawable. * @operation_name: The GEGL operation's name. - * @name: The effect name. + * @name: (nullable): The effect name. * * Create a new drawable filter. * diff --git a/libgimp/gimpdrawableselect_pdb.c b/libgimp/gimpdrawableselect_pdb.c index 4defd2a4cd..1e195cc79b 100644 --- a/libgimp/gimpdrawableselect_pdb.c +++ b/libgimp/gimpdrawableselect_pdb.c @@ -41,8 +41,8 @@ * @callback: The callback PDB proc to call when user chooses an drawable. * @popup_title: Title of the drawable selection dialog. * @drawable_type: The name of the GIMP_TYPE_DRAWABLE subtype. - * @initial_drawable: The drawable to set as the initial choice. - * @parent_window: An optional parent window handle for the popup to be set transient to. + * @initial_drawable: (nullable): The drawable to set as the initial choice. + * @parent_window: (nullable): An optional parent window handle for the popup to be set transient to. * * Invokes the drawable selection dialog. * diff --git a/libgimp/gimpdynamics_pdb.c b/libgimp/gimpdynamics_pdb.c index e9ab752dbf..a5dec727cb 100644 --- a/libgimp/gimpdynamics_pdb.c +++ b/libgimp/gimpdynamics_pdb.c @@ -73,7 +73,7 @@ gimp_dynamics_refresh (void) /** * gimp_dynamics_get_name_list: - * @filter: An optional regular expression used to filter the list. + * @filter: (nullable): An optional regular expression used to filter the list. * * Retrieve the list of loaded paint dynamics. * diff --git a/libgimp/gimpfonts_pdb.c b/libgimp/gimpfonts_pdb.c index 86dd8d56a1..d959731a15 100644 --- a/libgimp/gimpfonts_pdb.c +++ b/libgimp/gimpfonts_pdb.c @@ -117,7 +117,7 @@ _gimp_fonts_get_custom_configs (gchar **sysconfig, /** * gimp_fonts_get_list: - * @filter: An optional regular expression used to filter the list. + * @filter: (nullable): An optional regular expression used to filter the list. * * Retrieve the list of loaded fonts. * diff --git a/libgimp/gimpfontselect_pdb.c b/libgimp/gimpfontselect_pdb.c index ee81427a8b..0db3ce2342 100644 --- a/libgimp/gimpfontselect_pdb.c +++ b/libgimp/gimpfontselect_pdb.c @@ -49,8 +49,8 @@ * gimp_fonts_popup: * @font_callback: The callback PDB proc to call when user chooses a font. * @popup_title: Title of the font selection dialog. - * @initial_font: The name of the initial font choice. - * @parent_window: An optional parent window handle for the popup to be set transient to. + * @initial_font: (nullable): The name of the initial font choice. + * @parent_window: (nullable): An optional parent window handle for the popup to be set transient to. * * Invokes the Gimp font selection dialog. * diff --git a/libgimp/gimpgradients_pdb.c b/libgimp/gimpgradients_pdb.c index 56697fa9a3..8a72f36868 100644 --- a/libgimp/gimpgradients_pdb.c +++ b/libgimp/gimpgradients_pdb.c @@ -70,7 +70,7 @@ gimp_gradients_refresh (void) /** * gimp_gradients_get_list: - * @filter: An optional regular expression used to filter the list. + * @filter: (nullable): An optional regular expression used to filter the list. * * Retrieve the list of loaded gradients. * diff --git a/libgimp/gimpgradientselect_pdb.c b/libgimp/gimpgradientselect_pdb.c index 2523deeba3..b3360141ad 100644 --- a/libgimp/gimpgradientselect_pdb.c +++ b/libgimp/gimpgradientselect_pdb.c @@ -41,8 +41,8 @@ * gimp_gradients_popup: * @gradient_callback: The callback PDB proc to call when user chooses a gradient. * @popup_title: Title of the gradient selection dialog. - * @initial_gradient: The initial gradient choice. - * @parent_window: An optional parent window handle for the popup to be set transient to. + * @initial_gradient: (nullable): The initial gradient choice. + * @parent_window: (nullable): An optional parent window handle for the popup to be set transient to. * * Invokes the Gimp gradients selection dialog. * diff --git a/libgimp/gimphelp_pdb.c b/libgimp/gimphelp_pdb.c index a5b08dca46..e928b686ff 100644 --- a/libgimp/gimphelp_pdb.c +++ b/libgimp/gimphelp_pdb.c @@ -38,7 +38,7 @@ /** * gimp_help: - * @help_domain: The help domain in which help_id is registered. + * @help_domain: (nullable): The help domain in which help_id is registered. * @help_id: The help page's ID. * * Load a help page. diff --git a/libgimp/gimplayer_pdb.c b/libgimp/gimplayer_pdb.c index 49d78959f2..f403b11259 100644 --- a/libgimp/gimplayer_pdb.c +++ b/libgimp/gimplayer_pdb.c @@ -42,7 +42,7 @@ * @width: The layer width. * @height: The layer height. * @type: The layer type. - * @name: The layer name. + * @name: (nullable): The layer name. * @opacity: The layer opacity. * @mode: The layer combination mode. * @@ -98,7 +98,7 @@ _gimp_layer_new (GimpImage *image, * gimp_layer_new_from_visible: * @image: The source image from where the content is copied. * @dest_image: The destination image to which to add the layer. - * @name: The layer name. + * @name: (nullable): The layer name. * * Create a new layer from what is visible in an image. * diff --git a/libgimp/gimppalette_pdb.c b/libgimp/gimppalette_pdb.c index 4de6def50f..bf459b7c14 100644 --- a/libgimp/gimppalette_pdb.c +++ b/libgimp/gimppalette_pdb.c @@ -266,7 +266,7 @@ gimp_palette_set_columns (GimpPalette *palette, /** * gimp_palette_add_entry: * @palette: The palette. - * @entry_name: A name for the entry. + * @entry_name: (nullable): A name for the entry. * @color: The color for the added entry. * @entry_num: (out): The index of the added entry. * @@ -488,7 +488,7 @@ gimp_palette_get_entry_name (GimpPalette *palette, * gimp_palette_set_entry_name: * @palette: The palette. * @entry_num: The entry to get. - * @entry_name: The new name. + * @entry_name: (nullable): The new name. * * Sets the name of an entry in the palette. * diff --git a/libgimp/gimppalettes_pdb.c b/libgimp/gimppalettes_pdb.c index e43455a26a..baacc55338 100644 --- a/libgimp/gimppalettes_pdb.c +++ b/libgimp/gimppalettes_pdb.c @@ -70,7 +70,7 @@ gimp_palettes_refresh (void) /** * gimp_palettes_get_list: - * @filter: An optional regular expression used to filter the list. + * @filter: (nullable): An optional regular expression used to filter the list. * * Retrieves a list of all of the available palettes * diff --git a/libgimp/gimppaletteselect_pdb.c b/libgimp/gimppaletteselect_pdb.c index e278138054..dd8a34e643 100644 --- a/libgimp/gimppaletteselect_pdb.c +++ b/libgimp/gimppaletteselect_pdb.c @@ -41,8 +41,8 @@ * gimp_palettes_popup: * @palette_callback: The callback PDB proc to call when user chooses a palette. * @popup_title: Title of the palette selection dialog. - * @initial_palette: The palette to set as the initial choice. - * @parent_window: An optional parent window handle for the popup to be set transient to. + * @initial_palette: (nullable): The palette to set as the initial choice. + * @parent_window: (nullable): An optional parent window handle for the popup to be set transient to. * * Invokes the Gimp palette selection dialog. * diff --git a/libgimp/gimppatterns_pdb.c b/libgimp/gimppatterns_pdb.c index b79462c2bc..798ca9411c 100644 --- a/libgimp/gimppatterns_pdb.c +++ b/libgimp/gimppatterns_pdb.c @@ -70,7 +70,7 @@ gimp_patterns_refresh (void) /** * gimp_patterns_get_list: - * @filter: An optional regular expression used to filter the list. + * @filter: (nullable): An optional regular expression used to filter the list. * * Retrieve a complete listing of the available patterns. * diff --git a/libgimp/gimppatternselect_pdb.c b/libgimp/gimppatternselect_pdb.c index 0105c425ff..7763e2b4c6 100644 --- a/libgimp/gimppatternselect_pdb.c +++ b/libgimp/gimppatternselect_pdb.c @@ -41,8 +41,8 @@ * gimp_patterns_popup: * @pattern_callback: The callback PDB proc to call when the user chooses a pattern. * @popup_title: Title of the pattern selection dialog. - * @initial_pattern: The pattern to set as the initial choice. - * @parent_window: An optional parent window handle for the popup to be set transient to. + * @initial_pattern: (nullable): The pattern to set as the initial choice. + * @parent_window: (nullable): An optional parent window handle for the popup to be set transient to. * * Invokes the Gimp pattern selection. * diff --git a/libgimp/gimppdb_pdb.c b/libgimp/gimppdb_pdb.c index c0659a75c3..9c6b3572c9 100644 --- a/libgimp/gimppdb_pdb.c +++ b/libgimp/gimppdb_pdb.c @@ -349,7 +349,7 @@ _gimp_pdb_get_proc_return_value (const gchar *procedure_name, /** * _gimp_pdb_set_proc_image_types: * @procedure_name: The procedure for which to install the menu path. - * @image_types: The procedure's supported image types. + * @image_types: (nullable): The procedure's supported image types. * * Set the supported image types for a plug-in procedure. * @@ -658,9 +658,9 @@ _gimp_pdb_set_proc_icon (const gchar *procedure_name, /** * _gimp_pdb_set_proc_documentation: * @procedure_name: The procedure for which to install the menu path. - * @blurb: A short blurb. - * @help: Detailed procedure help. - * @help_id: The procedure help_id. + * @blurb: (nullable): A short blurb. + * @help: (nullable): Detailed procedure help. + * @help_id: (nullable): The procedure help_id. * * Set the documentation for a plug-in procedure. * @@ -756,9 +756,9 @@ _gimp_pdb_get_proc_documentation (const gchar *procedure_name, /** * _gimp_pdb_set_proc_attribution: * @procedure_name: The procedure for which to install the menu path. - * @authors: Authors of the procedure. - * @copyright: The copyright. - * @date: Copyright date. + * @authors: (nullable): Authors of the procedure. + * @copyright: (nullable): The copyright. + * @date: (nullable): Copyright date. * * Set the attribution for a plug-in procedure. * diff --git a/libgimp/gimpprogress_pdb.c b/libgimp/gimpprogress_pdb.c index 906cdc2bc8..9f8ba01324 100644 --- a/libgimp/gimpprogress_pdb.c +++ b/libgimp/gimpprogress_pdb.c @@ -38,7 +38,7 @@ /** * _gimp_progress_init: - * @message: Message to use in the progress dialog. + * @message: (nullable): Message to use in the progress dialog. * @gdisplay: (nullable): GimpDisplay to update progressbar in, or %NULL for a separate window. * * Initializes the progress bar for the current plug-in. @@ -146,7 +146,7 @@ gimp_progress_pulse (void) /** * gimp_progress_set_text: - * @message: Message to use in the progress dialog. + * @message: (nullable): Message to use in the progress dialog. * * Changes the text in the progress bar for the current plug-in. * diff --git a/pdb/app.pl b/pdb/app.pl index 37ea4c0a82..654e9a9603 100644 --- a/pdb/app.pl +++ b/pdb/app.pl @@ -587,14 +587,14 @@ CODE } elsif ($pdbtype eq 'string') { $allow_non_utf8 = exists $arg->{allow_non_utf8} ? 'TRUE' : 'FALSE'; - $null_ok = exists $arg->{null_ok} ? 'TRUE' : 'FALSE'; + $none_ok = exists $arg->{none_ok} ? 'TRUE' : 'FALSE'; $non_empty = exists $arg->{non_empty} ? 'TRUE' : 'FALSE'; $default = exists $arg->{default} ? $arg->{default} : NULL; $pspec = < 'The callback PDB proc to call when user chooses a brush' }, { name => 'popup_title', type => 'string', desc => 'Title of the brush selection dialog' }, - { name => 'initial_brush', type => 'brush', null_ok => 1, + { name => 'initial_brush', type => 'brush', none_ok => 1, desc => 'The brush to set as the initial choice' }, - { name => 'parent_window', type => 'bytes', null_ok => 1, + { name => 'parent_window', type => 'bytes', none_ok => 1, desc => 'An optional parent window handle for the popup to be set transient to' } ); diff --git a/pdb/groups/buffer.pdb b/pdb/groups/buffer.pdb index ebea3232d7..1f8c8fb8d1 100644 --- a/pdb/groups/buffer.pdb +++ b/pdb/groups/buffer.pdb @@ -26,7 +26,7 @@ HELP &mitch_pdb_misc('2005', '2.4'); @inargs = ( - { name => 'filter', type => 'string', null_ok => 1, + { name => 'filter', type => 'string', none_ok => 1, desc => 'An optional regular expression used to filter the list' } ); diff --git a/pdb/groups/drawable_filter.pdb b/pdb/groups/drawable_filter.pdb index 28e00d2d30..1d4da5bfa0 100644 --- a/pdb/groups/drawable_filter.pdb +++ b/pdb/groups/drawable_filter.pdb @@ -64,7 +64,7 @@ HELP { name => 'operation_name', type => 'string', desc => "The GEGL operation's name" }, { name => 'name', type => 'string', - desc => 'The effect name', null_ok => 0 }, + desc => 'The effect name', none_ok => 0 }, ); @outargs = ( diff --git a/pdb/groups/drawable_select.pdb b/pdb/groups/drawable_select.pdb index 8d4b848e3b..1b07919e76 100644 --- a/pdb/groups/drawable_select.pdb +++ b/pdb/groups/drawable_select.pdb @@ -27,9 +27,9 @@ sub drawables_popup { desc => 'Title of the drawable selection dialog' }, { name => 'drawable_type', type => 'string', non_empty => 1, desc => 'The name of the GIMP_TYPE_DRAWABLE subtype' }, - { name => 'initial_drawable', type => 'drawable', null_ok => 1, no_validate => 1, + { name => 'initial_drawable', type => 'drawable', none_ok => 1, no_validate => 1, desc => 'The drawable to set as the initial choice' }, - { name => 'parent_window', type => 'bytes', null_ok => 1, + { name => 'parent_window', type => 'bytes', none_ok => 1, desc => 'An optional parent window handle for the popup to be set transient to' } ); diff --git a/pdb/groups/dynamics.pdb b/pdb/groups/dynamics.pdb index 801e564606..72271d22a5 100644 --- a/pdb/groups/dynamics.pdb +++ b/pdb/groups/dynamics.pdb @@ -47,7 +47,7 @@ HELP &mitch_pdb_misc('2011', '2.8'); @inargs = ( - { name => 'filter', type => 'string', null_ok => 1, + { name => 'filter', type => 'string', none_ok => 1, desc => 'An optional regular expression used to filter the list' } ); diff --git a/pdb/groups/font_select.pdb b/pdb/groups/font_select.pdb index 647db6a8e7..a88f449be9 100644 --- a/pdb/groups/font_select.pdb +++ b/pdb/groups/font_select.pdb @@ -28,9 +28,9 @@ sub fonts_popup { desc => 'The callback PDB proc to call when user chooses a font' }, { name => 'popup_title', type => 'string', desc => 'Title of the font selection dialog' }, - { name => 'initial_font', type => 'font', null_ok => 1, + { name => 'initial_font', type => 'font', none_ok => 1, desc => 'The name of the initial font choice.' }, - { name => 'parent_window', type => 'bytes', null_ok => 1, + { name => 'parent_window', type => 'bytes', none_ok => 1, desc => 'An optional parent window handle for the popup to be set transient to' } ); diff --git a/pdb/groups/fonts.pdb b/pdb/groups/fonts.pdb index c6f5c17498..a0c0487a45 100644 --- a/pdb/groups/fonts.pdb +++ b/pdb/groups/fonts.pdb @@ -49,7 +49,7 @@ HELP &neo_pdb_misc('2003'); @inargs = ( - { name => 'filter', type => 'string', null_ok => 1, + { name => 'filter', type => 'string', none_ok => 1, desc => 'An optional regular expression used to filter the list' } ); diff --git a/pdb/groups/gimp.pdb b/pdb/groups/gimp.pdb index b79c357b72..187795161a 100644 --- a/pdb/groups/gimp.pdb +++ b/pdb/groups/gimp.pdb @@ -200,7 +200,7 @@ HELP @inargs = ( { name => 'extension', type => 'string', - allow_non_utf8 => 1, null_ok => 1, + allow_non_utf8 => 1, none_ok => 1, desc => 'The extension the file will have' } ); diff --git a/pdb/groups/gradient_select.pdb b/pdb/groups/gradient_select.pdb index 1303d9459c..0f6638e8b5 100644 --- a/pdb/groups/gradient_select.pdb +++ b/pdb/groups/gradient_select.pdb @@ -28,9 +28,9 @@ sub gradients_popup { desc => 'The callback PDB proc to call when user chooses a gradient' }, { name => 'popup_title', type => 'string', desc => 'Title of the gradient selection dialog' }, - { name => 'initial_gradient', type => 'gradient', null_ok => 1, + { name => 'initial_gradient', type => 'gradient', none_ok => 1, desc => 'The initial gradient choice' }, - { name => 'parent_window', type => 'bytes', null_ok => 1, + { name => 'parent_window', type => 'bytes', none_ok => 1, desc => 'An optional parent window handle for the popup to be set transient to' } ); diff --git a/pdb/groups/gradients.pdb b/pdb/groups/gradients.pdb index 8f266a3c2e..3344d2138b 100644 --- a/pdb/groups/gradients.pdb +++ b/pdb/groups/gradients.pdb @@ -47,7 +47,7 @@ HELP &federico_pdb_misc('1997'); @inargs = ( - { name => 'filter', type => 'string', null_ok => 1, + { name => 'filter', type => 'string', none_ok => 1, desc => 'An optional regular expression used to filter the list' } ); diff --git a/pdb/groups/help.pdb b/pdb/groups/help.pdb index e2616c5ba3..48519afece 100644 --- a/pdb/groups/help.pdb +++ b/pdb/groups/help.pdb @@ -31,7 +31,7 @@ HELP &mitch_pdb_misc('2000'); @inargs = ( - { name => 'help_domain', type => 'string', null_ok => 1, + { name => 'help_domain', type => 'string', none_ok => 1, desc => "The help domain in which help_id is registered" }, { name => 'help_id', type => 'string', desc => "The help page's ID" } diff --git a/pdb/groups/layer.pdb b/pdb/groups/layer.pdb index f9b96baec1..04ed8afdf5 100644 --- a/pdb/groups/layer.pdb +++ b/pdb/groups/layer.pdb @@ -43,7 +43,7 @@ HELP { name => 'type', type => 'enum GimpImageType', desc => 'The layer type' }, { name => 'name', type => 'string', - desc => 'The layer name', null_ok => 0 }, + desc => 'The layer name', none_ok => 0 }, { name => 'opacity', type => '0 <= double <= 100', desc => 'The layer opacity' }, { name => 'mode', type => 'enum GimpLayerMode', @@ -144,7 +144,7 @@ HELP { name => 'dest_image', type => 'image', desc => 'The destination image to which to add the layer' }, { name => 'name', type => 'string', - desc => 'The layer name', null_ok => 1 } + desc => 'The layer name', none_ok => 1 } ); @outargs = ( diff --git a/pdb/groups/palette.pdb b/pdb/groups/palette.pdb index b1665f6b45..7e32629622 100644 --- a/pdb/groups/palette.pdb +++ b/pdb/groups/palette.pdb @@ -202,9 +202,6 @@ CODE ); } - -# FIXME null_ok should allow None in Python for name, but fails. - sub palette_add_entry { $blurb = 'Appends an entry to the palette.'; @@ -220,7 +217,7 @@ HELP @inargs = ( ${palette_arg_spec}, - { name => 'entry_name', type => 'string', null_ok => 1, + { name => 'entry_name', type => 'string', none_ok => 1, desc => 'A name for the entry' }, { name => 'color', type => 'geglcolor', desc => 'The color for the added entry.' } @@ -414,7 +411,7 @@ HELP ${palette_arg_spec}, { name => 'entry_num', type => 'int32', desc => 'The entry to get' }, - { name => 'entry_name', type => 'string', null_ok => 1, + { name => 'entry_name', type => 'string', none_ok => 1, desc => 'The new name' } ); diff --git a/pdb/groups/palette_select.pdb b/pdb/groups/palette_select.pdb index 998aca67fa..bb03b3a2d4 100644 --- a/pdb/groups/palette_select.pdb +++ b/pdb/groups/palette_select.pdb @@ -27,9 +27,9 @@ sub palettes_popup { desc => 'The callback PDB proc to call when user chooses a palette' }, { name => 'popup_title', type => 'string', desc => 'Title of the palette selection dialog' }, - { name => 'initial_palette', type => 'palette', null_ok => 1, + { name => 'initial_palette', type => 'palette', none_ok => 1, desc => 'The palette to set as the initial choice.' }, - { name => 'parent_window', type => 'bytes', null_ok => 1, + { name => 'parent_window', type => 'bytes', none_ok => 1, desc => 'An optional parent window handle for the popup to be set transient to' } ); diff --git a/pdb/groups/palettes.pdb b/pdb/groups/palettes.pdb index a775cdaec5..51540b524a 100644 --- a/pdb/groups/palettes.pdb +++ b/pdb/groups/palettes.pdb @@ -47,7 +47,7 @@ HELP &rock_pdb_misc('2001'); @inargs = ( - { name => 'filter', type => 'string', null_ok => 1, + { name => 'filter', type => 'string', none_ok => 1, desc => 'An optional regular expression used to filter the list' } ); diff --git a/pdb/groups/pattern_select.pdb b/pdb/groups/pattern_select.pdb index 5b4903ce2f..22b7b00300 100644 --- a/pdb/groups/pattern_select.pdb +++ b/pdb/groups/pattern_select.pdb @@ -27,9 +27,9 @@ sub patterns_popup { desc => 'The callback PDB proc to call when the user chooses a pattern' }, { name => 'popup_title', type => 'string', desc => 'Title of the pattern selection dialog' }, - { name => 'initial_pattern', type => 'pattern', null_ok => 1, + { name => 'initial_pattern', type => 'pattern', none_ok => 1, desc => 'The pattern to set as the initial choice' }, - { name => 'parent_window', type => 'bytes', null_ok => 1, + { name => 'parent_window', type => 'bytes', none_ok => 1, desc => 'An optional parent window handle for the popup to be set transient to' } ); diff --git a/pdb/groups/patterns.pdb b/pdb/groups/patterns.pdb index f92fa33777..2a86bf68bb 100644 --- a/pdb/groups/patterns.pdb +++ b/pdb/groups/patterns.pdb @@ -47,7 +47,7 @@ HELP &std_pdb_misc; @inargs = ( - { name => 'filter', type => 'string', null_ok => 1, + { name => 'filter', type => 'string', none_ok => 1, desc => 'An optional regular expression used to filter the list' } ); diff --git a/pdb/groups/pdb.pdb b/pdb/groups/pdb.pdb index 42abc5407d..501414d117 100644 --- a/pdb/groups/pdb.pdb +++ b/pdb/groups/pdb.pdb @@ -360,7 +360,7 @@ HELP @inargs = ( { name => 'procedure_name', type => 'string', non_empty => 1, desc => 'The procedure for which to install the menu path' }, - { name => 'image_types', type => 'string', null_ok => 1, + { name => 'image_types', type => 'string', none_ok => 1, desc => "The procedure's supported image types" } ); @@ -700,11 +700,11 @@ HELP @inargs = ( { name => 'procedure_name', type => 'string', non_empty => 1, desc => 'The procedure for which to install the menu path' }, - { name => 'blurb', type => 'string', null_ok => 1, + { name => 'blurb', type => 'string', none_ok => 1, desc => 'A short blurb' }, - { name => 'help', type => 'string', null_ok => 1, + { name => 'help', type => 'string', none_ok => 1, desc => 'Detailed procedure help' }, - { name => 'help_id', type => 'string', null_ok => 1, + { name => 'help_id', type => 'string', none_ok => 1, desc => 'The procedure help_id' } ); @@ -792,11 +792,11 @@ HELP @inargs = ( { name => 'procedure_name', type => 'string', non_empty => 1, desc => 'The procedure for which to install the menu path' }, - { name => 'authors', type => 'string', null_ok => 1, + { name => 'authors', type => 'string', none_ok => 1, desc => 'Authors of the procedure' }, - { name => 'copyright', type => 'string', null_ok => 1, + { name => 'copyright', type => 'string', none_ok => 1, desc => 'The copyright' }, - { name => 'date', type => 'string', null_ok => 1, + { name => 'date', type => 'string', none_ok => 1, desc => 'Copyright date' } ); diff --git a/pdb/groups/progress.pdb b/pdb/groups/progress.pdb index d25f978274..e8a934e418 100644 --- a/pdb/groups/progress.pdb +++ b/pdb/groups/progress.pdb @@ -29,7 +29,7 @@ HELP $lib_private = 1; @inargs = ( - { name => 'message', type => 'string', null_ok => 1, + { name => 'message', type => 'string', none_ok => 1, desc => 'Message to use in the progress dialog' }, { name => 'gdisplay', type => 'display', none_ok => 1, desc => 'GimpDisplay to update progressbar in, or %NULL for a separate @@ -130,7 +130,7 @@ HELP &neo_pdb_misc('2005', '2.4'); @inargs = ( - { name => 'message', type => 'string', null_ok => 1, + { name => 'message', type => 'string', none_ok => 1, desc => 'Message to use in the progress dialog' } );