[EMAIL PROTECTED] writes:
> I am having difficulties enumerating, and identifying layers in a
> Gimp Plug-in. Is there a good source for code that shows how to
> do this? My need is to save the text information found in a Gimp
> document/image into another file. To do this, I need to iterate
> through all of the layers, find the text ones, get the text and
> save it to a file. My end goal is to make a new Plug-in Filter
> for an archaic file type that many people would like to have.
> Any code would be appreciated, I am just having a problem getting
> started with Gimp development. I am using the Plug-in Template,
> Linux (Fedora Core 2), Developer and Base RPM's. I have compiled
> the sample plugin, and got it to list the layers, but I cannot
> identify the contents of the layer or the simply the layer type.
I am afraid there is no way for a plug-in to find out if a layer is a
text layer or even to access the text properties. You could perhaps
implement what you are trying to do using some internal knowledge
about text layer. Basically I could tell you how to do it but I'd have
to kill you afterwards ;)
If you could outline what information you need exactly, we could try to
come up with an API that allows you to do this in a proper way. Having
access to the text layers has been requested before so I think we
should add this for GIMP 2.4.
Gimp-developer mailing list