Hi Tracy,
I dont know if you notice this but if you disable your combobox 
(enabled=false). the colour changes slightly. due to the 'grey' of a 
disabled combobox.
Do you have any ideas how i can change this disabled grey to a white.

thanks
bod 




--- In flexcoders@yahoogroups.com, "Tracy Spratt" <[EMAIL PROTECTED]> 
wrote:
> Never mind, I made my changes a little more slowly and found my 
red!
> 
> -----Original Message-----
> From: Tracy Spratt [mailto:[EMAIL PROTECTED] 
> Sent: Thursday, February 24, 2005 11:06 PM
> To: flexcoders@yahoogroups.com
> Subject: RE: [flexcoders] Re: ComboBox color ?
> 
> 
> Well I used this and it works fine, but the color is purple, I 
want red,
> and I am clueless how to set all those properties, even after I 
looked
> in the docs.
> 
> Red offset?? What the heck is that?
> 
> I tried changing things at random and managed to blow away the down
> arrow completely.
> 
> Will someone tell me what I need to do to get a "red" background? 
Right
> now I'd take any shade!
> 
> Tracy
> 
> -----Original Message-----
> From: r0main [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, January 18, 2005 8:59 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: ComboBox color ?
> 
> 
> 
> Yope, here it is, looks like:
> 
> class com.r0main.EnhancedComboBox extends mx.controls.ComboBox {
> ...
> private function changeState() {
> var colorTransform:Object = { ra: 70, rb: 0, ga: 70, gb: 0, 
ba:
> 100,
> bb: 0, aa: 70, ab: 0};
> var bg_color:Color = new Color(downArrow_mc);
> bg_color.setTransform(colorTransform);
> }
> 
> private function restoreState() {
> var colorTransform:Object = { ra: 100, rb: 0, ga: 100, gb: 0,
> ba:
> 100, bb: 0, aa: 100, ab: 0};
> var bg_color:Color = new Color(downArrow_mc);
> bg_color.setTransform(colorTransform);
> }
> ...
> }
> 
> 
> r0main
> 
> --- In flexcoders@yahoogroups.com, "Alistair McLeod" <[EMAIL PROTECTED]>
> wrote:
> > Ah, I did see that movieclip but assumed that it was the down 
arrow
> only, so
> > didn't even bother checking it.
> > 
> > If possible, it might be an idea if you could post your solution 
for
> future
> > reference for others.
> > 
> > Cheers,
> > 
> > Ali
> > 
> > 
> > --
> > Alistair McLeod
> > Development Director
> > iteration::two
> > [EMAIL PROTECTED]
> > 
> > Office: +44 (0)131 338 6108
> > Mobile: +44 (0)7976 987252
> > 
> > This e-mail and any associated attachments transmitted with it 
may
> contain
> > confidential information and must not be copied, or disclosed, or
> used by
> > anyone other than the intended recipient(s). If you are not the
> intended
> > recipient(s) please destroy this e-mail, and any copies of it,
> immediately.
> > 
> > Please also note that while software systems have been used to 
try
> to ensure
> > that this e-mail has been swept for viruses, iteration::two do 
not
> accept
> > responsibility for any damage or loss caused in respect of any 
viruses
> > transmitted by the e-mail. Please ensure your own checks are 
carried
> out
> > before any attachments are opened.
> > 
> > 
> > -----Original Message-----
> > From: r0main [mailto:[EMAIL PROTECTED] 
> > Sent: 18 January 2005 12:49
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Re: ComboBox color ?
> > 
> > 
> > 
> > Thanks Alistair,
> > using your idea I started to look at movieClips used by the 
ComboBox
> > component, and found that "downArrow_mc" represents the whole 
closed
> > uneditable box, ie using setTransform I can change the box 
color !
> > 
> > Thanks a lot, r0main
> > 
> > --- In flexcoders@yahoogroups.com, "Alistair McLeod" 
<[EMAIL PROTECTED]>
> wrote:
> > > Hi r0main,
> > > 
> > > Not really an answer, but perhaps a pointer for you (or MM) to
> > investigate).
> > > If the combo box is editable, then backgroundColor can be set; 
as
> > soon as
> > > editable is false, changing the style seems to have no effect. 
Eg,
> try:
> > > 
> > > <?xml version="1.0" encoding="utf-8"?> <mx:Application 
> > > xmlns:mx="http://www.macromedia.com/2003/mxml";>
> > > 
> > > <mx:ComboBox id="combo" editable="true"
> backgroundColor="#0000ff"
> > > dataProvider="{ [ 'a', 'b' ] }" />
> > > 
> > > </mx:Application>
> > > 
> > > When I looked into this a bit last year, I played about with 
setting
> > color
> > > styles on the combo box's textField property (the display part 
of
> > the combo)
> > > and even text_mc (the physical TextInput exposed as 
textField), and
> > although
> > > it works slightly differently, still doesn't do anything when 
the
> > combo is
> > > not editable:
> > > 
> > > <?xml version="1.0" encoding="utf-8"?> <mx:Application 
> > > xmlns:mx="http://www.macromedia.com/2003/mxml";>
> > > 
> > > <mx:ComboBox id="combo" editable="true"
> > > creationComplete="combo.textField.setStyle( 'backgroundColor',
> > '#0000ff' );"
> > > dataProvider="{ [ 'a', 'b' ] }" />
> > > 
> > > </mx:Application>
> > > 
> > > The ability to set the background color wasn't really needed by
> us, so 
> > > I didn't investigate long.
> > > 
> > > Let us know if you get any further :)
> > > 
> > > Ali
> > > 
> > > 
> > > --
> > > Alistair McLeod
> > > Development Director
> > > iteration::two
> > > [EMAIL PROTECTED]
> > > 
> > > Office: +44 (0)131 338 6108
> > > Mobile: +44 (0)7976 987252
> > > 
> > > This e-mail and any associated attachments transmitted with it 
may
> > contain
> > > confidential information and must not be copied, or disclosed, 
or
> > used by
> > > anyone other than the intended recipient(s). If you are not 
the 
> > > intended
> > > recipient(s) please destroy this e-mail, and any copies of it,
> > immediately.
> > > 
> > > Please also note that while software systems have been used to 
try
> > to ensure
> > > that this e-mail has been swept for viruses, iteration::two do 
not
> > accept
> > > responsibility for any damage or loss caused in respect of any
> viruses 
> > > transmitted by the e-mail. Please ensure your own checks are 
carried
> 
> > > out before any attachments are opened.
> > > 
> > > 
> > > -----Original Message-----
> > > From: r0main [mailto:[EMAIL PROTECTED]
> > > Sent: 18 January 2005 10:57
> > > To: flexcoders@yahoogroups.com
> > > Subject: [flexcoders] ComboBox color ?
> > > 
> > > 
> > > 
> > > Hi,
> > > I'd like to change the "main" color of a comboBox, ie the
> "background"
> > > color of the box when it is closed.
> > > Any working idea ?
> > > 
> > > thanks, r0main
> > > 
> > > 
> > > 
> > > 
> > > 
> > > 
> > > Yahoo! Groups Links
> > 
> > 
> > 
> > 
> > 
> > 
> > Yahoo! Groups Links
> 
> 
> 
> 
> 
> 
> Yahoo! Groups Links
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Yahoo! Groups Links





Reply via email to