Interface SheetHandler

    • Method Detail

      • onCellClick

        void onCellClick​(int column,
                         int row,
                         String value,
                         boolean shiftPressed,
                         boolean metaOrCtrlPressed,
                         boolean updateToActionHandler)
      • onLinkCellClick

        void onLinkCellClick​(int column,
                             int row)
      • onCellDoubleClick

        void onCellDoubleClick​(int column,
                               int row,
                               String value)
      • onRowHeaderClick

        void onRowHeaderClick​(int row,
                              boolean shiftPressed,
                              boolean metaOrCrtlPressed)
      • onColumnHeaderClick

        void onColumnHeaderClick​(int row,
                                 boolean shiftPressed,
                                 boolean metaOrCrtlPressed)
      • onScrollViewChanged

        void onScrollViewChanged​(int firstRow,
                                 int lastRow,
                                 int firstColumn,
                                 int lastColumn)
      • onSelectionIncreasePainted

        void onSelectionIncreasePainted​(int c1,
                                        int c2,
                                        int r1,
                                        int r2)
      • onSelectionDecreasePainted

        void onSelectionDecreasePainted​(int colEdgeIndex,
                                        int rowEdgeIndex)
      • onFinishedSelectingCellsWithDrag

        void onFinishedSelectingCellsWithDrag​(int col1,
                                              int col2,
                                              int row1,
                                              int row2)
      • onSelectingCellsWithDrag

        void onSelectingCellsWithDrag​(int parsedCol,
                                      int parsedRow)
      • onCellInputBlur

        void onCellInputBlur​(String value)
      • onCellInputFocus

        void onCellInputFocus()
      • onCellInputCancel

        void onCellInputCancel()
      • onCellInputEnter

        void onCellInputEnter​(String value,
                              boolean shift)
      • onCellInputTab

        void onCellInputTab​(String value,
                            boolean shift)
      • onCellInputValueChange

        void onCellInputValueChange​(String value)
      • onSheetKeyPress

        void onSheetKeyPress​(com.google.gwt.dom.client.NativeEvent nativeEvent,
                             String enteredCharacter)
      • getRowBufferSize

        int getRowBufferSize()
      • getColumnBufferSize

        int getColumnBufferSize()
      • getDefaultRowHeight

        float getDefaultRowHeight()
        default row height in points (?)
        Returns:
      • getDefinedRows

        int getDefinedRows()
        Number of defined rows in the spreadsheet
      • getColWidths

        int[] getColWidths()
      • getRowHeight

        float getRowHeight​(int row)
        Height of a row in points (pt) including bottom border. Rows are indexed from 1 to getRows(). Returns 0 for hidden rows.
      • getColWidth

        int getColWidth​(int col)
        Width of a column in pixels including right border. Columns are indexed from 1 to getColumns(). Returns 0 for hidden columns.
      • getColWidthActual

        int getColWidthActual​(int col)
        Returns 0 for hidden columns, otherwise same as getColWidth(int) .
        Parameters:
        col - 1-based
        Returns:
        width (px)
      • getColHeader

        String getColHeader​(int col)
        Get header of a column as HTML. Columns are indexed from 1 to getColumns().
      • getRowHeader

        String getRowHeader​(int row)
        Get header of a row as HTML. Rows are indexed from 1 to getRows().
      • getMaxColumns

        int getMaxColumns()
        The maximum amount of columns that are visible
        Returns:
      • getMaxRows

        int getMaxRows()
        The maximum amount of rows that are visible
        Returns:
      • getRowHeightsPX

        int[] getRowHeightsPX()
      • getConditionalFormattingStyles

        Map<Integer,​String> getConditionalFormattingStyles()
      • isColumnHidden

        boolean isColumnHidden​(int i)
        Parameters:
        i - 1-based
        Returns:
        true if the column is hidden
      • isRowHidden

        boolean isRowHidden​(int i)
        Parameters:
        i - 1-based
        Returns:
        true if the row is hidden
      • onCellRightClick

        void onCellRightClick​(com.google.gwt.dom.client.NativeEvent nativeEvent,
                              int column,
                              int row)
        Called on right mouse button click on top of some cell.
        Parameters:
        nativeEvent -
        column - 1-based
        row - 1-based
      • onRowHeaderRightClick

        void onRowHeaderRightClick​(com.google.gwt.dom.client.NativeEvent nativeEvent,
                                   int rowIndex)
        Called on right mouse button click on top of a row header
        Parameters:
        nativeEvent -
        rowIndex - 1-based
      • onColumnHeaderRightClick

        void onColumnHeaderRightClick​(com.google.gwt.dom.client.NativeEvent nativeEvent,
                                      int columnIndex)
        Called on right mouse button click on top of a column header
        Parameters:
        nativeEvent -
        columnIndex - 1-based
      • hasCustomContextMenu

        boolean hasCustomContextMenu()
      • canResizeColumn

        boolean canResizeColumn()
      • canResizeRow

        boolean canResizeRow()
      • onRowsResized

        void onRowsResized​(Map<Integer,​Float> newSizes)
        Map containing 1-based row indexes and new sizes as pt
      • onColumnsResized

        void onColumnsResized​(Map<Integer,​Integer> newSizes)
        Map containing 1-based column indexes and new sizes as pt
      • onRowHeaderDoubleClick

        void onRowHeaderDoubleClick​(int rowIndex)
        Parameters:
        rowIndex - 1-based
      • onColumnHeaderResizeDoubleClick

        void onColumnHeaderResizeDoubleClick​(int columnIndex)
        Parameters:
        columnIndex - 1-based
      • getMergedRegion

        MergedRegion getMergedRegion​(int col,
                                     int row)
        Returns the merged region that this cell belongs to.
        Parameters:
        col -
        row -
        Returns:
      • getMergedRegionStartingFrom

        MergedRegion getMergedRegionStartingFrom​(int col,
                                                 int row)
        Params 1-based
        Parameters:
        col - starting column of merged cell
        row - starting row of merged cell
        Returns:
      • onRedoPress

        void onRedoPress()
      • onUndoPress

        void onUndoPress()
      • setCellStyleWidthRatios

        void setCellStyleWidthRatios​(HashMap<Integer,​Float> cellStyleWidthRatioMap)
      • onSheetPaste

        void onSheetPaste​(String text)
        Called when user pastes something inside the sheet.
        Parameters:
        text - the pasted content
      • clearSelectedCellsOnCut

        void clearSelectedCellsOnCut()
        Called after successful cut operation; currently selected cells should be cleared
      • updateCellComment

        void updateCellComment​(String text,
                               int col,
                               int row)
      • selectAll

        void selectAll()
      • isSheetProtected

        boolean isSheetProtected()
      • isColProtected

        boolean isColProtected​(int col)
      • isRowProtected

        boolean isRowProtected​(int row)