_focusrect Color?
Is there way to change _focusrect color. By default the color of the focus rectangle around the button (when it is selected using the keyboard)is yellow. Please let me know if you have ideas.
Thanks
FlashKit > Flash Help > Flash ActionScript
Posted on: 10-21-2003, 12:26 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Change Color Of _focusrect?
Does anyone know how to change the color of the _focusrect? I want to make i the same color as my background to in effect make it appear like it's off.
I tried disabling it, but that turns off the arrow key navigation. I don't know why Macromedia tied the arrow navigation to the visibility of the _focusrect.
_focusrect
Hello,
can someone give me a practical example of "_focusrect" property,
in *.fla file,
tnx
V.
_focusrect
Anyone know how to solve the _focusrect and enter button problem?
when _focusrect is disabled, Enter does not work. I want to set up tabbing without the focusrect rectangle.
AM using this to disable focusrect:
_focusrect = false;
Thanks for any help.
_focusrect Problem
hiya
i'm trying to use the _focusrect property to set a yellow box around a MC on the stage like this:
on (release) {
setProperty("mc1", _focusrect, true);
}
yet nothing happens..can someone tell me what i'm doing wrong? thanks.
_focusrect Problem
I have a couple of buttons which I want to be able to TAB through. Normally when I select a button with the TAB button, I can press ENTER to execute the button's actions. However......... when I disable the focus rectangle, I can still TAB through them, but for some reason I can't execute their actions by tapping ENTER anymore....
this is the code I used:
buttonOne._focusrect = false;
buttonTwo._focusrect = false;
Anyone have an idea as to how to fix this?
Thanks in advance :-)
Skinning _focusrect?
I want to get rid of the yellow focus rectangle but I can't use _focusrect = false. Does anyone know if it's possible to skin the rectangle?
MX2004 - _focusrect (?) Problem.
I have a form application (A) that loads another form application (B)into one of its (A's) forms. This works fine except that the components in B suddenly start to get a green box around them when they have the focus. This doesn't happen when B is run by itself (i.e. not loaded into another form). I have tried setting _focusrect to false for all scopes from _global on up, but with no success. I have used trace statements to output the value of _focusrect for my components at runtime, and they all say component._focusrect = false, despite the fact that there is a green rectangle around the component.
Is this a _focusrect thing, or is it a Halo thing, or something else? Regardless of what it is, how do I get rid of it?
Thanks.
-Brian
MX2004 - _focusrect (?) Problem. Please Help.
This is my second posting regarding this problem. I have not been able to find a solution anywhere, although I have encountered others who have the same problem. Any help, even just suggestions on things to try, would be welcome.
MX2004 - _focusrect (?) problem.
I have a form application (A) that loads another form application (B) into one of its (A's) forms. This works fine except that the components in B suddenly start to get a green box around them when they have the focus. This doesn't happen when B is run by itself (i.e. not loaded into another form). I have tried setting _focusrect to false for all scopes from _global on up, but with no success. I have used trace statements to output the value of _focusrect for my components at runtime, and they all say component._focusrect = false, despite the fact that there is a green rectangle around the component. I know that _focusrect is supposed to put a yellow rectangle around things, but this one is green, and I thought perhaps MX2004 had changed the color to match the Halo theme.
Is this a _focusrect thing, or is it a Halo thing, or something else? Regardless of what it is, how do I get rid of it?
Thanks.
-Brian
MyTextArea._focusrect = False;
Hello
I am using Flash MX 2004, and I have a main.swf file that on button click targets a certain frame of a movieclip that loads in an external .swf file into level 1 that has a text area component that in turn loads in a xml file styled with css.
All that works fine. The problem is that when I click the scrollbar of the text area component that I am loading the xml file into a green rectangle appears around the text area.
I used this:
Code:
myTextArea._focusrect = false;
That gets rid of it the first time, but if I return to it again, or to any other textArea in the movie it shows the greeen rectangle again.
They all will work the first time but none will work the second time. Is there anyway to get rid of the green border?
Thanks
Johnny
Plzzz Urgent>> Scroll Bar's _focusrect
hii all
using flash mx 2004. i am using scrollPane for calling swf files and at a certain point in that scrollPane i have to click a button whic opens a mc above that scrollPane. The Problem is that the only focus rectangle of scrollPane is still above the mc which i am calling. i tried but can't solve it. i have to submit that file please help
[Flash CS3 AS2] Help With _focusrect For Input Field
Hello,
I have input field that shows yellow background when using TAB keyboard key. I need to disable that. I tried the code "_focusrect=false;" but it doesn't work. My input fields are not in a movie clip.
Thanks in advance!
AS 2 Hope It Is A Flash Bug(): _focusrect=false Not Working
Hi all,
I met a problem while using some input boxes along with an image loader component in an application. The actual problem is while tabbing between input texts I can see the focus rectangle around the current focused text box. This is happening only when I add any UI Components into the application. More over even I delete the component from the stage and if I have it in the library, I can't control the focus rectangle.
Solutions and explanations over this problem are most welcome!!
I've attached the .swfs here for better understanding my problem.
Thanks in advance,
cheers,
|k|o|s|a|
AS 2 Hope It Is A Flash Bug: _focusrect=false Not Working
Hi all,
I met a problem while using some input boxes along with an image loader component in an application. The actual problem is while tabbing between input texts I can see the focus rectangle around the current focused text box. This is happening only when I add any UI Components into the application. More over even I delete the component from the stage and if I have it in the library, I can't control the focus rectangle.
Solutions and explanations over this problem are most welcome!!
I've attached the swfs here for better understanding my problem.
How To Change MovieClip RollOver Color(NOT Single Color, But Gradient) Dynamically ?
hi
I have created this for single color.But how to change when it is a gradient color.
for single color rollover code.
Code:
rollcolor = "0xFF0000";
normalcolor = "0x339900";
my_color = new Color(my_mc);
my_mc.onRollOver = function() {
my_color.setRGB(rollcolor);
};
my_mc.onRollOut = function() {
my_color.setRGB(normalcolor);
};
Thanks in advance
How To Change MovieClip RollOver Color(NOT Single Color, But Gradient) Dynamically ?
hi
I have created this for single color.But how to change when it is a gradient color.
for single color rollover code.
ActionScript Code:
rollcolor = "0xFF0000";
normalcolor = "0x339900";
my_color = new Color(my_mc);
my_mc.onRollOver = function() {
my_color.setRGB(rollcolor);
};
my_mc.onRollOut = function() {
my_color.setRGB(normalcolor);
};
Thanks in advance
Changing Fill Color And Line Color Dynamicly And Seperately
Hi community,
In this case, I am going to load a swf with a looping animation colored in black and white only. I want to change the color of the animation dynamicly so that I could have different color at each time. Here is my code:
Code:
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
<mx:Script>
<![CDATA[
import flash.display.*;
import flash.net.URLRequest;
private function init():void{
myCan.addEventListener(Event.ENTER_FRAME,capMotion);
}
private function capMotion(event:Event):void{
var bmd1:BitmapData = new BitmapData(mySwf.width, mySwf.height, true, 0x00CCCCCC);
bmd1.draw(mySwf);
var bitmap1:Bitmap = new Bitmap(bmd1);
bitmap1.x = 0;
bitmap1.name="org";
if (map.getChildByName("org") != null){
map.removeChild(map.getChildByName("org"));
}
map.addChild(bitmap1);
var bmd2:BitmapData = new BitmapData(mySwf.width, mySwf.height, true, 0xFFFFFFFF);
var pt:Point = new Point(0, 0);
var rect:Rectangle = new Rectangle(0, 0, mySwf.width, mySwf.height);
var threshold:uint = 0xFF999999;
var color:uint = 0xFFFFFF00;
var maskColor:uint = 0x00FF0000;
bmd2.threshold(bmd1, rect, pt, ">=", threshold, color, maskColor, true);
var bmd3:BitmapData = new BitmapData(mySwf.width, mySwf.height, true, 0xFFFFFFFF);
threshold = 0xFF000000;
color = 0xFF00CCCC;
maskColor = 0xFFFFFF00;
bmd3.threshold(bmd2, rect, pt, "==", threshold, color, maskColor, true);
var bitmap2:Bitmap = new Bitmap(bmd3);
bitmap2.name="dup";
bitmap2.x = bitmap1.x + bitmap1.width + 10;
if (map.getChildByName("dup") != null){
map.removeChild(map.getChildByName("dup"));
}
map.addChild(bitmap2);
}
]]>
</mx:Script>
<mx:Canvas id="myCan" x="10" y="10" width="650" height="603">
<mx:SWFLoader id="mySwf" width="100" height="250" horizontalCenter="0" verticalCenter="-7.5" source="dance.swf" complete="init()" scaleContent="false" autoLoad="true"/>
<mx:Image x="61" y="320" width="550" height="152" id="map"/>
</mx:Canvas>
</mx:Application>
It works quite fine but I afraid that it's quite resource consuming using enterframe and bitmap drawing. Is there any better method?
Thanks for help.
How Would I Go Changing Lots Of Movieclips Color And Border Color Seperatly?
I am in the making of a isometric level editor, and I have about 15 movie clips with more to come.
I want to let people change the color of tiles to what they want from a list of colors, so how can I let them change the color of a tile dinamicly with actionscript so that it changes a tile's color while preserving changes of "shadows"?
I mean I have let's say a cube and to make it look 3D I need to change each face to make a feeling of 3D and not a flat one.
thanks.
Text Color And Background Color Setting Dynamically
How would I go about setting the background color of a flash movie as well as the text color of a text box based an external variable?
I want to pass in both of these colors in the <object> tag
myfile.swf?bgcolor=red&textcolor=white
Please advise.
Thanks
Robert
Changing Color On RollOut Then Back To Color After 2 Seconds
I am using the code below to make a shape turn color using on rollOver, then on rollOut is changes to a differant color(blue), then I want it to change back to the first color(white), either on another rollover or I perfer to make it change back to the fist color after a 2 seconds,
on (rollOver) {
var colorful = new Color("_root.shapes");
colorful.setRGB(0x006699);
}
on (rollOut) {
var colorful = new Color("_root.shapes");
colorful.setRGB(0x006688);
I want to be able to rollOver change color, onRollOut Change color again, then back to the first static color after 2 seconds.
Anyhelp would be great Thanks
Drag And Drop Color Swatches To Color Target
Hi there,
Need some help with this. I want to have color swatches that can be individually dragged onto a target MC and have that target MC take the color of the color swatch that has been dragged onto it. This procedure should be able to be done over and over again so a new color can replace the old one. I am working in Flash MX 6. Any help would really be appreciated.
Thanks so much.
Hex Color Code To Change Movie Clip Color
Hi all, Sorry real quick,
i've got a text box with the text with a hex code from a color picker which reads say "FF0000" how do i use that hex code(FF0000) to change a movie clips color.
simple (me stupid)....
thxs for any help
jon
[CS3] Changing Color (and Opacity Of That Color) Of Movie Clip
Hi. I have a pretty large movie clip filled with pngs. It's a sprite for a game and I want to change it's color. The setRGB method works, but I can't figure out how to set the opacity of the color. I don't want to change the alpha of the movie clip itself, just the color I'm applying to it so that it's just a shade over the normal images.
Is there any way to do this?
Assign Color To New Sprite In Order Of Color Wheel?
Is there a way to know the offset from one color to the next?
For example, I would like to create Sprite Balls, and have each be assigned a new color. But, I don't want it to be completely random color. I'd like it to be in order of the color chart slightly.
So if the first color is Red lets say, the next color would be a Yellow, then Green, then Aqua, then Blue, then Magenta, and back to Red. They don't need to be the absolute color, but in the general vicinity. Is this possible to do dynamically? What would the multiplier need to be to get to the next grouping of colors?
Drag And Drop Color Swatches To Color Target
Hi,
I am trying to have color swatches that can be individually dragged onto a colorless mc and have the mc adopt that color. This should be able to be replaced over and over again with new colors and reset to start again. I have only been able to find information on swopping mc's.
PLEASE HELP WITH THIS AS I AM STUMPED.http://www.jupiter.co.za/smart.jpg
THANKS SO MUCH
Fill Color And Stroke Color Option Not Working...
I am a faculty member at American River College who needs a word or two on how Flash CS3 works.
Specifically, how do I get back the option to add fill color to an oval drawing that I have made in Flash CS3? It appears that I have flipped a setting that makes that seemingly simple option unavailable.
I have several other documents where I have added fill color without a problem; however, as of this morning CS3 will not allow me do add such. When I open Flash, I draw on the Stage, the outline color is usually green, no matter what color I select for as Stroke Color and Flash will not allow me to change the Fill Color. I make a selection and nothing happens (just moments ago I opted for red as the Fill Color and the Fill remains white).
Is there a setting in Flash, that a rookie like yours truly could activated by accident?
Please help.
MacBrowne
Return MC To Original Color After Dynamic Color Change
How is it done? All I've seen on the web is how to change the color. Well how about going back. I'm talking about a MC with many colors. I can't just change back to a single hexadecimal color.
I can accomplish the change as it passes over a frame, but I can't get it to change back.
In the frame is this:
ActionScript Code:
cHurtColor = new Color(_root.compMC);cHurtColor.setRGB(0x00FF33);
Trying to keep this simple....
Return MC To Original Color After Dynamic Color Change
How is it done? All I've seen on the web is how to change the color. Well how about going back. I'm talking about a MC with many colors. I can't just change back to a single hexadecimal color.
I can accomplish the change as it passes over a frame, but I can't get it to change back.
In the frame is this:
ActionScript Code:
cHurtColor = new Color(_root.compMC);cHurtColor.setRGB(0x00FF33);
Trying to keep this simple....
Color.setTransform(colorTransf) >>> Color Question
These are the codes I´m using on my mc (target)
onClipEvent (load) {
color = new Color(this);
colorTransf = new Object();
colorTransf.ra = 0;
colorTransf.ga = 0;
colorTransf.ba = 0;
}
onClipEvent (enterFrame) {
Rdif += red - colorTransf.rb;
Gdif += green - colorTransf.gb;
Bdif += blue - colorTransf.bb;
colorTransf.rb += Rdif / 4;
colorTransf.gb += Gdif / 4;
colorTransf.bb += Bdif / 4;
color.setTransform(colorTransf);
}
I´m trying to understand it...
1.0 I can´t get the "new Object()" What am I doing with this???
2.0 Why I set on (load) ra; ga; ba and then on (enterFrame) I use rb; gb; bb???
3.0 What exactly does the setTransform() do?
The rest I understand well...
Hope it´s not complex for explain.
Thanks!
Dynamic Color Slider Or Color Wheel ?
can someone help, or direct me to a tuttorial on
¥ user input to adjust/select color
- must be RGB sliders, or colorwheel/color bar to choos from
I need the user to be able to change the background color of a graphic, without them knowing anythign about color.
so it would be best if they could just adjust RGB sliders or pick from a color wheel would be even bettter. . .
thanks
Darin
P.S.
I could make a bunch of buttons with a few basic predefined colors, however this would be limmiting in selection.
Matching Bg Color To Surrounding Jpeg Color
I'm putting a flash movie into a space that's surrounded by a deep blue gif color. Nothing fancy - no gradient - just a plain, old, single color that matches out to a hex value of 333399.
When I set the Flash movie's background to 333399 and place it within HTML page, the colors don't match. I've fooled around with different hex combinations in flash and have finally found a combination that matches the blue gif background almost exactly (#294099) - but man, what a hassle!
There must be a better way to match a flash movie's background to a background that it will be placed within...isn't there? Please advise if there is...
Thanks to all in advance.
Hummm...one more thought, is there a way to export a movie with a transparent background???
Matching HTML Color To Flash Color
How come when I set #336699 to my HTML page background and also #336699 to my flash .swf background. I put the swf into the page and I could see the difference between the two colors!!!! How do I fix this?
To Show Color Default, Or Color Param.
I´m trying to do this, I have a dynamic text and in this dynamic text I call a value, in my HTML I have a PARAM color, he change the color of my dynamic text, so far works fine, but I have 4 products, and each product I have a especific value, example: in product 2 I wanna change de color of my value, my problem is I cann´t change this color.
In my HTML I have the PARAM " cp=006699 " it is the color of the values of the 4 products, 1 default color for the 4 values of my 4 products, but I would like to change the color of my 2º product, some special color " cp2=330099 ", and so on.
HTML
Code:
arquivo.swf?cp=006699&cp2=330099........
my AS.
code:
//alterar cor dos preços dos produtos 2 = cp2
if (cp != undefined) {
new Color (preco2_2_mc.preco2_mc).setRGB (parseInt (cp, 16));
}
else {
new Color (preco2_2_mc.preco2_mc).setRGB (parseInt (cp2, 16));
}
Sorry about my English.
[F8] Color Swatch Or Change - Color Object?
You know how on retail sites or even a car site you can swap the color by clicking on the swatch and than the image changes the color. I wanted to do this in flash preferably with actionscripting but I have NO CLUE how to do it. Can anyone show me a tutorial or advise me o how to do this. This is just a BASIC example in flash five but this is the same concept I want. http://www.adobe.com/support/flash/i...y/colorobject/ If anyone knows of a high level example with tutorial I would appreciate it.
Turtle
To Show Color Default, Or Color Param.
I´m trying to do this, I have a dynamic text and in this dynamic text I call a value, in my HTML I have a PARAM color, he change the color of my dynamic text, so far works fine, but I have 4 products, and each product I have a especific value, example: in product 2 I wanna change de color of my value, my problem is I cann´t change this color.
In my HTML I have the PARAM " cp=006699 " it is the color of the values of the 4 products, 1 default color for the 4 values of my 4 products, but I would like to change the color of my 2º product, some special color " cp2=330099 ", and so on.
HTML
Code:
arquivo.swf?cp=006699&cp2=330099........
my AS.
ActionScript Code:
//alterar cor dos preços dos produtos 2 = cp2
if (cp != undefined) {
new Color (preco2_2_mc.preco2_mc).setRGB (parseInt (cp, 16));
}
else {
new Color (preco2_2_mc.preco2_mc).setRGB (parseInt (cp2, 16));
}
Sorry about my English.
Color Burn/ Color Dodge In FLASH?
Check out two these links:
http://www.podlob.com/flash/template...0&quality=HIGH
http://www.podlob.com/flash/template...20&quality=LOW
Does anyone know how to create that burn and dodge technique in flash? I've been seeing this effect a lot lately.
-Thai
Random Color + Change Color With AS With Ease
HI,
I followed this tutorial , but I´d like to add something more but don´t know how.
I[d like to make the MC to load a random color, in a color range that I specify, like #000000, #FFFFFF and #111111.
Also, I want somew buttons to change between this colors, but with an ease transition.
How can I do this?
Drag Color And Change Objects Color
i looked at the kirupa's paint tutorial and it really didn't achieve the effect that i'm going for. i'm new to actionscript so i can't figure it out for myself, so i'm hoping someone can shed some light on the situation for me.
here is the setup: i have an object that i rendered in 3d studio max. will just call it a box. i have rendered that box in 3 different colors. red, yellow, and blue. i saved them each individually as targa files and imported them into flash. i created a movie with 3 frames. frame one contains the red box image, frame 2 contains the yellow box, and frame 3 contains the blue box. each frame has the stop command applied to it.
now on the main timeline, i have 3 different circles that have been converted to buttons each colored red, yellow and blue. now i can use a "tellTarget" type action to make the playhead on the box movie clip to jump to the corresponding colored circle that was clicked, but i'd rather let the user be able to drag the colored circle to that box, release, and change the box to the color that corresponds to that circle. i don't know if that requires some type of collision detection script or not. the box has no background so all there is, is the box itself so collision detection should just detect the box itself...right??
i would appreciate any insight that you could give me!!! if need be, i can supply a *.fla file for you to look at.
Color Mask? Or Setting Color Of A PNG Bitmap?
I made a movie clip of a sequence of outer glow effects in PhotoShop to give the effect of a pulsating halo. I made the clip seperate from the beveled graphic it surounds so I could mask it. I want to have it pulsating between colors as it expands and contracts. I made the halo white, not anticipating that there would be any great difficulty in masking or changing its color.
So my question is, how do you make a color mask? I can only seem to get alpha masks, it completely ignores the color of the masks I make and lets through all colors, no matter the color of the mask.
Or alternately, is there a why to alter the color of all the pixels in a PNG bitmap, so that the varying transparancy/alpha of different pixels is preserved but the color is uniformly changed?
Tween Color Class Not The Color I Expected
Here is the code for a gallery slide show I'm working on.
What I'm wanting is the background to change color with each gallery. To tween over a few seconds. I have not included the gallery images. Sorry
I don't understand why the colors are so different from the what the hexadecimal colors I intended.
B2C3D0
598479
D16546
You have to go to the gallery button to see what I'm getting at.
Thanks for your help
kiwiupover
http://www.missionadventures.co.nz/k...er/gallery.fla
babyPic.onRelease = function() {
_parent._parent._parent.gotoAndPlay("galleryBaby") ;
var colour:Color = new Color(_parent._parent._parent.galleryBack);
colour.getRGB(_parent._parent._parent.galleryBack) ;
var trans:Object = colour.getTransform();
var rb:Tween = new Tween(trans, "rb", Strong.easeOut, trans.rb, 0xB2, 3, true);
var gb:Tween = new Tween(trans, "gb", Strong.easeOut, trans.gb, 0xC3, 3, true);
var bb:Tween = new Tween(trans, "bb", Strong.easeOut, trans.bb, 0xD0, 3, true);
rb.onMotionChanged = function():Void {
colour.setTransform(trans)
};
};
To Show Color Default, Or Color Param.
I´m trying to do this, I have a dynamic text and in this dynamic text I call a value, in my HTML I have a PARAM color, he change the color of my dynamic text, so far works fine, but I have 4 products, and each product I have a especific value, example: in product 2 I wanna change de color of my value, my problem is I cann´t change this color.
In my HTML I have the PARAM " cp=006699 " it is the color of the values of the 4 products, 1 default color for the 4 values of my 4 products, but I would like to change the color of my 2º product, some special color " cp2=330099 ", and so on.
HTML
Code:
arquivo.swf?cp=006699&cp2=330099........
my AS.
ActionScript Code:
//alterar cor dos preços dos produtos 2 = cp2if (cp != undefined) { new Color (preco2_2_mc.preco2_mc).setRGB (parseInt (cp, 16));}else { new Color (preco2_2_mc.preco2_mc).setRGB (parseInt (cp2, 16));}
Sorry about my English.
|