Is anybody able to teach me how to add a style to my personal theme ?

Hi all,

I spent hours today on creating my personal theme.

I just wanted to add a style to align the text of my TexyFields to the right.

Well, I read the istructions to add the style in my theme and then…nothing worked.
I am really tired so I need help :slight_smile:
This is my code :


File styles.scss

@import “addons.scss”;
@import “mytheme.scss”;

.testtheme {
@include addons;
@include mytheme;
}


File mytheme.css

@import “…/reindeer/reindeer.scss”;
@mixin mytheme {
@include reindeer;

.v-textfield.numerical { text-align: right; }
}

File addons.scss

@mixin addons {
}

I specified in my application class @Theme(“mytheme”) and the only result I got was my application without any Theme.
Any suggestion or example ?
Cheers.

                   Stefano

I do not know if this is what you want.
But i am creating a custom theme at the moment as well.
If i want to have something changed, i will add a StyleName to my component with:

Component.setStyleName("align-right"); Then i will watch on my chrome css explorer via rightlick what is the full name of the css tag and then i add this to my css file.

For example something like:

.v-panel-align-right{ display: none;} Makes no sense =D

Hi Michael,

Thank you for the reply.
I’d need to align the text inside of a textfield to the right.
So, do you have an example to send me ?
I am getting mad…or almost :slight_smile:
Cheers.

        Stefano

Hi Michael,

I found the solution…it was a cache problem…!!!
I found a message in a forum about my same issue.
It seems that I must do the following things :

  • stop Tomcat from NetBeans
  • Build my application
  • restart Tomcat
  • disabling Chrome cache

In this way my theme is correcly displayed.
Another solution could be install JRebel, but it is not free :frowning:
Cheers.

               Stefano