Overriding the pre-defined function and make change AbsoluteLayout

Hi All,

I am designing a theme. The problem I am facing is I have to make change in AbsoluteLayout on one single page.
when I use below code:
.v-absolutelayout{
left: 15%;
}
It changes all the AbsoluteLayout. And if I use below code:

.v-dashabsolutelayout{
left: 15%;
}

and attached it to the particular AbsoluteLayout the particular AbsoluteLayout looses it’s property.

How I can override pre-defined properties of AbsoluteLayout and add my requirment (left: 15%) and attched to just one AbsoluteLayout?

Thanks for the help in advance.

Hello,

You can add a class name to that particular AbsoluteLayout, and set the style for that class in your theme.

Java

AbsoluteLayout al = new AbsoluteLayout();
al.addStyleName("custom");

(S)CSS

.v-absolutelayout.custom {
 ..
}