On Sun, 2010-10-03 at 13:42 +0000, Alan Campbell wrote:

> > You need to explicitly create the submenu using
> > gimp-plugin-menu-branch-register. This procedure should accept
> > mnemonics marked with an underscore.
> > 
> 
> Tried
> (gimp-plugin-menu-branch-register "<Image>/File/Create" "W_oodrat")
> (gimp-plugin-menu-branch-register "<Image>/File/Create" "_Woodrat") 
> 
> followed by 
> 
> (script-fu-menu-register "wrdhb_create_half_blind_dovetail"
>                                   "<Image>/File/Create/W_oodrat")
> 
> or
> script-fu-menu-
> (script-fu-menu-register "wrdhb_create_half_blind_dovetail"
>                                   "<Image>/File/Create/_Woodrat")
> 
> or
> 
> (script-fu-menu-register "wrdhb_create_half_blind_dovetail"
>                                   "<Image>/File/Create/Woodrat")
> 
> 
> Always got the "Woodrat" folder under File | Create menu, no shortcut 
> key indicated.

I am pretty sure that it theoretically should work this way. After all
the Script-Fu extension itself creates sub-menus this way and those
sub-menus do have mnemonics. You definitely should not use the
underscore in the menu-register call.

However the problem is most likely that Script-Fu doesn't provide you
any means to call this procedure before the menu-register call is
executed. There would probably have to be a
script-fu-menu-branch-register() wrapper added for this purpose.

A possible solution would be to write your scripts in Python.


Sven


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

Reply via email to