On 10/07/2011 10:09 AM, Tommaso Cucinotta wrote:
Hi all,
in the recently added Export As... dialog, we need to enumerate the
possible export formats for the current LyX document.
Originally I had thought this was achievable by checking the
Format::document()
method, however it was returning true also for XLS, ODS, CSV and other
formats for which I cannot see immediately how they could possibly be
the target of an export operation for a LyX document (see the attached
file formats-document.txt)
Therefore, recently I restricted the selectable formats to be the ones
for which
both "document" and "menu=export" is set (see the attached
formats-menu-export.txt)
file. However, I suspect to have lost some useful export possibilities
here, as shown
by the diff between the two attachments (see [1] below).
What is the right way to know which are the right formats to propose ?
I'd like to avoid to hard-code skipping of xls, ods, csv and fax in
the code of course :-).
Try using BufferParams::exportableFormats().
rh