ActionScript 3.0 :: Implementing Padding For Thumbs

Jun 6, 2009

i, am building an portfolio site and i have come a long way (still a beginner) but now i found an problem. After i load xml file for paths to portfolio assets i load actual jpg's and/or swf's. But i am stuck since i do not understand how to implement padding so thumbs will be spaced evenly.[code]but than how to position first thumb?

View 3 Replies


Similar Posts:


ActionScript 2.0 :: XML Photo Gallery - Replaced The Original Thumbs With New Thumbs It Got All Screwed Up?

Jul 24, 2006

I was working with the XML Photo Gallery Thumbnail Tutorial on this site: http:[url]....

And I modified it for my own usage, making it a vertical gallery instead, and had no problems until I came upon the thumbnail images. When I replaced the original thumbs with my new thumbs (that I sized based on width, as it is a vertical gallery) it got all screwed up. The images are of all different shapes. So when it loads up, some of them had huge gaps in between them, and others were even overlapping. So I fixed it by making the heights of all the images the same, resulting in a working thumb gallery, but now half my thumbs are cropped off by the mask. I'm looking for a way to fix it where I still have the same spacing between the images, and that they are all the same width, but can vary in their height. Here's the section of the code I am using:

function thumbNailScroller() {
// thumbnail code!
this.createEmptyMovieClip("tscroller", 1000);[code]....

I'm also trouble figuring something out from the same tutorial, that I want to change. The tutorial uses these "Next" and "Previous" buttons. On the far right hand side, the half-circle buttons are what I assigned this to, but I don't really want them to have that function. I would rather have them function just like how the mouse functions when it rolls over the thumb gallery, except they scroll the thumbs up and down when clicked.

View 14 Replies

Text Box Padding Inconsistency?

Oct 20, 2009

I am using Flash CS4 at work: newly created type sits flush (top edge) within the text box. If I take the same file home and open in my newly purchased Flash CS4, the text now shows up with 10 or so pixels between the top of the letters and the top edge of the text box (like padding in CSS objects). This is a problem because it means all my text is now positioned lower on the stage than I intended and I can't take projects to and from work and home with any consistency. This is the same font, same file, same program version, which would suggest a preferences setting, but I can't find anywhere to modify text box appearance.

View 4 Replies

ActionScript 3.0 :: Add Padding Between Elements In A TileList?

May 12, 2010

Is there a way to add padding between elements in a TileList .

I've passed deadline with a big project , it's all done , but he changed his mind and demands padding. And doesn't want without, i don't have time to make a new component

View 4 Replies

Flex :: Remove All Padding From Label?

Nov 18, 2010

I am trying to remove all the padding from a Label contained in an HBox. I set paddingTop and paddingBottom to 0 in both the Label and HBox but there is still quite a bit of padding. I also tried setting verticalGap to 0 on HBox. If I just have a checkbox in the HBox the padding is removed fine.

View 2 Replies

Flash :: Add Padding To The Contents Of A Textfield?

Apr 1, 2011

I have a textinput component on my stage with an instance name of "myTxt" I would like to add some left padding to the contents of this textfield. I've tried:

myTxt.setStyle("textPadding", 5); But it adds top (and I assume bottom and right) padding in addition to the left padding. What is the best way to simply add left padding to the textfield's contents?

View 2 Replies

ActionScript 3.0 :: Adding Padding To A MovieClip?

Sep 2, 2009

An empty movieClip container will dynamically update it's width and height depending on the sum of it's child objects dimensions. Is there a way to add padding to this value?For example, say you have 10 child displayObjects within a movieclip and all together their width adds up to 100px. Therefore the parent clip's width is 100. Is there anyway to add say 2px padding around these child clips to make the parent clip's width 104? The basic goal here would be to set the parent's width independently and unrelated to it's contents dimensions.

View 7 Replies

ActionScript 2.0 :: Padding As It Were Of Stage.width?

Feb 2, 2008

i have a mask which is over some thumbnails. i have given that mask the value ofStage.widthi.e mask_mc._width = Stage.width /1;however i would like the mask to e slightly padded left and right so the mask doesnt go edge to edge of the screen any ideas on how i can do this AS2

View 2 Replies

IDE :: Modify TextField's Margin / Padding?

Jan 28, 2009

When dealing with TextFields, Flash always adds some sort of margin/padding around the outside of your TextField, so that if you set the X and Y of your TextField to 0, then your text would still sit about +4 pixels in.

If you create a TextField and set 'border=true', you will see what i mean - the border is drawn right on the edge of the TextField, but the actual text itself sits within a padding of about 4 pixels.

Is there any way at all to get the text of a TextField to sit hard-up against the border?

View 4 Replies

ActionScript 3.0 :: Padding Numbers For Time?

Jun 1, 2010

I am working on a time display that takes a time reference from a video. What is the best way to pad the numbers so they show correctly as 00:00, 01:23, etc.Would like to stay away from just padding a string "0" in front, so I can test the var for proper time and use it elsewhere. Has anyone already done this with some code already floating around ?

View 2 Replies

ActionScript 3.0 :: Flash - Applying Padding To A TextField?

Nov 10, 2010

I'm trying to apply a padding to the top of my TextField instance in my Flash application, much like you would using CSS.

I haven't found any way to do this. You'd expect it to be a part of the TextFormat or StyleSheet classes, but it's in neither. I sort of found a workaround by adding htmlText to the top of the TextField with <br /><br /> in it, but adding entire lines of white space to the top isn't desirable.

View 1 Replies

Flex :: Add Padding For SpanElement With Background Color?

Feb 21, 2011

I have a Spark TextArea with a SpanElement inside. This element has the backgroundColor property set, but I would like to have the background a bit taller because it looks a bit weird at the top like this.[URL]..

I already tried to adjust lineHeight and paddingTop for the SpanElement, but no luck.

View 1 Replies

Flex :: Panel Title Text Padding

Jun 21, 2011

Is there anyway for me to adjust the padding (left and right) of the text within a Panel Title in Felx 3.5?

View 1 Replies

Actionscript3 :: Flash - Padding Top And Bottom Of TextField?

Sep 6, 2011

Padding left can be done by TextFormat.leftMargin. And padding right can be done by TextFormat.rightMargin.

But there is no topMargin or bottomMargin property in TextField or TextFormat.
How can I do padding top and bottom?

Example code of left and right padding(margin) of TextField:

var format:TextFormat = new TextFormat
format.leftMargin = 40
format.rightMargin = 40

[Code].....

View 4 Replies

Actionscript 3 :: Using The Padding Property In Combobox Components?

Dec 2, 2011

I made a quick search in Google and I couldnt find what I need, basically, I want to set a padding in my combobox component, so the entire combobox (not the items inside) is a little separated from the previous component.

The combobox is contained inside a VBox container, and above there is a label. If I use the padding property, what it does is to decrease the Y position of the text inside, but the component doesn't move at all.

View 2 Replies

ActionScript 2.0 :: Set Different Padding For Header And Paragraph Using Css On Flash

Jul 8, 2010

I am using css on flash. Is it possible for me to set different padding for header and paragraph using css. I tried this on external loaded css file, but does not work

[Code]...

View 1 Replies

Actionscript 3 :: Draws Bigger Sprite Than I Have Set (padding/margin?

Mar 30, 2012

i created my own Button which simply extends from Sprite.Its able to show 3 different text fading in and out using a timer.In my draw function i first draw a rectangle with the Sprites graphics object representing the background of the button.I added a function to set the button width. This property is used to draw the rectangle. I know that the sprites's size is updated after the rectangle drawing. But for some reason the sprite's width is always more than what i have set via my "setButtonWidth" function.Now i have a simple sprite acting as a button having a graphics.drawRectangle part drawing a simple rect. with lets say 500px width. But when i trace the width of that button it is always about 10% more. Where are these 10% coming from?I read about calling validateNow(). But this is only for Labels, or Checkboxes. For some reason i cannot access the library for Label. This must work somehow with TextFields. But how?

// this function is part of MyButtonClass.as file
function drawButton()
{

[code].....

View 1 Replies

ActionScript 3.0 :: Padding Extra Argument From Event Listener To Handler

Nov 19, 2009

I have one event handler for several object's events. I would like to pass a value through to the function from the event listener:

PHP Code:

function chkEmpty(event:Event){
if(event.currentTarget.text==""){
thisIsBitIWantToBeAbleChange.text = "You haven't entered anything in the box, please try again"

[Code].....

Could I give the event.currentTarget a value that I could test for? So if the value is 1, I effect output1_txt, if 2, output2_txt, etc etc. If so, are there customisable values that I could use that wouldn't do anything to the display object,?

View 6 Replies

ActionScript 3.0 :: Consistent Value From Top Margin / Padding Of TextField To Top Of Actual Text

Jan 11, 2011

How can I get a consistent value from the top margin/padding of a TextField to the top of the actual text.According to the docs (link below), the text field has a 2px gutter on all sides. But there seems to be another gutter that seems to increase / decrease with the size of the text.Using times new roman for a default font size, I can get the baseline of some random text using what we know: I know that there is a 2px gutter all the way around the text field and we can get the ascent through textfield.getLineMetrics(0).ascent. If I draw a line at that position I'll get a line about 2 px below the actual text. Works fine.Now if I want to draw another line at the TOP of the text it's a guessing game. At 36pt text it's 8px from the top of the textfield. At 72pt text it's more like 12px from the top, and at 144pt text it's more like 20px from the top.URL...

View 0 Replies

Flash - Dynamically Made Sprite Object Has Margin/Padding On Bottom?

Sep 18, 2010

I'm made an Item class which extends the Sprite class, the Item class basically has a few checkmarks & labels at the moment.

Then what I try to do is run through a for loop of items and create Item classes that I want to place one after each other on the y-axis, so I'm reading the Item.height property to find the y of the next Item in the list.

The problem is for some reason there is always an extra 75 pixels added to the Sprite height at the bottom, no matter how many checkmarks and labels are in each Item class ( varying the height of the Item class ).

Any idea why this is being added and how it can be removed?I'm having trouble figuring this out, I tried dynamicly calculating and setting the Item.height property but when I do that the Sprite is simply cropped.

View 1 Replies

Flex :: Implementing States In App

Apr 24, 2010

I'm trying to work out how to use states in my Flex app.I've created two states, State1 and Stage 2. Both are based off the base state. I've created a few visual elements for State1, and given each of them includeIn="State1".But when I'm in design mode and click on State2, these elements are still visible?If I try to delete them while State2 is selected, all that happens is RemoveChild is added to the State2 tag.

View 1 Replies

Actionscript 3 :: Implementing IEventDispatcher?

Jun 3, 2011

I haven't used the implements keyword before, and I've been trying to use it to implement the IEventDispatcher class to see if this would allow me to use addEventListener() in a class that extends Object (this is my understanding of what it's for - correct me if I'm wrong).My class is like this:

package
{
import flash.events.Event;

[code].....

View 2 Replies

Actionscript 3 :: Implementing Indexer From C#?

Aug 29, 2011

Within C# there're these things called indexers that do something similar to this:

public Something
{
public Object this[String s]

[code].....

View 1 Replies

ActionScript 2.0 :: Implementing And Editing XML?

Jun 11, 2004

implementing and editing XML within Actionscript worked out swell - no problems so far..but the some_xml.send() seems to become a true nightmare!

Soit, here's an example:

I made a little "keep-in-touch" maillinglist, where visitors can leave their adress, click the "send" button - and let the administrator view the list on a secure page. XML suits fine for this job, i think.

Code:
on (press, keyPress "<Enter>") {
mailInput_xml = new XML();
mailInput_xml.ignoreWhite = true;[code]....

View 2 Replies

Actionscript 3 :: Crypto Say "Invalid Padding Value"?

Sep 1, 2010

What is the cause of the error "Invalid padding value" in as3crypto?

Error: PKCS#5:unpad: Invalid padding value. expected [153], found [25]
at com.hurlant.crypto.symmetric::PKCS5/unpad()
at com.hurlant.crypto.symmetric::CTRMode/decrypt()[code].........

View 1 Replies

ActionScript 3.0 :: Implementing External Swfs?

Sep 28, 2010

I have a custom form that I want to implement and I am having a problem figuring out how to do so. I want to have it work like an inner popup where it blurs and unblurs the background imageHere's my setup:FLA file contains-UILoader for swf sectionUILoader for random background imageLets say I load a section called home.swf into the section loader. Within the home.swf I have a button for someone to call up the form.swf. Is it possible for the form to blur the random background image when loaded then unblur it when it's done? I also have no idea how to unload it.

View 1 Replies

ActionScript 1/2 :: Implementing  A Preloader For Loading An Swf?

Aug 2, 2009

I am trying to implement a preloader for loading an swf. I have an swf named 001.swf. I need to create a preloader for loading this swf. So should i create one more swf for loding the 001.swf.

View 7 Replies

Professional :: Implementing A Scrolling Banner?

Mar 3, 2010

I'm pretty new to Flash, and having a few problems with a website I've had to design for my college ICT course.I built the site entirely in Flash, which went perfectly, then went on to build a scrolling image gallery banner for use on a gallery page of the site (assuming that it would be an easy task to chop the banner into the website).When I've tried importing the file to the stage/library it leaves all the images behind (as they are in the library of the first file) as well as the actionscript required to call the images; leaving me with just a new, blank layer.I've also tried copying the actionscript code into the website document and transferring the images from the gallery library to the website library, however, the gallery is written so that the stage is used in its entirety to show only a certain amount of images, meaning that the proportions of the banner are all wrong on the website file.Is there any way to integrate the flash file for the gallery into a confined area of the stage in the website document, or am I going to have to alter my designs so that the gallery goes entirely across the page (put up and shut up style).
 
Attatched are download links to the two files in question, sorry if they're a little on the large side.

[Code]...

View 4 Replies

ActionScript 3.0 :: Implementing A Simple Class

Jun 15, 2010

I cannot believe that implementing a simple class should be so hard. I am trying out the simple example outlined on the Adobe website: url...I copied the class code from here to file Greeter.as in subdirectory Learning. Then I created a dynamic Text field on the stage.

View 3 Replies

ActionScript 3.0 :: Implementing Webservices In Flash CS5

Feb 15, 2011

I am looking for a walkthrough for implementing a call for a webservice from an swf file, I cant find any..

View 1 Replies







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