Hiding Annotation (and other) buttons in WebViewer

I am hiding various annotations (and other) buttons from the WebViewer toolbar, from within the documentLoaded event in config.js.

I'm using jquery syntax such as the following:
$('#overflowToolsContainer span[data-toolmode=AnnotationCreateSignature]').hide();
$('#overflowToolsContainer span[data-toolmode=AnnotationCreatePolygon]').hide();
$('#overflowToolsContainer span[data-toolmode=AnnotationCreatePolyline]').hide();
$('#overflowToolsContainer span[data-toolmode=AnnotationCreateEllipse]').hide();

This is working fine, however, the buttons are initially visible within WebViewer for a split second, before they are removed.
Is there a way of hiding buttons on the toolbar, without them being displayed momentarily?

Note: for the Print button, I am setting the hidePrint property on ReaderControl.config.ui, and this works as expected without being displayed momentarily. Unfortunately, not all buttons, including annotation buttons, are supported using this technique.


Looks like this message was posted in the wrong forum. For WebViewer forum/KB is https://groups.google.com/forum/#!forum/pdfnet-webviewer