Package com._1c.g5.v8.dt.moxel.util
Class ClipboardPasteUtil
java.lang.Object
com._1c.g5.v8.dt.moxel.util.ClipboardPasteUtil
Utils for pasting from the clipboard
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptioncopyDrawingFromClipboard(Drawing drawing, SheetAccessor document, SheetAccessor sheet, long mask, int nFirstCol, int nFirstRow, boolean calcParameters, boolean oneLocale) static AreagetClipboardSheetSelection(MoxelDescriptor descriptor) Get selection area of clipboard sheet, specified by descriptorstatic SpreadsheetRectgetDrawingsSelectionRect(List<Drawing> drawings) Get total rect, containing all of the drawings' position rectsstatic SelectiongetNormalizedSelection(SheetAccessor sheet, Selection selection, UUID id, int sizeX, int sizeY) Get normalized selectiongetNormalizedSelectionToPaste(SheetAccessor sheet, List<Selection> selections, UUID id, int sizeX, int sizeY) Get list of normalized selections for pastingstatic intgetSelectionHeight(Selection selection, SheetAccessor sheet) Get height of specified selectionstatic intgetSelectionWidth(Selection selection, SheetAccessor sheet) Get width of specified selectionstatic booleanisSelectionAcceptableToFill(Area area, Selection selection) Check if it's possible to fill the selection with specified areastatic booleanisSelectionsAcceptableToFill(Area sel, List<Selection> selections) Check if all of the listed selections are acceptable to fillstatic SelectionmakeSelectionCopy(Selection selection) Make copy of specified selectionstatic voidpasteSelectionDrawings(Selection selection, List<Drawing> selectedDrawings, SheetAccessor document, SheetAccessor sheet, List<Drawing> oldDrawings, IPositionHolder positionHolder) Paste selected drawingsstatic voidpasteSheetCells(PasteSpecialOptions pasteOptions, boolean oneLocale, int sizeX, int sizeY, Selection selection, SheetAccessor srcSheet, SheetAccessor dstSheet) Paste sheet into specified selection.static voidunmergeSelection(Selection selection, SheetAccessor sheet) Make correct unmerges into specified selection
-
Field Details
-
STR_PROPERTIES_SHIFT
public static final int STR_PROPERTIES_SHIFT- See Also:
-
-
Method Details
-
getSelectionHeight
Get height of specified selection- Parameters:
selection-sheet-- Returns:
-
getSelectionWidth
Get width of specified selection- Parameters:
selection-sheet-- Returns:
-
getNormalizedSelection
public static Selection getNormalizedSelection(SheetAccessor sheet, Selection selection, UUID id, int sizeX, int sizeY) Get normalized selection- Parameters:
sheet-selection-id-sizeX-sizeY-- Returns:
-
getNormalizedSelectionToPaste
public static List<Selection> getNormalizedSelectionToPaste(SheetAccessor sheet, List<Selection> selections, UUID id, int sizeX, int sizeY) Get list of normalized selections for pasting- Parameters:
sheet-selections-id-sizeX-sizeY-- Returns:
-
getClipboardSheetSelection
Get selection area of clipboard sheet, specified by descriptor- Parameters:
descriptor-- Returns:
-
makeSelectionCopy
Make copy of specified selection- Parameters:
selection-- Returns:
-
isSelectionAcceptableToFill
Check if it's possible to fill the selection with specified area- Parameters:
area-selection-- Returns:
-
isSelectionsAcceptableToFill
Check if all of the listed selections are acceptable to fill- Parameters:
sel-selections-- Returns:
-
pasteSheetCells
public static void pasteSheetCells(PasteSpecialOptions pasteOptions, boolean oneLocale, int sizeX, int sizeY, Selection selection, SheetAccessor srcSheet, SheetAccessor dstSheet) Paste sheet into specified selection.- Parameters:
pasteOptions-PasteSpecialOptions, must not benulloneLocale-truein case of using single language,falseotherwisesizeX- horizontal size of document being pastedsizeY- vertical size of document being pastedselection- paste area, must not benullsrcSheet- source sheet, must not benulldstSheet- destination sheet, must not benull
-
pasteSelectionDrawings
public static void pasteSelectionDrawings(Selection selection, List<Drawing> selectedDrawings, SheetAccessor document, SheetAccessor sheet, List<Drawing> oldDrawings, IPositionHolder positionHolder) Paste selected drawings- Parameters:
selection-document-sheet-
-
getDrawingsSelectionRect
Get total rect, containing all of the drawings' position rects- Parameters:
drawings-- Returns:
-
unmergeSelection
Make correct unmerges into specified selection- Parameters:
selection-sheet-
-
copyDrawingFromClipboard
public Drawing copyDrawingFromClipboard(Drawing drawing, SheetAccessor document, SheetAccessor sheet, long mask, int nFirstCol, int nFirstRow, boolean calcParameters, boolean oneLocale)
-