Package ag.ion.bion.officelayer.text

Examples of ag.ion.bion.officelayer.text.ITextTableCell


   * @throws TextException if any error occurs
   *
   * @author Miriam Sutter
   */
  private void cloneRange(ITextTable textTable, ITextTableCellRange textTableCellRange, int count, boolean adoptContent) throws CloneException, TextException {
    ITextTableCell textTableCell = textTable.getCell(0,count);
    IDestinationPosition position = new DestinationPosition(textTableCell);
    textTableCellRange.getCloneService().cloneToPosition(position,adoptContent,null);
  }
View Full Code Here


      if(newTable != null) {
        int rowArrayLength = cellCloneServices.length;
        for (int rows = 0; rows < rowArrayLength; rows++) {
          for (int columns = 0; columns < columnArrayLength ; columns++) {
            ICloneService cellClone = cellCloneServices[rows][columns];
            ITextTableCell textTableCell = newTable.getCell(columnStart + columns, rowStart + rows);
            CloneDestinationPosition destinationCell = new CloneDestinationPosition(textTableCell, textTableCell.getClass());
            cellClone.cloneToPositionNoReturn(destinationCell, adoptContent,propertyKeysContainer);
          }
        }
        if(generateReturnValue) {
          ITextTableCellRange textTableCellRange = newTable.getCellRange(columnStart,rowStart,columnArrayLength,rowArrayLength);
View Full Code Here

  private void getCloneCells() throws CloneException {   
    cellCloneServices = new ICloneService[rowCount][columnCount];   
    for (int i=0;i<rowCount;i++) {
      for (int h=0;h<columnCount;h++){
        try {
          ITextTableCell currentTableCell = textTableCellRange.getCell(h,i);
          cellCloneServices[i][h] = currentTableCell.getCloneService();
        }
        catch(TextException excep) {
          CloneException cloneException =  new CloneException(excep.getMessage());
          cloneException.initCause(excep);
          throw cloneException;
View Full Code Here

  public short compareRange(ITextRange textRangeToCompare) throws TextException {
    try {
      ITextRange thisCompareRange = this;
      if(document instanceof ITextDocument) {
        ITextDocument textDocument = (ITextDocument)document;
        ITextTableCell thisCompareRangeCell = thisCompareRange.getCell();
        ITextTableCell textRangeToCompareCell = textRangeToCompare.getCell();
        if(thisCompareRangeCell != null && textRangeToCompareCell == null) {
          XTextContent textTable = thisCompareRangeCell.getTextTable().getXTextContent();  
          XSelectionSupplier selectionSupplier = (XSelectionSupplier)UnoRuntime.queryInterface(XSelectionSupplier.class, textDocument.getXTextDocument().getCurrentController());
          selectionSupplier.select(textTable);
          XTextViewCursorSupplier xTextViewCursorSupplier = (XTextViewCursorSupplier)UnoRuntime.queryInterface(XTextViewCursorSupplier.class, textDocument.getXTextDocument().getCurrentController());
          xTextViewCursorSupplier.getViewCursor().goLeft((short)1,false);
          thisCompareRange = textDocument.getViewCursorService().getViewCursor().getTextCursorFromEnd().getEnd();
        }
        else if(textRangeToCompareCell != null && thisCompareRangeCell == null) {
          XTextContent textTable = textRangeToCompareCell.getTextTable().getXTextContent();  
          XSelectionSupplier selectionSupplier = (XSelectionSupplier)UnoRuntime.queryInterface(XSelectionSupplier.class, textDocument.getXTextDocument().getCurrentController());
          selectionSupplier.select(textTable);
          XTextViewCursorSupplier xTextViewCursorSupplier = (XTextViewCursorSupplier)UnoRuntime.queryInterface(XTextViewCursorSupplier.class, textDocument.getXTextDocument().getCurrentController());
          xTextViewCursorSupplier.getViewCursor().goLeft((short)1,false);
          textRangeToCompare = textDocument.getViewCursorService().getViewCursor().getTextCursorFromEnd().getEnd();
        }
        else if(thisCompareRangeCell != null && textRangeToCompareCell != null) {
          XTextContent thisCompareRangeTable = thisCompareRangeCell.getTextTable().getXTextContent();
          XTextContent textRangeToCompareTable = textRangeToCompareCell.getTextTable().getXTextContent();
          boolean sameTable = UnoRuntime.areSame(
              thisCompareRangeTable,textRangeToCompareTable);
          if(sameTable) {
            ITextTableCellName thisCompareRangeCellName = thisCompareRangeCell.getName();
            ITextTableCellName textRangeToCompareCellName = textRangeToCompareCell.getName();
            int thisCompareRangeCellRow = thisCompareRangeCellName.getRowIndex();
            int thisCompareRangeCellCol = thisCompareRangeCellName.getColumnIndex();
            int textRangeToCompareCellRow = textRangeToCompareCellName.getRowIndex();
            int textRangeToCompareCellCol = textRangeToCompareCellName.getColumnIndex();
            if(thisCompareRangeCellRow < textRangeToCompareCellRow)
View Full Code Here

      if (newTable != null) {
        int rowArrayLength = cellCloneServices.length;
        for (int rows = 0; rows < rowArrayLength; rows++) {
          for (int columns = 0; columns < columnArrayLength; columns++) {
            ICloneService cellClone = cellCloneServices[rows][columns];
            ITextTableCell textTableCell = newTable.getCell(
                columnStart + columns, rowStart + rows);
            CloneDestinationPosition destinationCell = new CloneDestinationPosition(
                textTableCell, textTableCell.getClass());
            cellClone.cloneToPositionNoReturn(destinationCell,
                adoptContent, propertyKeysContainer);
          }
        }
        if (generateReturnValue) {
View Full Code Here

  private void getCloneCells() throws CloneException {
    cellCloneServices = new ICloneService[rowCount][columnCount];
    for (int i = 0; i < rowCount; i++) {
      for (int h = 0; h < columnCount; h++) {
        try {
          ITextTableCell currentTableCell = textTableCellRange
              .getCell(h, i);
          cellCloneServices[i][h] = currentTableCell
              .getCloneService();
        } catch (TextException excep) {
          CloneException cloneException = new CloneException(excep
              .getMessage());
          cloneException.initCause(excep);
View Full Code Here

    for (int i = 0; i < tableNumber; i++) {
      help = help + textTableManagement.getTextTable(i).getRowCount();
    }
    rowNumber = rowNumber - help + 1;

    ITextTableCell textTableCell = textTableManagement.getTextTable(
        tableNumber).getCell(
        TextTableCellNameHelper.getColumnCharacter(cellName)
            + rowNumber);
    ETextTableCell tableCell = new ETextTableCell(textTableCell, cellName,
        this);
View Full Code Here

   * @author Miriam Sutter
   */
  private void cloneRange(ITextTable textTable,
      ITextTableCellRange textTableCellRange, int count,
      boolean adoptContent) throws CloneException, TextException {
    ITextTableCell textTableCell = textTable.getCell(0, count);
    IDestinationPosition position = new DestinationPosition(textTableCell);
    textTableCellRange.getCloneService().cloneToPosition(position,
        adoptContent, null);
  }
View Full Code Here

            textTable.getRow(rows).getAutoHeight());

        int columnArrayLength = cellCloneServices[rows].length;
        for (int columns = 0; columns < columnArrayLength; columns++) {
          ICloneService cellClone = cellCloneServices[rows][columns];
          ITextTableCell textTableCell = newTable.getCell(columns,
              rows);
          CloneDestinationPosition destinationCell = new CloneDestinationPosition(
              textTableCell, textTableCell.getClass());
          cellClone.cloneToPositionNoReturn(destinationCell,
              adoptContent, propertyKeysContainer);
        }
      }
View Full Code Here

      tablePropertyStore = new TextTablePropertyStore(textTable);
      cellCloneServices = new ICloneService[rowCount][columnCount];

      for (int i = 0; i < rowCount; i++) {
        for (int h = 0; h < columnCount; h++) {
          ITextTableCell currentTableCell = textTable.getCell(h, i);
          cellCloneServices[i][h] = currentTableCell
              .getCloneService();
        }
      }
    } catch (TextException exception) {
      CloneException cloneException = new CloneException(exception
View Full Code Here

TOP

Related Classes of ag.ion.bion.officelayer.text.ITextTableCell

Copyright © 2018 www.massapicom. 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.