Parameters to filters
Inge Wallin
inge at lysator.liu.se
Wed Aug 22 11:23:28 BST 2012
I would like to add the ability to parameters to filters. My usecase is that I
want the user to be able to specify a path to a book cover image (normally an
SVG file) and have the epub filter add that to the epub file.
I wonder if anybody else have thought about this and maybe even has a design
thought out already. The problem is slightly complex, involving at least the
following aspects:
- In the general case we can have a whole chain of filters and it's possible
that more than one filter wants an option with the same name. So we need to be
able to specify which filter should receive each parameter.
- We may want to send several different data types. I guess the most common
one would be a string or a number but in the general case it could be
anything. So I think a QVariant should be involved somewhere (but see below).
- We need some code in calligraconverter to parse command line options and
create parameters. This would speak against using anything but strings.
- We need to be able to create a UI using tools or general dockers so the
user can control the parameters from the applications. The values need then be
transferred to the filters somehow.
So, any good ideas?
More information about the calligra-devel
mailing list