C# Class dnSpy.Contracts.Hex.Operations.HexEditorOperations

Hex editor operations
Show file Open project: 0xd4d/dnSpy Class Usage Examples

Public Methods

Method Description
ClearData ( ) : bool

Clears data

CopySelectionBytes ( ) : bool

Copy selection, bytes (as text)

CopySelectionText ( ) : bool

Copy selection, UI text

CopySpecial ( HexCopySpecialKind copyKind ) : bool

Copies text to the clipboard

ExtendSelection ( HexBufferPoint newEnd ) : void

Extend selection

InsertText ( string text ) : bool

Inserts text

MoveCaret ( dnSpy.Contracts.Hex.Formatting.HexViewLine hexLine, double horizontalOffset, bool extendSelection ) : void

Move caret to a line

MoveCaret ( dnSpy.Contracts.Hex.Formatting.HexViewLine hexLine, double horizontalOffset, bool extendSelection, HexMoveToFlags flags ) : void

Move caret to a line

MoveCurrentLineToBottom ( ) : void

Move current line to bottom of the view

MoveCurrentLineToTop ( ) : void

Move current line to top of the view

MoveLineDown ( bool extendSelection ) : void

Move down a line

MoveLineUp ( bool extendSelection ) : void

Move up a line

MoveToBottomOfView ( bool extendSelection ) : void

Move the caret to the bottom of the view

MoveToEndOfDocument ( bool extendSelection ) : void

Move to end of document

MoveToEndOfLine ( bool extendSelection ) : void

Move to the end of the line

MoveToNextCharacter ( bool extendSelection ) : void

Moves the caret to the next character

MoveToNextValidStartEnd ( bool extendSelection ) : void

Move to the next closest start/end position of a block of memory

MoveToNextWord ( bool extendSelection ) : void

Moves the caret to the next word (cell)

MoveToPreviousCharacter ( bool extendSelection ) : void

Moves the caret to the previous character

MoveToPreviousValidStartEnd ( bool extendSelection ) : void

Move to the previous closest start/end position of a block of memory

MoveToPreviousWord ( bool extendSelection ) : void

Moves the caret to the previous word (cell)

MoveToStartOfDocument ( bool extendSelection ) : void

Move to start of document

MoveToStartOfLine ( bool extendSelection ) : void

Move to the start of the line

MoveToTopOfView ( bool extendSelection ) : void

Move the caret to the top of the view

PageDown ( bool extendSelection ) : void

Page down

PageUp ( bool extendSelection ) : void

Page up

Paste ( ) : bool

Paste

PasteSpecial ( HexPasteSpecialKind pasteKind ) : bool

Pastes data from the clipboard

Refresh ( ) : void

Refreshes the screen and clears any read caches

ResetSelection ( ) : void

Reset selection

ScrollColumnLeft ( ) : void

Scoll one column left

ScrollColumnRight ( ) : void

Scoll one column right

ScrollDownAndMoveCaretIfNecessary ( ) : void

Scroll down and move caret so it's within the viewport

ScrollLineBottom ( ) : void

Move current line to the bottom of the view, don't move the caret

ScrollLineCenter ( ) : void

Move current line to the center of the view, don't move the caret

ScrollLineTop ( ) : void

Move current line to the top of the view, don't move the caret

ScrollPageDown ( ) : void

Page down, but don't move caret

ScrollPageUp ( ) : void

Page up, but don't move caret

ScrollUpAndMoveCaretIfNecessary ( ) : void

Scroll up and move caret so it's within the viewport

SelectAll ( ) : void

Select all

SelectAllBytesBlock ( ) : void

Selects all bytes in the current block, unless the caret is in a memory hole

SelectAndMoveCaret ( HexColumnType column, HexBufferPoint anchorPoint, HexBufferPoint activePoint, bool alignPoints ) : void

Selects data and moves the caret

SelectAndMoveCaret ( HexColumnType column, HexBufferPoint anchorPoint, HexBufferPoint activePoint, bool alignPoints, Microsoft.VisualStudio.Text.Editor scrollOptions ) : void

Selects data and moves the caret

SelectCurrentWord ( ) : void

Selects the current word (cell)

SelectLine ( dnSpy.Contracts.Hex.Formatting.HexViewLine viewLine, bool extendSelection ) : void

Selects the line

ShowAllBytes ( ) : void

Shows all bytes (HexBuffer.Span)

