Package com.sun.star.drawing

Examples of com.sun.star.drawing.XDrawPages.insertNewByIndex()


          XDrawPagesSupplier.class, xDrawDoc );
      XDrawPages xDrawPages = xDrawPagesSupplier.getDrawPages();
           
      // take care that this document has ten pages
        while ( xDrawPages.getCount() < 10 )
        xDrawPages.insertNewByIndex( 0 );

      // assign a name to each page and also insert a text object including the name of the page
      String aNameArray[] = { "Introduction", "page one", "page two", "page three", "page four",
                  "page five", "page six", "page seven", "page eight", "page nine" };
      int i;
View Full Code Here


  {
    XDrawPagesSupplier xDrawPagesSupplier =
      (XDrawPagesSupplier)UnoRuntime.queryInterface(
        XDrawPagesSupplier.class, xComponent );
    XDrawPages xDrawPages = xDrawPagesSupplier.getDrawPages();
    return xDrawPages.insertNewByIndex( nIndex );
  }

    /** removes the given page
  */
  static public void removeDrawPage( XComponent xComponent, XDrawPage xDrawPage )
View Full Code Here

  {
    XMasterPagesSupplier xMasterPagesSupplier =
      (XMasterPagesSupplier)UnoRuntime.queryInterface(
        XMasterPagesSupplier.class, xComponent );
    XDrawPages xDrawPages = xMasterPagesSupplier.getMasterPages();
    return xDrawPages.insertNewByIndex( nIndex );
  }

    /** removes the given page
  */
  static public void removeMasterPage( XComponent xComponent, XDrawPage xDrawPage )
View Full Code Here

        log.println( "adding INSTANCEn as mod relation to environment" );
        try {
            for (int n = 1; n < (2*THRCNT+1) ;n++ ) {
                log.println( "adding INSTANCE" + n
                    +" as mod relation to environment" );
                oDPn.insertNewByIndex(0);
                oDrawPage = (XDrawPage) AnyConverter.toObject(
                        new Type(XDrawPage.class),oDPi.getByIndex(0));
                tEnv.addObjRelation("INSTANCE" + n, oDrawPage);
            }
        } catch (com.sun.star.lang.WrappedTargetException e) {
View Full Code Here

        tEnv.addObjRelation("SecondController", secondController);
        tEnv.addObjRelation("XDispatchProvider.URL",
                                    "slot:27009");

        //Adding relations for DrawingDocumentDrawView
        XDrawPage new_page = the_pages.insertNewByIndex(1);
        tEnv.addObjRelation("DrawPage", new_page);

        log.println("Implementation Name: "+utils.getImplName(oObj));

        XModifiable modify = (XModifiable)
View Full Code Here

        try {
            log.println( "getting Drawpages" );
            XDrawPagesSupplier oDPS = (XDrawPagesSupplier)
            UnoRuntime.queryInterface(XDrawPagesSupplier.class,xSpreadsheetDoc);
            XDrawPages oDP = (XDrawPages) oDPS.getDrawPages();
            oDP.insertNewByIndex(1);
            oDP.insertNewByIndex(2);
            oDrawPage = (XDrawPage) AnyConverter.toObject(
                new Type(XDrawPage.class),oDP.getByIndex(0));
            if (oDrawPage == null)
                log.println("ERROR: could not get DrawPage: null");
View Full Code Here

            log.println( "getting Drawpages" );
            XDrawPagesSupplier oDPS = (XDrawPagesSupplier)
            UnoRuntime.queryInterface(XDrawPagesSupplier.class,xSpreadsheetDoc);
            XDrawPages oDP = (XDrawPages) oDPS.getDrawPages();
            oDP.insertNewByIndex(1);
            oDP.insertNewByIndex(2);
            oDrawPage = (XDrawPage) AnyConverter.toObject(
                new Type(XDrawPage.class),oDP.getByIndex(0));
            if (oDrawPage == null)
                log.println("ERROR: could not get DrawPage: null");
           
View Full Code Here

        // get the drawpage of drawing here
        log.println( "getting Drawpages" );
        XDrawPagesSupplier oDPS = (XDrawPagesSupplier)
            UnoRuntime.queryInterface(XDrawPagesSupplier.class, xSheetDoc);
        oDP = (XDrawPages) oDPS.getDrawPages();
        oDP.insertNewByIndex(1);
        oDP.insertNewByIndex(2);
        oObj = oDP;

        log.println( "creating a new environment for drawpage object" );
        TestEnvironment tEnv = new TestEnvironment( oObj );
View Full Code Here

        log.println( "getting Drawpages" );
        XDrawPagesSupplier oDPS = (XDrawPagesSupplier)
            UnoRuntime.queryInterface(XDrawPagesSupplier.class, xSheetDoc);
        oDP = (XDrawPages) oDPS.getDrawPages();
        oDP.insertNewByIndex(1);
        oDP.insertNewByIndex(2);
        oObj = oDP;

        log.println( "creating a new environment for drawpage object" );
        TestEnvironment tEnv = new TestEnvironment( oObj );
View Full Code Here

        // get the drawpage of drawing here
        log.println( "getting Drawpage" );
        XDrawPagesSupplier oDPS = (XDrawPagesSupplier)
            UnoRuntime.queryInterface(XDrawPagesSupplier.class, xDrawDoc);
        XDrawPages oDPn = oDPS.getDrawPages();
        final XDrawPage fDP2 = oDPn.insertNewByIndex(1);
        XIndexAccess oDPi = (XIndexAccess)
            UnoRuntime.queryInterface(XIndexAccess.class, oDPn);
        XDrawPage oDP = null;
        try {
            oDP = (XDrawPage) AnyConverter.toObject(
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.