Diagrams generated by Plugin gets published with cutoff content

I have created a Plugin that, by using Plugin.bat, takes external Data and generates some Diagrams. I then want to publish those Diagrams using ProjectPublisher.bat. If i were to export those Diagrams as Images with ExportDiagramImage.bat everything works fine, but on the html page of the diagrams created by ProjectPublisher parts of the diagram are cut off by the rim and not visible. The only way i found to circumvent this problem is manually opening every diagram generated by hand (which cannot be done using Commandline), before publishing the project. Using API to open the diagrams
IDiagramUIModel generatedDiagram=…;
does not fix the problem.

May I know what is the version and build number of VP application you now using? You can find them in the Help > About dialog.

Version 17.1 BuildNr 20231203