Examples of XTableRows


Examples of com.sun.star.table.XTableRows

        }

        XColumnRowRange oColumnRowRange = (XColumnRowRange)
            UnoRuntime.queryInterface(XColumnRowRange.class, xSpreadsheet);

        XTableRows oRows = (XTableRows) oColumnRowRange.getRows();
        oObj = oRows;

        log.println("creating a new environment for object");

        XEnumerationAccess ea = (XEnumerationAccess)
View Full Code Here

Examples of com.sun.star.table.XTableRows

        bIsGroupColumn = true;
        XTextRange xTextCell;
        XCell xCell;
        getTableColumns(TableName);

        XTableRows xRows = null;
        try
        {
            xRows = xTextTable.getRows();
        }
        catch (java.lang.NullPointerException e)
        {
            e.printStackTrace();
// TODO: handle the nullpointer right
//                return;
        }
        for (int n = 0; n < xTableColumns.getCount(); n++)
        {
            for (int m = 0; m < xRows.getCount(); m++)
            {
                xCell = xCellRange.getCellByPosition(n, m);
                xTextCell = (XTextRange) UnoRuntime.queryInterface(XTextRange.class, xCell);
                String CompString = TableName.substring(4);
                XTextCursor xLocCellCursor = TextDocument.createTextCursor(xCell);
View Full Code Here

Examples of com.sun.star.table.XTableRows

            oObj.filter(desc);

            XColumnRowRange oColumnRowRange = (XColumnRowRange) UnoRuntime.queryInterface(
                                                      XColumnRowRange.class,
                                                      oSheet);
            XTableRows oRows = (XTableRows) oColumnRowRange.getRows();
            XPropertySet rowProp = (XPropertySet) UnoRuntime.queryInterface(
                                           XPropertySet.class,
                                           oRows.getByIndex(0));
            boolean locRes = ((Boolean) rowProp.getPropertyValue("IsVisible")).booleanValue();

            if (locRes) {
                log.println("Row 1 should be invisible after filter()");
                res &= false;
            } else {
                res &= true;
            }

            rowProp = (XPropertySet) UnoRuntime.queryInterface(
                              XPropertySet.class, oRows.getByIndex(1));
            locRes = ((Boolean) rowProp.getPropertyValue("IsVisible")).booleanValue();

            if (locRes) {
                log.println("Row 2 should be invisible after filter()");
                res &= false;
View Full Code Here

Examples of com.sun.star.table.XTableRows

                log.println("Cells were already inserted. "+
                    "Delete old cells now");
                XColumnRowRange oColumnRowRange = (XColumnRowRange)
                    UnoRuntime.queryInterface(XColumnRowRange.class, oSheet);

                XTableRows oRows = (XTableRows) oColumnRowRange.getRows();
                oRows.removeByIndex(21,1);
            }
            CellRangeAddress sSrc = new CellRangeAddress(iSheet, 0, 21, 5, 21);
            oObj.insertCells (sSrc, CellInsertMode.DOWN) ;

            // check the result
View Full Code Here

Examples of com.sun.star.table.XTableRows

    if(textTableCellRange == null)
      return 0;
    try {
     
      XTextTable xTextTable = (XTextTable)textTableCellRange.getCell(0,0).getTextTable().getXTextContent();
      XTableRows tableRows = xTextTable.getRows();
      Object row = tableRows.getByIndex(textTableCellRange.getRangeName().getRangeStartRowIndex());
      XPropertySet propertySetRow = (XPropertySet)UnoRuntime.queryInterface(XPropertySet.class, row);
      Integer rowHeight = (Integer)propertySetRow.getPropertyValue("Height");
      return rowHeight.intValue();
    }
    catch (Exception exception) {
View Full Code Here

Examples of com.sun.star.table.XTableRows

  public void setHeight(int height) {
    if(textTableCellRange == null)
      return;
    try {     
      XTextTable xTextTable = (XTextTable)textTableCellRange.getCell(0,0).getTextTable().getXTextContent();
      XTableRows tableRows = xTextTable.getRows();
      Object row = tableRows.getByIndex(textTableCellRange.getRangeName().getRangeStartRowIndex());
      XPropertySet propertySetRow = (XPropertySet)UnoRuntime.queryInterface(XPropertySet.class, row);
      propertySetRow.setPropertyValue("Height",new Integer(height));
    }
    catch (Exception exception) {
    }
View Full Code Here

Examples of com.sun.star.table.XTableRows

  public boolean getAutoHeight() {
    if(textTableCellRange == null)
      return false;
    try {     
      XTextTable xTextTable = (XTextTable)textTableCellRange.getCell(0,0).getTextTable().getXTextContent();
      XTableRows tableRows = xTextTable.getRows();
      int rowIndex = textTableCellRange.getRangeName().getRangeStartRowIndex();
      Object row = tableRows.getByIndex(rowIndex);
      XPropertySet propertySetRow = (XPropertySet)UnoRuntime.queryInterface(XPropertySet.class, row);
      Boolean rowAutoHeight = (Boolean)propertySetRow.getPropertyValue("IsAutoHeight");     
      return rowAutoHeight.booleanValue();
    }
    catch (Exception exception) {
View Full Code Here

Examples of com.sun.star.table.XTableRows

  public void setAutoHeight(boolean autoHeight) {
    if(textTableCellRange == null)
      return;
    try {     
      XTextTable xTextTable = (XTextTable)textTableCellRange.getCell(0,0).getTextTable().getXTextContent();
      XTableRows tableRows = xTextTable.getRows();
      Object row = tableRows.getByIndex(textTableCellRange.getRangeName().getRangeStartRowIndex());
      XPropertySet propertySetRow = (XPropertySet)UnoRuntime.queryInterface(XPropertySet.class, row);
      propertySetRow.setPropertyValue("IsAutoHeight",new Boolean(autoHeight));
    }
    catch (Exception exception) {
    }
View Full Code Here

Examples of com.sun.star.table.XTableRows

      return 0;
    try {

      XTextTable xTextTable = (XTextTable) textTableCellRange.getCell(0,
          0).getTextTable().getXTextContent();
      XTableRows tableRows = xTextTable.getRows();
      Object row = tableRows.getByIndex(textTableCellRange.getRangeName()
          .getRangeStartRowIndex());
      XPropertySet propertySetRow = (XPropertySet) UnoRuntime
          .queryInterface(XPropertySet.class, row);
      Integer rowHeight = (Integer) propertySetRow
          .getPropertyValue("Height");
View Full Code Here

Examples of com.sun.star.table.XTableRows

    if (textTableCellRange == null)
      return;
    try {
      XTextTable xTextTable = (XTextTable) textTableCellRange.getCell(0,
          0).getTextTable().getXTextContent();
      XTableRows tableRows = xTextTable.getRows();
      Object row = tableRows.getByIndex(textTableCellRange.getRangeName()
          .getRangeStartRowIndex());
      XPropertySet propertySetRow = (XPropertySet) UnoRuntime
          .queryInterface(XPropertySet.class, row);
      propertySetRow.setPropertyValue("Height", new Integer(height));
    } catch (Exception exception) {
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.