ActionScript 3.0 :: Text Format Not Changing Colour Or Size?

Apr 30, 2011

My Text Format is not changing colour or size, despite me telling it to do so with the following code. it displays the number of steps taken (a number called Steps) to complete the level in my flash game.

ActionScript Code:
var myFont:TextFormat = new TextFormat;
myFont.font = "Ariel";
myFont.color = 0xCCCCCC;

[Code]....

It displays the box the correct size (height and width), position and number inside, but the text font is still black and small size.

View 2 Replies


Similar Posts:


ActionScript 3.0 :: Text Format Size Not Changing Results?

Dec 8, 2010

The text shows up, but it needs to display bigger than it is.  It's showing up consistently at about size 10, no matter what I set the size to, even "size = 100" .

public function StimLetter(data:Object) {
// format
var format:TextFormat = new TextFormat();
format.font = "Verdana";

[Code].....

View 4 Replies

Flash :: Colour Format/Encoding Are These Colour Values In?

Oct 31, 2011

I am parsing colour codes that I get from a Flex(Flash ActionScript) application, then creating HTML div elements with that same colour. My Problem: The colours are all only 8 digits long. So they cant be RGB colour values can they? What color value format are they in? If I can figure the format they are in I can convert them to RGB. Maybe the last/first digit signifies its 0. alpha value?

PS: Should I convert the colours to RGB or something else?

This is an example of the colour code values I getting from the flash application:

View 1 Replies

ActionScript 3.0 :: Changing Text Colour Please?

Jul 15, 2011

I have a set of textfields created in a for loop and I want individual textfield text to change colour on mouse roll-over. I can't get it to work - it throws a 1009 null object reference error:

Code:
var textField = new TextField();
textField.x = 150;

[code]....

View 2 Replies

ActionScript 2.0 :: Changing Colour Of Text?

Sep 7, 2011

should be simple anyway . I'm using flash CS5 but have continued using AS2 because that is what I know how to use. Im trying to change the colour of a Dynamic text field in which the string is constantly changing. I am trying to use the code:

Code:
_root.textField1.textColor = 0xFF0000;to get change it from white to red, but it does not work. I am thinking it is maybe because in CS5 you have to embed fonts (I dont know how to do this!). If this is the case is there an easy way to embed a whole font with all colours etc?

View 7 Replies

ActionScript 3.0 :: Changing The Colour Of Text Inside A MC?

Sep 16, 2009

I am having trouble changing the text I've created inside a movieClip.Wha I do below is place a movieCLip from the library onto the stageI add an eventListenerThen I create a text field inside the movieClip and add some text from an arrayThen, when the user clicks the button I want to change the text colour but it keeps giving me an TypeError: Error #1010: A term is undefined and has no properties. (Where I commented the code with // ########)I can adjust the movieClip's position but I don't seem to be able to access anything inside it.

Code:
var createButtonArray:Array=new Array("BUT1","BUT2");
var len:Number=createButtonArray.length;

[code]....

View 3 Replies

ActionScript 2.0 :: [Flash8] Changing The Colour Of Text?

Sep 25, 2007

I'm trying to create a crossword puzzle, and I was wondering whether its would be possible to change its colour if the letter was right. For example if the right answer was C and C is entered in the box the letter goes green or something similar.

View 5 Replies

Professional :: Text Object - Changing Colour In Animation

Aug 19, 2011

I've created a text object, writing let's say "HELLO". I then made it into a picture, and erased parts of the text, all the while taking frame captures (F6). It ended up looking great, even though I had 900+ frames. However, I now want to change the font colour...in each of the frames. Any easy way to accomplish this, I cannot go frame by frame. The object is in the same place each time, so if I could just put a mask on all the frames or something to change the colour to black, that would be sweet. I followed this tutorial [URL].

View 4 Replies

ActionScript 2.0 :: Dynamic Colour Changing Text Links

Jul 18, 2006

i've recently been trying to think of a way to create dynamic color changing txt links.For example, say you have a list of static txt boxes in flash, each one being a link to a website, im trying to make it so that when you rollover a link, the txt would change colour. is it possible to achieve this effect using actionscript? As making each link a movie clip and tweening it would be very tiresome and time consuming.

View 1 Replies

ActionScript 3.0 :: Changing Format Of Text?

May 27, 2009

I have a textField inside a mc. When you roll over an event is triggered.

In the fuction I can do thisCode:event.currentTarget.getChildAt(0).text="fred";and the text changes - so its being targettedI want to change the format of the text so I thoughtCode:event.currentTarget.getChildAt(0).defaultTextFormat=mTitle_fmt;but, its doesn't work.it says "ReferenceError: Error #1037: Cannot assign to a method setTextFormat on flash.text.TextField.at index001_fla::MainTimeline/overHandler()"

View 5 Replies

ActionScript 3.0 :: Changing Colour Of A MC With A Colour Picker?

Aug 17, 2009

i have a background and i want to be able to change the colours of it using a colour picker... if the MC was to cover the whole stage... how could i then get a colour picker and make it so it would change to whatever colour i wanted from the colour picker?

View 5 Replies

ActionScript 3.0 :: Changing Format Of Text Inside MovieClip

May 27, 2009

I have a textField inside a mc. When you roll over an event is triggered. In the fuction I can do this:
Code:
event.currentTarget.getChildAt(0).text="fred";
And the text changes - so its being targeted. I want to change the format of the text so I thought.
Code:
event.currentTarget.getChildAt(0).defaultTextFormat=mTitle_fmt;
But, its doesn't work.

It says "ReferenceError: Error #1037: Cannot assign to a method setTextFormat on flash.text.TextField. at index001_fla::MainTimeline/overHandler()"

View 3 Replies

ActionScript 3.0 :: Changing Text Format According To Container Color?

Sep 26, 2010

on click on "elements" i'm dynamically generating coloured boxes (all instances of the same symbol) and the colour of these boxes is applied through a colortransform. in the box there is a textfield and i want the the text to be colored according to the box color. i mean, if the box is dark the text has to be white, and viceversa.

here's the code:

Code:
var box_text:TextField = new TextField();
//textformat for black text
var dark_text:TextFormat = new TextFormat();

[Code]....

View 3 Replies

Format Input Text Font, Color, Size?

Feb 10, 2012

now i need to customize the Font, Color, and Size.. can anyone help. I've found many possible solutions but none that I know how to apply to exactly what I have already created.

AS3:
stop();
submit_btn.addEventListener(MouseEvent.CLICK,check Answer);

[code].....

View 21 Replies

ActionScript 3.0 :: Format - Customize The Text (besides Color - Font - Size)

May 25, 2010

Im making a grid datatbase and wanted to know more ways to customize the text(besides color, font, size). Something like filters mabye?

View 2 Replies

ActionScript 3.0 :: Format Different Alignments And Font Size For Different Lines In The Same Text Field?

Dec 23, 2010

I created an multiline TLF editable text field in my fla file. How can I format different alignments and font size for different lines in the same text field?

View 2 Replies

Multiline And Changing Text Box Size?

May 13, 2010

I have some text pulled in from a db via cfm and remoted into flash - I'm trying to figure out a way to determine if whether or not a given string requires the vertical space of a multiline text box.Visually, two lines take up more space than a single line and when the string only takes up a single line, the second (empty) line creates to much whitespace and has everything below it too far away from that initial single line. When the string can fill both lines, it doesn't look bad at all - so, ultimately, I'm trying to get that whitespace gone.

View 1 Replies

ActionScript 2.0 :: CS3 Changing Font Size Of Dynamic Text Box?

May 19, 2010

have created a scrolling text area in flash CS3 using a dynamic text box with text inside controlled by a couple of buttons using the .scroll property to add to the scroll value on each click of a button.i am wanting to add two new buttons to decrease and increase the font size of the text within the dynamic text area, which i thought should be fairly easy. i found a .size property which could be applied to text, but i do not think i am using it in the right way. here's what i have tried to do (where 'myText' is the instance name of my dynamic text area):

on (release) {
var myFormat = myText.getTextFormat();
myFormat.size += 10;

[code].....

View 2 Replies

ActionScript 2.0 :: Dynamically Changing Text Font And Size

Jan 23, 2002

is there a way by which i could change the font and colour of a dynamic text,during run time.

View 7 Replies

ActionScript 2.0 :: Change Colour/format Of Multiple Objects?

Oct 2, 2003

I have a number of graphical called "Arms1", "Arm".... "ArmsN".

I would like to change the colour of all the objects.

I have a _global.armColour variable that I would like to access and all the graphics to change to that colour.

How do I great a for loop to create N number of these:

armsColor = new Color(_root.ArmsN);

and set N number of these.

armsColorN.setRGB(0x000099);
N = say 10.

View 1 Replies

ActionScript 2.0 :: [FMX] Change Colour/format Of Multiple Objects?

Oct 2, 2003

I have a number of graphical called "Arms1", "Arm".... "ArmsN".I would like to change the colour of all the objects.I have a _global.armColour variable that I would like to access and all the graphics to change to that colour.How do I great a for loop to create N number of these:

armsColor = new Color(_root.ArmsN);

and set N number of these.

armsColorN.setRGB(0x000099);

N = say 10.

View 1 Replies

ActionScript 3.0 :: Changing A Font Size In A Dynamic Text Field?

Jul 18, 2010

I am using a downloaded script and it is helping me out tremendously. After a little manipultion it is doing wonders for my intended project. The script yields a nunber into a dynamic text field that I would like to enlarge. In other words, make the font larger. I changed the size of the text field but the font size didn't change.Here's my script:

stop();
if (!initialized){
memory = 0;[code]...........

View 1 Replies

Professional :: Way Of Resizing A Dynamic Text Box Without The Type Changing Size?

Apr 1, 2010

I want to use the UI Text Scroll component on a text box. When I make the initial text box,it is the normal 1 line in depth, based on the font size. When I paste the type into the box it gets very long, which is fine, but when I try to make the text box  smaller using  the transform tool so that I can make it fit the movie, it makes the type smaller as well. Is there a way to change the height of the box, without it effecting the text inside?

View 2 Replies

Flex :: Hide (or Remove) Label Text Without Changing The Button Size?

Dec 21, 2010

I have a button with variable-length of label text. I have a User Setting that can turn on or off the label text on this button.

How can I implement this?

NOTE: the button's background has a gradient color.

I tried using BlendMode.LAYER, no luck;

I tried using Button.resizeHandler

private function resizeHandler(event:ResizeEvent):void
{
if (event.oldWidth > this.width)

[Code]....

but it only worked if the initial UserSetting value is true.

How about embedded font? I don't know how to apply it to button

View 3 Replies

ActionScript 1/2 :: Text Fields Resetting Characteristics (font - Size) When Tabbing To Them And Changing

May 2, 2010

When I set up 3 input text fields, I allow the user to change the font and size of those fields. If the user selects each one with the mouse and modifys them then no problems are seen. But if the user first changes the size and font of text field 2, then tabs to that text field and starts to change the text. The font and size properties revert back to the default.

View 1 Replies

ActionScript 1/2 :: Text Fields Resetting Characteristics (font, Size) When Tabbing To Them And Changing

Jun 7, 2010

When I set up 3 input text fields, I allow the user to change the font and size of those fields. If the user selects each one with the mouse and modifys them then no problems are seen. But if the user first changes the size and font of text field 2, then tabs to that text field and starts to change the text.  The font and size properties revert back to the default.

I could re-apply the formating everytime the text field changes, but that seems like a bandaid to the problem.

View 1 Replies

ActionScript 2.0 :: Changing The Colour Of A MC?

Nov 21, 2002

I am trying to automatically change the colour of an MC when it comes into play and am having a few problem. I used the code I found in the Flash AS Help, but it's not working.

Here's what I used:

myColor = new Color(rollover);
myColor = setRGB(0x993366);

Rollover is the instance of the MC I want to target.

View 14 Replies

ActionScript 3.0 :: Changing The Colour Of An Image?

Dec 10, 2008

I have a client that has a series of products that come indifferent colours and different textures. What I need to do is havepicture of the product. When the user runs a mouse over the colourpalette the product changes it's colour to represent the chose madeby the customer fro the various choose in a colour palette. FordCanada does this when I pick the colour of my car. I can run overred and the car will change colour to red.

View 3 Replies

ActionScript 3.0 :: Changing The Colour Of MovieClip?

Feb 9, 2010

Basically, I want to change the colour of a component in my fla file that is called 'EDL Arrow' using Actionscript
 
'EDL Arrow' is a Movieclip and is part of another movileclip called 'EDLClipDisplay' - which exports to my actionscript file: 'Export: CIS.FLVPlayer.EDLClipDisplay'
 
How can I change the colour of the component 'EDL Arrow' from the actionscript file 'EDLClipDisplay'
 
I understand how to do colorTransforms but I just don't understand how to connect this component 'EDL Arrow' with my Actionscript file.

View 1 Replies

Professional :: Colour Changing Upon Export?

Jul 27, 2010

I'm working on a game at the moment, and I'm running into a problem. I was testing the vector files that I export of the art I made, and upon re-importation to flash the colours have changed significantly. Then, when the game is running in a browser, it looks different again. It even looks different between different browsers.

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved