GIMP,python-fu:如何禁用“输入图片"和“输入可绘制" [英] GIMP, python-fu: How to disable "Input image" and "Input drawable"

查看:129
本文介绍了GIMP,python-fu:如何禁用“输入图片"和“输入可绘制"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对gimp如何为python插件生成gui的艺术感到困惑.

i am confused a little about the art of how gimp generates the gui for python plug-ins.

gimp为我的脚本生成了两个不必要的字段. 输入图像"和输入可绘制对象". 我该如何禁用它们?

gimp generates two, for my script, needless fields. "Input image" and "Input drawable". how can i disable them?

在标准的文档中我什么都没找到.

I didn't find anything about it in the standart documetation.

我的注册方法:

register(
  "fixPngColors",
  "fixPngColors",
  "fixPngColors",
  "Author",
  "Author",
  "2013",
  "<Image>/plug-ins/BATCH PNG Color Fix",
  "",
  [
  (PF_DIRNAME, "png_input_directory", "Png directory(INPUT)", ""),
  (PF_DIRNAME, "png_output_directory", "Png directory(OUTPUT)", ""),
  (PF_INT, "c_count", "Max Colors", "255"),
  ],
  [],
  launcher
  )

如您所见,其他两个都没有.

like you can see, nothing about the other two.

推荐答案

是因为

"<Image>/plug-ins/BATCH PNG Color Fix",

在注册功能中!

有同样的问题.将菜单移到另一个位置,例如

Had the same Problem. Move the menu to another place like

"<Toolbox>/MyScripts/BATCH PNG Color Fix",

,您不再需要输入图像.

and you dont need an input image anymore.

如果将插件放置在图像"下,则Gimp会假定您需要图像和可绘制对象作为输入.这似乎覆盖了其他所有内容.

If you place an plug-in under "Image", Gimp assumes you need an image and a drawable as input. This seems to override everything else.

这篇关于GIMP,python-fu:如何禁用“输入图片"和“输入可绘制"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