ShowOnlySelectedBytes ( ) : void

Shows only the selected bytes

SwapCaretAndAnchor ( ) : void

Swap selection caret and anchor positions

ToggleColumn ( ) : void

Toggles active column

ZoomIn ( ) : void

Zoom in

ZoomOut ( ) : void

Zoom out

ZoomTo ( double zoomLevel ) : void

Zoom to zoomLevel

Protected Methods

Method Description
HexEditorOperations ( ) : dnSpy.Contracts.Hex.Editor

Constructor

Method Details

ClearData() public abstract method

Clears data
public abstract ClearData ( ) : bool
return bool

CopySelectionBytes() public abstract method

Copy selection, bytes (as text)
public abstract CopySelectionBytes ( ) : bool
return bool

CopySelectionText() public abstract method

Copy selection, UI text
public abstract CopySelectionText ( ) : bool
return bool

CopySpecial() public abstract method

Copies text to the clipboard
public abstract CopySpecial ( HexCopySpecialKind copyKind ) : bool
copyKind HexCopySpecialKind What kind of data to copy
return bool

ExtendSelection() public abstract method

Extend selection
public abstract ExtendSelection ( HexBufferPoint newEnd ) : void
newEnd HexBufferPoint New end position
return void

HexEditorOperations() protected method

Constructor
protected HexEditorOperations ( ) : dnSpy.Contracts.Hex.Editor
return dnSpy.Contracts.Hex.Editor

InsertText() public abstract method

Inserts text
public abstract InsertText ( string text ) : bool
text string Text
return bool

MoveCaret() public method

Move caret to a line
public MoveCaret ( dnSpy.Contracts.Hex.Formatting.HexViewLine hexLine, double horizontalOffset, bool extendSelection ) : void
hexLine dnSpy.Contracts.Hex.Formatting.HexViewLine Line
horizontalOffset double Horizontal offset
extendSelection bool true to extend the selection
return void

MoveCaret() public abstract method

Move caret to a line
public abstract MoveCaret ( dnSpy.Contracts.Hex.Formatting.HexViewLine hexLine, double horizontalOffset, bool extendSelection, HexMoveToFlags flags ) : void
hexLine dnSpy.Contracts.Hex.Formatting.HexViewLine Line
horizontalOffset double Horizontal offset
extendSelection bool true to extend the selection
flags HexMoveToFlags Flags
return void

MoveCurrentLineToBottom() public abstract method

Move current line to bottom of the view
public abstract MoveCurrentLineToBottom ( ) : void
return void

MoveCurrentLineToTop() public abstract method

Move current line to top of the view
public abstract MoveCurrentLineToTop ( ) : void
return void

MoveLineDown() public abstract method

Move down a line
public abstract MoveLineDown ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveLineUp() public abstract method

Move up a line
public abstract MoveLineUp ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToBottomOfView() public abstract method

Move the caret to the bottom of the view
public abstract MoveToBottomOfView ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToEndOfDocument() public abstract method

Move to end of document
public abstract MoveToEndOfDocument ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToEndOfLine() public abstract method

Move to the end of the line
public abstract MoveToEndOfLine ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToNextCharacter() public abstract method

Moves the caret to the next character
public abstract MoveToNextCharacter ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToNextValidStartEnd() public abstract method

Move to the next closest start/end position of a block of memory
public abstract MoveToNextValidStartEnd ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToNextWord() public abstract method

Moves the caret to the next word (cell)
public abstract MoveToNextWord ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToPreviousCharacter() public abstract method

Moves the caret to the previous character
public abstract MoveToPreviousCharacter ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToPreviousValidStartEnd() public abstract method

Move to the previous closest start/end position of a block of memory
public abstract MoveToPreviousValidStartEnd ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToPreviousWord() public abstract method

Moves the caret to the previous word (cell)
public abstract MoveToPreviousWord ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToStartOfDocument() public abstract method

Move to start of document
public abstract MoveToStartOfDocument ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToStartOfLine() public abstract method

Move to the start of the line
public abstract MoveToStartOfLine ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

MoveToTopOfView() public abstract method

Move the caret to the top of the view
public abstract MoveToTopOfView ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

PageDown() public abstract method

Page down
public abstract PageDown ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

PageUp() public abstract method

Page up
public abstract PageUp ( bool extendSelection ) : void
extendSelection bool true to extend the selection
return void

Paste() public abstract method

