Indesign : how to move a rectangle object with his content ?

hi
i develop an indesign extension with flash builder and cs extension builder 2.
when I move a rectangle object containing an image with the geometricBounds property the image does not move and is not visible anymore ...
how to move a rectangle object with his content ?
thanks
Simon

Use rectangle.move()

Similar Messages

  • How to move the anchor object in indesign cs2 using js?

    i can able to move the normal textframe and other objects but cant do this for anchor objects.
    syntex:  anchorobject.move([x value,y value],undefined,true)
    how to move the anchor objects?
    thanks
    subha

    Could it be that the anchord object in question won't move because you have it set to keep within margins which is preventing the move you're requesting? I've certainly run into that.
    I've also run into the situation where the object model thinks the anchored object is in one place when it is actually in another because of that same keep within margins option. In this case, a move will apparently not work because the move is invisible, it being completely outside of the margins -- although that only applies to relative moves, I think.
    Dave

  • How to move some xml element and its content to a new frame

    Hi All,
    How to move some xml element and its content to a new frame.

    Hi Chinnadk,
    Sorry my code its comment some lines. Now only I check the forum thread, you just try one more time.
    #target InDesign;
    #include "/Program Files (x86)/Adobe/Adobe InDesign CS5.5/Scripts/XML Rules/glue code.jsx"
    var myDoc = app.activeDocument;
    //____________________ XML RULE SET
    var myRuleSet = new Array (new margintag);
    with(myDoc){
        var elements = xmlElements;
        __processRuleSet(elements.item(0), myRuleSet);
    function margintag(){
        this.name = "margintag";
        //this.xpath = "//margintag[@type='mn2']";
        this.xpath = "//margintag";
        this.apply = function(myElement, myRuleProcessor){
            with(myElement){
                app.select(myElement);
                try{
                    var myPrePara = app.selection[0].paragraphs[-1].parentTextFrames[0].paragraphs.previousItem(app.selection[0].paragraphs[-1]);
                    if(myPrePara.characters[-1].contents=="\r"){
                        myPrePara.characters[-1].remove();
                    var myTextframe = myElement.placeIntoInlineFrame(["7p9","6p"]);
                    myTextframe.appliedObjectStyle= myDoc.objectStyles.item("MN1");
                    myTextframe.fit(FitOptions.FRAME_TO_CONTENT);
                    myTextframe.parentStory.paragraphs.everyItem().appliedParagraphStyle = app.activeDocument.paragraphStyles.itemByName("MN1");
                    }catch(e){}
                app.selection = null;
            return true;
    thx,
    csm_phil

  • How do I create an object with "click and drag" interaction?

    I want do make an object that I can move around the screen at will, so, I need a way to make a click and drag object in adobe edge.
    I also need this to work with touch devices and also to limit the movement of the object to one direction (x or y).
    Thank you all in advance.

    Thanks for your reply.  I tried doing what you said, creating a command by opening a new flash file, etc.  For some reason, I could make a rectangle and save that as a command, but making a shape using the polystar command didn't work - there was a red "x" next to it in the history panel.
    Anyway, even if I could do that, it's not what I want to do.  I want to be able to create a shape and then be able to change the shape dynamically.  For instance, I want to be able to create a series of points and draw curves between them to create a closed curve shape.  Then I want to be able to change the positions of the vertices so that the shape changes as the .swf is running.  Thanks.

  • Move a Rectangle object

    Hi guys
    I'm just trying to create an applet that draws a shape such as a rectangle that will allow the user to click on the rectangle, then move the mouse and the shape will be re-drawn at the point where the mouse is released.
    Any ideas where i can start, pointers greatly appreciated.

    Here is the program you posted (with my corrections) which works
    import java.awt.*;
    import java.applet.*;
    import java.awt.event.*;
    public class Test extends Applet
                                implements MouseListener
        private Color color = Color.black;
            int x1, y1, x2, y2 = 0;
    int width, height = 0;
      int startX, startY = 0;
    boolean drawObject = false;
         boolean moveObject = false;
         Rectangle myRectangle = new Rectangle(startX,startY,width,height);
        public void init()
            setBackground(Color.gray);
            addMouseListener(this);
            int i = 5;
        public void paint(Graphics g)
              //recover Graphics2D
                Graphics2D g2 = (Graphics2D)g;
              g2.setColor(color);
                 if(drawObject){
                     //create Rectangle Object
                            myRectangle = new Rectangle(startX,startY,width,height);
                          g2.draw(myRectangle);}
              else if (moveObject){
                       g2.drawString("MOVE", 100,100); //just testing here
                         myRectangle.setLocation(x2,y2);}
        //--> Start of section dealing with Mouse Events
        public void mouseClicked(MouseEvent e)
        public void mouseEntered(MouseEvent e)
        public void mouseExited(MouseEvent e)
        public void mousePressed(MouseEvent e)
               x1 = e.getX();
              y1 = e.getY();
              //Check to see if mouse is pressed in the current rectangle.
                if(myRectangle.contains(x1,y1))
                           //move the object instead of moving it
                      drawObject = false;
                         moveObject = true;
                   else
                           //draw the object, don't move
                       drawObject = true;
                          moveObject = false;
        public void mouseReleased(MouseEvent e)
                   //get the positions of where the mouse was released
                 x2 = e.getX();
              y2 = e.getY();
              if (x1 != x2 && y1 != y2){
              //maths to work out where to draw the object
                if(x1 < x2 && y1 < y2){//1
                          startX = x1;
                        startY = y1;
                        height = y2 - y1;
                           width = x2 - x1;}
                   else if (x1 > x2 && y1 > y2){//2
                            startX = x2;
                        startY = y2;
                        height = y1 - y2;
                           width = x1 - x2;}
                   else if (x1 > x2 && y1 < y2){//3
                            startX = x2;
                        startY = y1;
                        height = y2 - y1;
                           width = x1 - x2;
                   else if (x1 < x2 && y1 > y2){//4
                            startX = x1;
                        startY = y2;
                        height = y1 - y2;
                           width = x2 - x1;}
                   } repaint();
    }I.e. User can draw a rectangle; clicking inside it causes string MOVE to appear at point 100,100. If you want to redraw rectangle at point where mouse has been clicked, try to think about it a bit and post your code if it wont work. Do not ask to write it for you.

  • How do I outline an object with a dash line in Photoshop CS6?

    How do I outline an object (silhouette figure) with a dash line in Photoshop CS6? ... never was this difficult.

    I have a silhouetted figure I'd like to outline with a dash line ... Will I have to manually outline the object ... what alternative do I have?

  • How to create a date object with a specific time?

    How can I create a date with today's date but with a specific time, say: 20:00:00?
    Thanks in advance.

    Don't forget about those pesky milliseconds!I'd have gotten away with it too.. if it hadn't been
    for that pesky BigDaddyLoveHandles.I'm in top form today. On the drive in to work I managed to
    push two scooter riders off the road and gave the finger to
    a Prius owner.

  • How to import/paste Illustrator-objects with opacity-effects?

    Hi all!
    I can't get FW CS4 to import or paste Illustrator objects
    with opacity-effects such as Multiply?
    The objects gets flattened and all effects are gone!
    Please help!
    TIA!
    /H

    henriko75 wrote:
    > Hi all!
    >
    > I can't get FW CS4 to import or paste Illustrator
    objects with
    > opacity-effects such as Multiply? The objects gets
    flattened and all
    > effects are gone!
    Why not apply them in Fireworks?
    Linda Rathgeber - Adobe Community Expert
    http://www.adobe.com/communities/experts/members/8.html

  • How to synchronize test schema objects with the prod schema objects.

    Hi,
    I have a requirement of synchronizing test schema objects with the production schema objects. Please let me know the below
    1. if there is a standardized method for such activity,
    2. if there are oracle utilities for this task.
    3. If i had to do this job manually, can you let me know the check list if any.
    Thanks
    Purushotham M

    http://www.oracle.com/technetwork/issue-archive/2012/12-sep/o52sqldev-1735911.html
    You could try database diff tool in sql developer(but there are some licence restrictions).
    I don't know your database version, you could try DBMS_COMPARISON package also.
    Look at this link http://docs.oracle.com/cd/B28359_01/appdev.111/b28419/d_comparison.htm
    Other solution is to create db link between test and production database, and then you can try different types of queries like
    select table_name from user_tables
    minus
    select table_name from user_tables@db_link_to_other_database
    And you can do this for columns, indexes and so on.
    But you must have proper DDL scripts for this, to generate sync script.
    Also there is a question about work process, you are doing sync in reverse order(from production to test). Test db is for test, after test you go to production db with proper ddl and dml scripts, so these schemas shouldn't be different in the first place(talking about schema, not data here).

  • How to upload html file document with his.files

    i can upload only one file and i can't upload html file with his images or some more pages
    index.html
    chapter1.html
    chapterN.html
    I see this problem so: upload zip file and extract to os(i use linux) and saved link to his index.html.
    IS IT POSSIBLE.
    Thanks.
    Sorry for my english.

    The simplest way to handle this would be to Upload the  page and files to a  remote server space and send your email buddies a link to the site.   Barring that....
    How to Code HTML Emails
    http://www.sitepoint.com/article/code-html-email-newsletters/
    Use  inline CSS styles for fonts and background colors.  Use Tables to hold your  page elements.  Use absolute URLs to images hosted on your web server because attached images may not get through. Give  people who can't see your HTML page in their email client a link to the HTML  page on your web server.
    Download some HTML Email Templates from the links below  to help you get started.
    Mail Chimp
    http://www.mailchimp.com/resources/html_email_templates/
    Constant  Contact
    http://www.constantcontact.com/email-marketing/html-email-templates/index.jsp
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists
    www.alt-web.com/
    www.twitter.com/altweb
    www.alt-web.blogspot.com

  • Link a "Smart Object" with his Mask - possible?

    Hello -
    Is there a way to link a smart object and his mask?
    It's really annoying, because, when I move my smart object, his mask doesn't follow!
    Thank you, have a nice end of day
    - Dimitri

    At this time, Smart Objects can't have masks linked to them. So place your smart object in a group by itself, then create a mask for the group.

  • How to Specify/Associate a layout with a content

    I have created a new site, I have created few contents and few templates. During creation of content/page i did not find any option to associate a template or layout with the content/page. When i am trying to preview the content or try to open in web mode, I gets the following error.
    "A content layout must be specified to render this asset in web mode. Please specify a default layout."
    Need help me in resolving this issue.

    @Rodney: Thanks for the pointer. I did not choose that option. Problem solved after using that option.

  • How Select All Text Objects with Specific Contents and Move to Top-Center?

    Mavens,
    In a ~230 page InDesign CC Book (9 INDD files), on about ~35 pages, there is a small text block with the word "NOTES."
    Currently, the NOTES text block is in the Middle-Center of the page. I would like to find a way for InDesign to move all ~35 instances of the NOTES text block to the Top-Center (of the page each text block is on).
    Is there an easy way to do this with Edit --> Find/Change?
    Thanks!

    Probably not.
    That text block really belongs on a master page applied to those 35 pages, and if it is, all you have to do is move it on the master page. If it isn't, you've got some work to do. Probably easiest to fix one, then coy it and use Paste in Place on the other pages, and delete the frame that's in the wrong place.

  • How to create the Frame object with API in 6i?

    do i create an item using d2fitmcr_Create, and then set the type or style to frame? or is it a graphics item that i have to create using a different function? ive tried various combinations with no luck.
    ive looked at the frame object in the GUI, and cant figure out how to duplicate it using the API (the frame object is the thin line box with a label used to groups items visually on a form)
    thanks!
    [email protected]

    Frame is a type of graphic d2fgracr_Create() (d2fgra.h) then set the type as required using d2fgras_graphics_typ():
    Definition of Graphics types is in d2fdef.h
    ** Graphics Type (D2FP_GRAPHICS_TYP)
    ** [BPT]
    #define D2FC_GRTY_ARC              0                                 /* Arc */
    #define D2FC_GRTY_IMAGE            1                               /* Image */
    #define D2FC_GRTY_LINE             2                                /* Line */
    #define D2FC_GRTY_POLY             3                             /* Polygon */
    #define D2FC_GRTY_RECT             4                           /* Rectangle */
    #define D2FC_GRTY_RREC             5                   /* Rounded Rectangle */
    #define D2FC_GRTY_TEXT             6                                /* Text */
    #define D2FC_GRTY_GROUP            7                               /* Group */
    #define D2FC_GRTY_FRAME            8                               /* Frame */All the various properties for setting up the associated block etc (if required) can be set through macros in d2fgra.h

  • How do I create an object with code?

    I have a flash cs3 file in which I have created a simple movieclip (square) by drawing a rectangle on the stage of that movieclip.  When I drag that into another movieclip (clip) I am able to set properties for it such as x and y position by adding actionscript code to various frames of the "clip" timeline.  So far so good.
    Now I have created a second movieclip (shape).  I want to be able to define the shape purely with code, so I entered the following code into the first frame of the "shape" timeline:
    var myShape:Shape = new Shape();
    myShape.graphics.beginFill(0xFF0000);
    myShape.graphics.moveTo(20,20);
    myShape.graphics.lineTo(100,20);
    myShape.graphics.lineTo(100,100);
    myShape.graphics.lineTo(20,20);
    myShape.graphics.endFill();
    this.addChild(myShape);
    I then hoped I could drag and instance of the "shape" movieclip onto the "clip" stage and have a red triangle show up, but nothing shows up.  It seems I have to actually draw something onto the "shape" stage for something to show up.  I would like to be able to create shapes programmatically but I don;t know how to do it.
    Thanks.

    Thanks for your reply.  I tried doing what you said, creating a command by opening a new flash file, etc.  For some reason, I could make a rectangle and save that as a command, but making a shape using the polystar command didn't work - there was a red "x" next to it in the history panel.
    Anyway, even if I could do that, it's not what I want to do.  I want to be able to create a shape and then be able to change the shape dynamically.  For instance, I want to be able to create a series of points and draw curves between them to create a closed curve shape.  Then I want to be able to change the positions of the vertices so that the shape changes as the .swf is running.  Thanks.

Maybe you are looking for

  • Data migrated from MS SQL Server 2k to Oracle8i is not the same :(

    I'm trying to help a customer here who is trying to migrate a table from MS SQL Server 2000 with column WORD of type varchar (100) to Oracle8i (8.1.7.2) using Oracle Migration Workbench 1.4.0.1 using MS SQL Server 2000 plugin. That column has unique

  • Report with both read-only and uploadable features

    Client would like to use one report as both an uploadable report and as a read-only report, depending on user. Is there any way to have a report which gets security based on the user making the request, say, by hiding the upload button for the user w

  • Opening a browser window from iBooks

    Is it possible to have a link to a website in an ibook author textbook but instead of dumping you out of ibooks into Safari, it opens up a browser window within iBooks?  I don't want to have the user to leave the iBook just to check out a website for

  • Allocate Additional Account Assignments to Contracts

    Hello people. I would like to know if there is anyway I can have a field available in the MM or Securities contracts to assign a cost center and then at the moment of posting the system uses this classification I´ve informed in the contract.´ I´ve lo

  • Guys why is Coherence asking for hibernate.cfg.xml file ???

    Wondering why Coherence could not read/interpret from our hibernate mapping file and ask for hibernate.cfg.xml. Wondering if Coherence has been configured to require hibernate.cfg.xml. Here is the error i get while running JUnit test 2009-11-10 11:01