Reputation: 1046
I started messing with SmartGWT the other day, but ive stumbled in this ridiculous spot.. This is a question that the documentation should respond, but i havent found any simple and straightforward solution. What i want: add 5px to the left margin of a Hlayout. I tried the method setMargin(), but it applies margins to the 4 margins. Since i just want the left one, i was left with the option to use the this.setStyleName(), which leads me to the problem.
How should i go about it? is there a master css file that i have to edit? should i create a custom css file and put there my customizations? where should it be saved?
I tried the solution given here, but it doesnt seem to work for me. am using smartgwt v.2.5
Upvotes: 1
Views: 1406
Reputation: 2059
There are no special restrictions with CSS and SmartGWT. You can put an inline <style> in your host .html, link a stylesheet from there, etc.
There is also no need to modify a skin in order to add or customize styles, but if you do want to create a custom skin, see the instructions in the QuickStart Guide, Extending SmartGWT chapter.
Finally you don't need CSS to do this anyway since there is a dedicated Layout.setLayoutLeftMargin() for setting the left margin.
Upvotes: 1