How to magnify a rounded rectangle

Hello,
How to magnify a rounded rectangle if I would like the size
of it's rounded corners to stay fix? The script I draw the
rectangle with:
function DrawRoundedRectangle(X:Number, Y:Number, W:Number,
H:Number, Roundness:Number, Thickness:Number, Tint:Number,
Alpha:Number) {
_root.createEmptyMovieClip("Rect", 1);
_root.Rect.lineStyle(Thickness, Tint, Alpha, true, "none");
_root.Rect.moveTo(X, Y + Roundness);
_root.Rect.curveTo(X, Y, X + Roundness, Y);
_root.Rect.lineTo(X + (W - Roundness), Y);
_root.Rect.curveTo(X + W, Y, X + W, Y + Roundness);
_root.Rect.lineTo(X + W, Y + (H - Roundness));
_root.Rect.curveTo(X + W, Y + H, X + (W - Roundness), Y + H);
_root.Rect.lineTo(X + Roundness, Y + H);
_root.Rect.curveTo(X, Y + H, X, Y + (H - Roundness));
_root.Rect.lineTo(X, Y + Roundness);
DrawRoundedRectangle(10, 10, 120, 90, 10, 1, 0x000000, 100);
If I change it's _width or _height property unfortunately
it's rounded corners grows too. And the other problem I don't
understand: Why do the x and y coordinates of the rectangle change
when I magnify it?

I would use the 'scale9Grid' movieclip property, where as
when applied to a movieclip the rounded corners will not deform. An
easy way to use this property, if you can, would be to use it on a
movieclip symbol in the library where you can adjust the grids
during author-time. Here is a link from the livedocs;
http://livedocs.adobe.com/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveD ocs_Parts&file=00002512.html

Similar Messages

  • How to create a rounded rectangle?

    I can't figure out how to create a rounded rectangle in Flash
    8... Any one
    want to help me with this?
    Best Regards,
    Chris Jumonville
    iMedia Web Design
    503.277.3553

    You can ignore this. I figured it out.
    Best Regards,
    Chris Jumonville
    iMedia Web Design
    503.277.3553
    "Chris Jumonville" <[email protected]> wrote in
    message
    news:ej6l1r$ano$[email protected]..
    >I can't figure out how to create a rounded rectangle in
    Flash 8... Any one
    >want to help me with this?
    >
    > --
    > Best Regards,
    >
    > Chris Jumonville
    > iMedia Web Design
    > 503.277.3553
    >

  • How can we draw Round Rectangle Border

    how can we draw Round Rectangle Border for example, just like XP's Task Manager( under "performance tab" )

    HI,
    Check MacTopia's support area for Word. http://www.microsoft.com/mac/help.mspx?product=Word&app=4
    I would think you need graphics software for that....
    Carolyn

  • Rounded Rectangle

    I was trying to rember how to make a rounded rectangle in FCP.  I looked across the web.  And everyone was telling each other it can't be done.  But I was doing it five years ago.  Just couldn't figure out where.
    Got it.  Boris' Vector Shape.

    Here are at least 25 ways using CSS: http://www.cssjuice.com/25-rounded-corners-techniques-with-css
    I like the 'nifty corners' technique.

  • Rounded rectangle window?

    In java how to get the rounded rectangle window. I used JWindow class to design the window. But how to do the rounded rectangle shape.
    Thanks in advance
    javasans

    Anyone else done something similar?
    I'm drawing a screen capture on my window and then drawing an AlphaComposite image over that... but what happens when the window is dragged won't there be a delay in the painting?

  • Fill a rounded rectangle with a gradient paint with "new RoundRectangle2D"?

    Hello,
    at the moment I have to do a lot of Java2D to draw a customized GUI. Now it comes to a simple task, filling a rounded rectangle with a gradient paint. I have a solution for this - but I don't know if it is bad to do it this way:
    private void drawBackground( Component component, Graphics2D graphics2d ) {
         int w = component.getWidth() - 1;
         int h = component.getHeight() - 1;
         graphics2d.setPaint( gradientPaint );
         RoundRectangle2D backgroundShape =
              new RoundRectangle2D.Float( 0, 0, w, h, 10, 10 );
         graphics2d.fill( backgroundShape );
    }This is very easy and it works. The backdraw is, that on every call of "drawBackground", which is called on a repaint() method by Swing, a "new RoundRectangle2D.Float" will be created. I don't know how "expensive" it is to create a new RoundRectangle2D. On the other hand, I don't know how to fill a rounded rectangle with a gradient paint without a RoundRectangle2D.
    When I do it this way, I worry that at a later time, when I created a lot of custom components that all create shapes on a repaint, the GUI may become horrible slow or has a huge memory footprint.
    Well, I would like to hear some kind of "this is okay" (maybe because those Shape implementation are all not very memory consuming and the instanciation in Java is not very time consuming) by you Java2D experts :) Or, of course, how I could do it better.
    Thanks a lot for your help!

    patb1 wrote:
    on every call of "drawBackground", which is called on a repaint() method by Swing, a "new RoundRectangle2D.Float" will be created. I don't know how "expensive" it is to create a new RoundRectangle2D.
    When I do it this way, I worry that at a later time, when I created a lot of custom components that all create shapes on a repaint, the GUI may become horrible slow or has a huge memory footprint.You could do as many UI delegates in the Swing code do with Rectangles: maintain a RoundRectangle2D as a field and set its attributes when it is to be painted (setRoundRect(double x, double y, double w, double h, double arcw, double arch)).
    db

  • Scaling 'rounded' rectangle

    Hi there, I'm having problems working out how to scale a rounded rectangle without the corners becoming distorted.  I've attached an example below, with the smaller rectangle on the top being the original and the one below being the 're-sized' version of the same thing.  As you can see, the corners are not right.
    Thanks.

    Wow just days after posting this, the 2014 Illustrator CC top feature:
    Live Shapes: Rectangles and Rounded Rectangles
    Rectangles now have quickly modifiable corners, including independent radius control. Corner attributes are retained if you scale and rotate your rectangle. Now Illustrator remembers your work — width, height, rotation, corner treatment — so you can return to your original shape.See how it works
    Adobe Illustrator CC new features | Buy Illustrator CC

  • Rounded Rectangle Tool - how to set default corners?

    This has been bugging me for ages, time to get an answer!
    How can you set the rounded corners to a default value? I know that while manually creating a mask, using the arrow keys I can increase/decrease the size of the corners. I was hoping that this last setting would be remembered so, with a layer selected, I could double-click on the Rounded Rectangle Tool and it creates a mask with rounded corners at the last setting.
    Doesn't happen. Any ideas?
    Also, while I have your ear, how do I hide a mask in the Layer Viewer in CS6? I'm sure there was an icon for it in previous verions and neither the Hide Edges keyboard shortcuts or the mask button in the Composition window has any effect.

    Cheers Mylenium. I seem to remember in past versions of AE we got a little button in the Layers window the same as in the Composition window that toggles the mask edges (not the mask) on and off:
    I just want to hide the mask edges regardless of the popup selection. Think I'm going bonkers as I'm sure it used to be there and I can't be the only one that found it useful!!

  • Premiere Pro cs6 How to adjust radius of rounded rectangle

    I think my title covers my question.
    How do I adjust radius of rounded rectangle in Premiere Pro CS6? Trying to make a lower third and don't want the exaggerated rounded corner.  Is there a way to adjust the radius of the corner?
    Thanks

    how about using the pen tool? Either place your rounded rectangle in your spot (to use as a template, guide to line up, or practice pen) and draw over with the pen tool
    or, draw your rounded rectangle with the pen (no guide)
    with the pen - properties - graphic type - choose 'filled bezier'
    EDIT - just using the rounded rectangle tool, gives the properties- graphic type - round rectangle (ah, but then I also see a 'rounded corner rectangle')
    so, change option to 'filled bezier' and either delete middle anchor point of corner and use convert anchor point tool to pull out corners
    or - change option to 'filled bezier' choose pen tool, select middle anchor point, click, hold and move to your choice
    or I have misunderstood your rounded rectangle to be either
    1. round rectangle
    2. rounded corner rectangle

  • How to make ROUNDED rectangle default style cp8?

    Hi,
    I want my smart shape style to be rounded rectangle, not squared. I have set up my object styles with color and all that good stuff, but there is no way I can see to make it the rounded shape instead of the squared off shape.  I also tried to change one on the properties panel thinking I could "apply to all" but that option is not available.  I am trying to use smart shapes as my captions in recording and it sure would be nice not to have to touch every single one and change it to rounded - defeats the purpose of styles, yes?
    Using CP8, latest version (I checked and there are no updates available), on a windows machine, 64 bit.
    Thanks!!!
    Kelly

    Rick, that option has effect on the captions inserted while creating a software simulation.
    @LMS_90 About which shapes as Text container are you talking? Object styles for Shapes do not include the 'form' of the shape. And at this moment, you cannot set such a form as being included in the default style, with the one exception that Rick points out: added text during a simulation capture.
    Even for Success/Failure/Hint shapes you cannot define that it always has to be a rounded rectangle. For Question slides, you can set them up in the master slides, and if you use always master slides with placeholders it is also possible. Quite a lot of the default themes have rounded rectangle shapes as text container for Title and Subtitle.
    Also in the Properties the 'form' is not part of the style: if you apply the default Shape Style that includes Stroke, Fill, Character properties, Margins, Shadow...but not the shape itself. That is the reason why 'Apply to all' cannot be used for the shape form.
    This is probably not the answer you expected, I try to change as much as possible in the Master slide.

  • How to smooth pixelated edges of Rounded Rectangle Filter?

    I'm using the rounded rectangle filter to divide the frame into about 25 pieces (a mosaic type of transition is what Im going for) and I like the look of the round rectangle but the four corners are terribly pixelated. Is this just an oversight on the part of the programs developers or is there a setting I am over looking?
    Thanks Mac People,
    Justin!

    Hey Jim,
    I am seeing the pixelation on my monitor. The oval shape filters work just fine, and thats what has me scratching my head.
    Also, i have my Filmo figured out, except for the dial one the viewfinder that changes the size of the frame in side it. Do those numbers correlate with different size lenses? Do you have any suggestions and what lenses I should look into and where to find them. Theere is only one on the camera as is, a very small one about the size of a golf ball.
    Thanks again Jim,
    Justin!

  • How to make a round border around my picture?

    I am trying to design a logo that would fit into the center of a Frisbie, yet I cannot figure out how to make a round border around the picture. I have tried using the eliptical tool, and have also tried using the cookie cutter. The only option I can get to work with the eliptical tool, is the feather, yet I can't change the pixel number for some reason, so it just makes a thin circle around the picture. I thought I could cut and paste it, but the copy and cut options were grayed out and didn't work. When I used the cookie cutter, it made a nice border, and I pasted the picture into it, but, there are four sections that need to be filled in with the background color and the paintbucket didn't work in those spaces (they are the gray and white checked areas. (the picture ends up looking like a rectangle inside of a circle). So I made a new blank file and filled it in with the color of the picture's background, hoping to use the cookie cutter tool around the picture that was now pasted into the new blank file (I chose another color for the round border) and I used the cookie cutter around the picture, but when it was finished, the whole picture ended up being white. All I want to do is to make a border around a picture (a round border). Nothing I have done has worked though. What am I doing wrong, or what are some other options for trying to do this? Thanks.

    Here is a simple way to add a border. Select the item, add a blank layer, choose the border size and color and the Outside option:
    Here is the result:
    Note that you don't even need to do the Stroke on a blank layer. You can Stroke directly on the picture layer. However having the blank layer preserves the picture in case you want to start again with different Stroke options.
    If this is not what you are looking to do, please clarify.

  • Can't use the knife tool to cut the rounded rectangle

    The knife tool is grayed out when I try to use it ona rounded
    rectangle. How can I errase part of a rounded rectangle?

    dm25 wrote:
    > The knife tool is grayed out when I try to use it ona
    rounded rectangle. How can I errase part of a rounded rectangle?
    You need to ungroup it first. Modify > Ungroup.
    Linda Rathgeber [PVII] *Adobe Community Expert-Fireworks*
    http://www.projectseven.com
    Fireworks Newsgroup:
    news://forums.projectseven.com/fireworks/
    CSS Newsgroup: news://forums.projectseven.com/css/
    http://www.adobe.com/communities/experts/

  • Convert rectangle into rounded rectangle

    Hi!
    Can anyone tell me how I cn convert an existing rectangle
    into a rounded rectangle please?
    Also, how do you insert a rectangle/shape of a specific
    size& position without having to click and drag?
    I find that when I want to insert a rounded rectangle but
    then want to make it bigger, clicking and dragging a corner can
    make it the right size but causes the rounded corners to distort
    into a more elliptical shape then circular.
    Thanks,
    Matthew.

    maffpunton wrote:
    > Hi!
    >
    > Can anyone tell me how I cn convert an existing
    rectangle into a rounded
    > rectangle please?
    Use the Rectangle Roundness slider in the Property inspector.
    > Also, how do you insert a rectangle/shape of a specific
    size& position without
    > having to click and drag?
    You can insert one via the Auto Shape Properties panel.
    >
    > I find that when I want to insert a rounded rectangle
    but then want to make it
    > bigger, clicking and dragging a corner can make it the
    right size but causes
    > the rounded corners to distort into a more elliptical
    shape then circular.
    Have you tried using the Auto Shape Properties panel?
    Linda Rathgeber [PVII] *Adobe Community Expert-Fireworks*
    http://www.projectseven.com
    Fireworks Newsgroup:
    news://forums.projectseven.com/fireworks/
    CSS Newsgroup: news://forums.projectseven.com/css/
    http://www.adobe.com/communities/experts/

  • Rounded rectangle shape - save for web issue

    Hi, I made a rounded rectangle logo with radius=40 and when I save the file for web, shape appears with cutted edges. In .psd file everything looks fine, problem apperas only with save for web options (.jpg/.png). is this some bug, do somebody know how I can fix this?

    If this is a bug, I would either flatten or merge visible - making sure you have a pixel layer - even if it is blank, so the shape layers are rasterized before you save for web.  Just don't flatten it and save your original file!

Maybe you are looking for