Class ApplyFontOperation
- java.lang.Object
-
- org.eclipse.core.commands.operations.AbstractOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.BaseOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.ChangeCellsOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.BaseApplyFormatOperation
-
- com._1c.g5.v8.dt.moxel.ui.operations.ApplyFontOperation
-
- All Implemented Interfaces:
org.eclipse.core.commands.operations.IUndoableOperation
public class ApplyFontOperation extends BaseApplyFormatOperation
Operation of applying font
-
-
Field Summary
-
Fields inherited from class com._1c.g5.v8.dt.moxel.ui.operations.BaseApplyFormatOperation
applyToMissed
-
Fields inherited from class com._1c.g5.v8.dt.moxel.ui.operations.ChangeCellsOperation
changeContentOrFormat, oldCells, positionHolder, selection, sizeHelper
-
Fields inherited from class com._1c.g5.v8.dt.moxel.ui.operations.BaseOperation
sheet
-
-
Constructor Summary
Constructors Constructor Description ApplyFontOperation(String label, org.eclipse.core.commands.operations.IUndoContext undoContext, SheetAccessor sheet, Selection selection, Font fontToApply, int propertiesToApply, PositionHolder positionHolder)
Creates new instance ofApplyFontOperation
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
applyToCell(Map<Integer,Integer> convertedFormatsApply, int rowIndex, int columnIndex, boolean applyFormat)
Apply to cellprotected void
applyToCell(Map<Integer,Integer> convertedFormatsApply, Cell cell, boolean applyFormat)
Apply to cellprotected Integer
getConvertedFormatIndex(Map<Integer,Integer> convertedFormats, int srcFormatIndex, boolean applyFormat)
Get converted format indexprotected boolean
needCleaCache()
Check whether there is a need to clean cache-
Methods inherited from class com._1c.g5.v8.dt.moxel.ui.operations.BaseApplyFormatOperation
performAction, updateCells
-
Methods inherited from class com._1c.g5.v8.dt.moxel.ui.operations.ChangeCellsOperation
execute, redo, undo, updateCacheState
-
-
-
-
Constructor Detail
-
ApplyFontOperation
public ApplyFontOperation(String label, org.eclipse.core.commands.operations.IUndoContext undoContext, SheetAccessor sheet, Selection selection, Font fontToApply, int propertiesToApply, PositionHolder positionHolder)
Creates new instance ofApplyFontOperation
- Parameters:
label
- operation labelundoContext
- undo contextsheet
-SheetAccessor
selection
-Selection
fontToApply
-Font
propertiesToApply
- properties maskpositionHolder
-PositionHolder
-
-
Method Detail
-
getConvertedFormatIndex
protected Integer getConvertedFormatIndex(Map<Integer,Integer> convertedFormats, int srcFormatIndex, boolean applyFormat)
Description copied from class:BaseApplyFormatOperation
Get converted format index- Specified by:
getConvertedFormatIndex
in classBaseApplyFormatOperation
- Parameters:
convertedFormats
- collection of converted format indexessrcFormatIndex
- format index to be convertedapplyFormat
- need to apply format- Returns:
- converted format index
-
applyToCell
protected void applyToCell(Map<Integer,Integer> convertedFormatsApply, Cell cell, boolean applyFormat)
Description copied from class:BaseApplyFormatOperation
Apply to cell- Specified by:
applyToCell
in classBaseApplyFormatOperation
- Parameters:
convertedFormatsApply
- collection of converted format indexescell
- cell to apply format toapplyFormat
- need to apply format
-
applyToCell
protected void applyToCell(Map<Integer,Integer> convertedFormatsApply, int rowIndex, int columnIndex, boolean applyFormat)
Description copied from class:BaseApplyFormatOperation
Apply to cell- Specified by:
applyToCell
in classBaseApplyFormatOperation
- Parameters:
convertedFormatsApply
- collection of converted format indexesrowIndex
- row indexcolumnIndex
- columns indexapplyFormat
- need to apply format
-
needCleaCache
protected boolean needCleaCache()
Description copied from class:ChangeCellsOperation
Check whether there is a need to clean cache- Overrides:
needCleaCache
in classChangeCellsOperation
- Returns:
- check result
-
-