I noticed that the program title displayed in the command window of the program node is “inserted” in the HTML by Polyscope even without having any placeholder tag in the program node HTML file, using the value returned by Get Title.
I want to use an image instead of plain text as a title, but if I set the return value of getTitle to an empty string to save that space, the button to create a new node also gets empty:
Is there a way to remove the title and replace it with a label with an image, but without erasing the button name?
This worked for me, in the getTitle() of the ProgramNodeService add this: String myLogo = getClass().getResource("/com/ur/urcap/my_urcap/impl/my_logo_image.png").toString(); return "<html><table cellpadding=0><tr><td><img src='" + myLogo + "'></td></tr></table></html>";
Cool, thanks @r4p! Worked for me too
I had to adjust the image a bit so as to fit the button. I think it’s acceptable, although it would be great to be able to adjust the sizes for the button and the title independently… maybe this could be a feature request?
Generally, UR would like to refer to using a String as a title for various nodes, both in Installation and Program.
This is the same behavior as any other node in PolyScope, and UR would encourage, that URCap nodes mimic the same look and feel as other PolyScope nodes.
Note that Toolbars in e-Series by default must supply a logo / icon for selecting their toolbar from the toolbar-menu.