the issue is very easy, but seems quite complicate;I've search on internet and try a lot but there is not way to find a solution for me!!
All I need is not having space between an icon and a text:
this is the code:
Label subTitle = new Label("nel cammin di nostra vita mi trovai in selva oscura");
Label stpIMG = null;
stpIMG = new Label();
stpIMG.setContentMode(ContentMode.HTML);
stpIMG.setValue("<img src=\"VAADIN/themes/valo/images/sprite_svg_all.svg#ristampa\">");
stpIMG.setWidth("30px");
stpIMG.setHeight("20px");
HorizontalLayout subTitleLayout=null;
subTitleLayout = new HorizontalLayout(stpIMG,subTitle);
subTitleLayout.setExpandRatio(stpIMG, 1);
subTitleLayout.setExpandRatio(subTitle, 2);
subTitleLayout.setWidth("650px");
subTitleLayout.setSpacing(false);
mainLayout.addComponents(subTitleLayout);
And is not easy to accomplish even if is so easy; What I'm wrong? thanks so much