We can't sign OOXML and PDF documents with GPG, only ODF. So we should show GPG keys only if we are working with an ODF doc.
ODF >= 1.2, to be precise
Samuel Mehrbrodt committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=e2378bbf4539455e445205ad868c43246ec423ed tdf#108711 GPG key selection should only be possible for ODF >= 1.2 documents It will be available in 6.0.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Samuel Mehrbrodt committed a patch related to this issue. It has been pushed to "libreoffice-5-4": http://cgit.freedesktop.org/libreoffice/core/commit/?id=8b9f00fced21014bed6695b962084c8af0249dbc&h=libreoffice-5-4 tdf#108711 GPG key selection should only be possible for ODF >= 1.2 documents It will be available in 5.4.0.2. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.