Paste
public abstract Paste ( ) : bool
return bool

PasteSpecial() public abstract method

Pastes data from the clipboard
public abstract PasteSpecial ( HexPasteSpecialKind pasteKind ) : bool
pasteKind HexPasteSpecialKind What kind of data to paste
return bool

Refresh() public abstract method

Refreshes the screen and clears any read caches
public abstract Refresh ( ) : void
return void

ResetSelection() public abstract method

Reset selection
public abstract ResetSelection ( ) : void
return void

ScrollColumnLeft() public abstract method

Scoll one column left
public abstract ScrollColumnLeft ( ) : void
return void

ScrollColumnRight() public abstract method

Scoll one column right
public abstract ScrollColumnRight ( ) : void
return void

ScrollDownAndMoveCaretIfNecessary() public abstract method

Scroll down and move caret so it's within the viewport
public abstract ScrollDownAndMoveCaretIfNecessary ( ) : void
return void

ScrollLineBottom() public abstract method

Move current line to the bottom of the view, don't move the caret
public abstract ScrollLineBottom ( ) : void
return void

ScrollLineCenter() public abstract method

Move current line to the center of the view, don't move the caret
public abstract ScrollLineCenter ( ) : void
return void

ScrollLineTop() public abstract method

Move current line to the top of the view, don't move the caret
public abstract ScrollLineTop ( ) : void
return void

ScrollPageDown() public abstract method

Page down, but don't move caret
public abstract ScrollPageDown ( ) : void
return void

ScrollPageUp() public abstract method

Page up, but don't move caret
public abstract ScrollPageUp ( ) : void
return void

ScrollUpAndMoveCaretIfNecessary() public abstract method

Scroll up and move caret so it's within the viewport
public abstract ScrollUpAndMoveCaretIfNecessary ( ) : void
return void

SelectAll() public abstract method

Select all
public abstract SelectAll ( ) : void
return void

SelectAllBytesBlock() public abstract method

Selects all bytes in the current block, unless the caret is in a memory hole
public abstract SelectAllBytesBlock ( ) : void
return void

SelectAndMoveCaret() public method

Selects data and moves the caret
public SelectAndMoveCaret ( HexColumnType column, HexBufferPoint anchorPoint, HexBufferPoint activePoint, bool alignPoints ) : void
column HexColumnType Column
anchorPoint HexBufferPoint Anchor position
activePoint HexBufferPoint Active position
alignPoints bool true to align the span to include all bytes of the cells
return void

SelectAndMoveCaret() public abstract method

Selects data and moves the caret
public abstract SelectAndMoveCaret ( HexColumnType column, HexBufferPoint anchorPoint, HexBufferPoint activePoint, bool alignPoints, Microsoft.VisualStudio.Text.Editor scrollOptions ) : void
column HexColumnType Column
anchorPoint HexBufferPoint Anchor position
activePoint HexBufferPoint Active position
alignPoints bool true to align the span to include all bytes of the cells
scrollOptions Microsoft.VisualStudio.Text.Editor Scroll options
return void

SelectCurrentWord() public abstract method

Selects the current word (cell)
public abstract SelectCurrentWord ( ) : void
return void

SelectLine() public abstract method

Selects the line
public abstract SelectLine ( dnSpy.Contracts.Hex.Formatting.HexViewLine viewLine, bool extendSelection ) : void
viewLine dnSpy.Contracts.Hex.Formatting.HexViewLine Line
extendSelection bool true to extend the selection
return void

ShowAllBytes() public abstract method

Shows all bytes (HexBuffer.Span)
public abstract ShowAllBytes ( ) : void
return void

ShowOnlySelectedBytes() public abstract method

Shows only the selected bytes
public abstract ShowOnlySelectedBytes ( ) : void
return void

SwapCaretAndAnchor() public abstract method

Swap selection caret and anchor positions
public abstract SwapCaretAndAnchor ( ) : void
return void

ToggleColumn() public abstract method

Toggles active column
public abstract ToggleColumn ( ) : void
return void

ZoomIn() public abstract method

Zoom in
public abstract ZoomIn ( ) : void
return void

ZoomOut() public abstract method

Zoom out
public abstract ZoomOut ( ) : void
return void

ZoomTo() public abstract method

Zoom to zoomLevel
public abstract ZoomTo ( double zoomLevel ) : void
zoomLevel double Zoom level, between 20% and 400% (20.0 and 400.0)
return void