LibreOffice
LibreOffice (using Linux)
using Linux a certificate manager like "kleopatra", "seahorse", "gpa" or "kgpg" is needed
. open libreoffice (e.g. "Writer" for text document)
create the document (do not forget to save before going on with signing)
the signing menu opens now
now the window where you can choose the certificate/keypair opens
the windows in the baqckground ca be closed using <Esc>
now the certificates are show for which valid information are stored in "kleopatra" (e.g. private key)
select the wanted certificate/keypair and add a short description if wanted/needed
and sign the document as final step
"Close" this last window at the end
the document shall now show a valid signature
close the document
Important note - do not save the file as the signature will be lost if doing so