fireburner69
Programmer
Hello,
I am trying to customize a list component and I really cannot do that.
My problem is that I have figure out that in some cases I can modify some setting of the comp and in others I cannot.
What I want to do is 4 things:
1. Set the background color of the comp to undefined or false so that it can be transparent.
2. Change the color of the scrollbar again to undefined or false.
3.Change the font size
4.Change the font weight.
Whan I am trying to do the last two it's easy enough:
list_comp.setStyle("fontWeight", "bold");
list_comp.setStyle("fontSize", "40");
*Where list_comp is the name of the list Component.
That is working 100% fine.
But in the case where I am trying to set up the bgcolor like that is not working:
list_comp.setStyle("backgroundColor", "false");
the same pro comes up when I am trying to change the scrollbar color.
After searching some days now I have found out this code that can do the work but again with some pros.
import mx.styles.CSSStyleDeclaration;
if (_global.styles.List == undefined) {
_global.styles.List = new CSSStyleDeclaration();
}
_global.styles.List.setStyle("backgroundColor", false);
_global.styles.List.setStyle("borderStyle", "none");
this will do the work but cause I am recreating the style of the list I am loosing all the extra info that has with the select and other stuff and the component does not work.
After some tracing I have seen that the Style is not defined in the begining!? Why is that? I mean I am using the list comp in the begining of the movie what is the problem?
And another problem is again with the textarea comp.
There I can modify the bgcolor but I can not modify the font size and the weight.?
'
What am I doing wrong?
Any good tutorials or tips about compo and customize ?
Thanks for your time!
I am trying to customize a list component and I really cannot do that.
My problem is that I have figure out that in some cases I can modify some setting of the comp and in others I cannot.
What I want to do is 4 things:
1. Set the background color of the comp to undefined or false so that it can be transparent.
2. Change the color of the scrollbar again to undefined or false.
3.Change the font size
4.Change the font weight.
Whan I am trying to do the last two it's easy enough:
list_comp.setStyle("fontWeight", "bold");
list_comp.setStyle("fontSize", "40");
*Where list_comp is the name of the list Component.
That is working 100% fine.
But in the case where I am trying to set up the bgcolor like that is not working:
list_comp.setStyle("backgroundColor", "false");
the same pro comes up when I am trying to change the scrollbar color.
After searching some days now I have found out this code that can do the work but again with some pros.
import mx.styles.CSSStyleDeclaration;
if (_global.styles.List == undefined) {
_global.styles.List = new CSSStyleDeclaration();
}
_global.styles.List.setStyle("backgroundColor", false);
_global.styles.List.setStyle("borderStyle", "none");
this will do the work but cause I am recreating the style of the list I am loosing all the extra info that has with the select and other stuff and the component does not work.
After some tracing I have seen that the Style is not defined in the begining!? Why is that? I mean I am using the list comp in the begining of the movie what is the problem?
And another problem is again with the textarea comp.
There I can modify the bgcolor but I can not modify the font size and the weight.?
'
What am I doing wrong?
Any good tutorials or tips about compo and customize ?
Thanks for your time!