C# Класс Be.Windows.Forms.HexBox

Наследование: System.Windows.Forms.Control
Показать файл Открыть проект Примеры использования класса

Private Properties

Свойство Тип Описание
ActivateEmptyKeyInterpreter void
ActivateKeyInterpreter void
ActivateStringKeyInterpreter void
BasePreProcessMessage bool
CheckCurrentLineChanged void
CheckCurrentPositionInLineChanged void
ConvertByteToHex string
ConvertBytesToHex string
ConvertHexToByte bool
ConvertHexToBytes byte[]
CreateCaret void
DestroyCaret void
FromScrollPos long
GetBytePointF System.Drawing.PointF
GetBytePointF System.Drawing.PointF
GetByteStringPointF System.Drawing.PointF
GetCopyData byte[]
GetDefaultForeColor Color
GetGridBytePoint Point
GetHexBytePositionInfo BytePositionInfo
GetStringBytePositionInfo BytePositionInfo
InternalSelect void
PaintCurrentByteSign void
PaintCurrentBytesSign void
PaintHex void
PaintHexAndStringView void
PaintHexString void
PaintHexStringSelected void
PaintLineInfo void
PerformScrollLineDown void
PerformScrollLineUp void
PerformScrollLines void
PerformScrollPageDown void
PerformScrollPageUp void
PerformScrollThumbTrack void
PerformScrollThumpPosition void
PerformScrollToLine void
PreProcessMessage bool
ReleaseSelection void
SetCaretPosition void
SetHorizontalByteCount void
SetPosition void
SetPosition void
SetSelectionLength void
SetVerticalByteCount void
ToScrollMax int
ToScrollPos int
UpdateCaret void
UpdateRectanglePositioning void
UpdateScrollSize void
UpdateVScroll void
UpdateVisibilityBytes void
_byteProvider_LengthChanged void
_vScrollBar_Scroll void

Открытые методы

Метод Описание
AbortFind ( ) : void

Aborts a working Find method.

CanCopy ( ) : bool

Return true if Copy method could be invoked.

CanCut ( ) : bool

Return true if Cut method could be invoked.

CanPaste ( ) : bool

Return true if Paste method could be invoked.

CanPasteHex ( ) : bool

Return true if PasteHex method could be invoked.

CanSelectAll ( ) : bool

Returns true if Select method could be invoked.

Copy ( ) : void

Copies the current selection in the hex box to the Clipboard.

CopyHex ( ) : void

Copies the current selection in the hex box to the Clipboard in hex format.

Cut ( ) : void

Moves the current selection in the hex box to the Clipboard.

Find ( byte bytes, long startIndex ) : long

Searches the current ByteProvider

HexBox ( ) : System

Initializes a new instance of a HexBox class.

Paste ( ) : void

Replaces the current selection in the hex box with the contents of the Clipboard.

PasteHex ( ) : void

Replaces the current selection in the hex box with the hex string data of the Clipboard.

ScrollByteIntoView ( ) : void

Scrolls the selection start byte into view

ScrollByteIntoView ( long index ) : void

Scrolls the specific byte into view

Select ( long start, long length ) : void

Selects the hex box.

SelectAll ( ) : void

Selects all bytes.

Защищенные методы

Метод Описание
OnBorderStyleChanged ( EventArgs e ) : void

Raises the BorderStyleChanged event.

OnByteProviderChanged ( EventArgs e ) : void

Raises the ByteProviderChanged event.

OnBytesPerLineChanged ( EventArgs e ) : void

Raises the BytesPerLineChanged event.

OnCopied ( EventArgs e ) : void

Raises the Copied event.

OnCopiedHex ( EventArgs e ) : void

Raises the CopiedHex event.

OnCurrentLineChanged ( EventArgs e ) : void

Raises the CurrentLineChanged event.

OnCurrentPositionInLineChanged ( EventArgs e ) : void

Raises the CurrentPositionInLineChanged event.

OnGotFocus ( EventArgs e ) : void

Raises the GotFocus event.

OnHexCasingChanged ( EventArgs e ) : void

Raises the HexCasingChanged event.

OnHorizontalByteCountChanged ( EventArgs e ) : void

Raises the HorizontalByteCountChanged event.

OnInsertActiveChanged ( EventArgs e ) : void

Raises the InsertActiveChanged event.

OnLineInfoVisibleChanged ( EventArgs e ) : void

Raises the LineInfoVisibleChanged event.

OnLostFocus ( EventArgs e ) : void

Raises the LostFocus event.

OnMouseDown ( MouseEventArgs e ) : void

Raises the MouseDown event.

OnMouseWheel ( MouseEventArgs e ) : void

Raises the MouseWhell event

OnPaint ( PaintEventArgs e ) : void

Paints the hex box.

OnPaintBackground ( PaintEventArgs e ) : void

Paints the background.

OnReadOnlyChanged ( EventArgs e ) : void

Raises the ReadOnlyChanged event.

OnResize ( EventArgs e ) : void

Raises the Resize event.

OnSelectionLengthChanged ( EventArgs e ) : void

Raises the SelectionLengthChanged event.

OnSelectionStartChanged ( EventArgs e ) : void

Raises the SelectionStartChanged event.

OnStringViewVisibleChanged ( EventArgs e ) : void

Raises the StringViewVisibleChanged event.

OnUseFixedBytesPerLineChanged ( EventArgs e ) : void

Raises the UseFixedBytesPerLineChanged event.

OnVScrollBarVisibleChanged ( EventArgs e ) : void

Raises the VScrollBarVisibleChanged event.

OnVerticalByteCountChanged ( EventArgs e ) : void

Raises the VerticalByteCountChanged event.

Приватные методы

Метод Описание
ActivateEmptyKeyInterpreter ( ) : void
ActivateKeyInterpreter ( ) : void
ActivateStringKeyInterpreter ( ) : void
BasePreProcessMessage ( Message &m ) : bool
CheckCurrentLineChanged ( ) : void
CheckCurrentPositionInLineChanged ( ) : void
ConvertByteToHex ( byte b ) : string

Converts the byte to a hex string. For example: "10" = "0A";

ConvertBytesToHex ( byte data ) : string

Converts a byte array to a hex string. For example: {10,11} = "0A 0B"

ConvertHexToByte ( string hex, byte &b ) : bool
ConvertHexToBytes ( string hex ) : byte[]

Converts the hex string to an byte array. The hex string must be separated by a space char ' '. If there is any invalid hex information in the string the result will be null.

CreateCaret ( ) : void
DestroyCaret ( ) : void
FromScrollPos ( int value ) : long
GetBytePointF ( Point gp ) : PointF
GetBytePointF ( long byteIndex ) : PointF
GetByteStringPointF ( Point gp ) : PointF
GetCopyData ( ) : byte[]
GetDefaultForeColor ( ) : Color
GetGridBytePoint ( long byteIndex ) : Point
GetHexBytePositionInfo ( Point p ) : BytePositionInfo
GetStringBytePositionInfo ( Point p ) : BytePositionInfo
InternalSelect ( long start, long length ) : void
PaintCurrentByteSign ( Graphics g, Rectangle rec ) : void
PaintCurrentBytesSign ( Graphics g ) : void
PaintHex ( Graphics g, long startByte, long endByte ) : void
PaintHexAndStringView ( Graphics g, long startByte, long endByte ) : void
PaintHexString ( Graphics g, byte b, Brush brush, Point gridPoint ) : void
PaintHexStringSelected ( Graphics g, byte b, Brush brush, Brush brushBack, Point gridPoint ) : void
PaintLineInfo ( Graphics g, long startByte, long endByte ) : void
PerformScrollLineDown ( ) : void
PerformScrollLineUp ( ) : void
PerformScrollLines ( int lines ) : void
PerformScrollPageDown ( ) : void
PerformScrollPageUp ( ) : void
PerformScrollThumbTrack ( object sender, EventArgs e ) : void

Performs the thumbtrack scrolling after an delay.

PerformScrollThumpPosition ( long pos ) : void
PerformScrollToLine ( long pos ) : void
PreProcessMessage ( Message &m ) : bool
ReleaseSelection ( ) : void
SetCaretPosition ( Point p ) : void
SetHorizontalByteCount ( int value ) : void
SetPosition ( long bytePos ) : void
SetPosition ( long bytePos, int byteCharacterPos ) : void
SetSelectionLength ( long selectionLength ) : void
SetVerticalByteCount ( int value ) : void
ToScrollMax ( long value ) : int
ToScrollPos ( long value ) : int
UpdateCaret ( ) : void
UpdateRectanglePositioning ( ) : void
UpdateScrollSize ( ) : void
UpdateVScroll ( ) : void
UpdateVisibilityBytes ( ) : void
_byteProvider_LengthChanged ( object sender, EventArgs e ) : void
_vScrollBar_Scroll ( object sender, ScrollEventArgs e ) : void

Описание методов

AbortFind() публичный Метод

Aborts a working Find method.
public AbortFind ( ) : void
Результат void

CanCopy() публичный Метод

Return true if Copy method could be invoked.
public CanCopy ( ) : bool
Результат bool

CanCut() публичный Метод

Return true if Cut method could be invoked.
public CanCut ( ) : bool
Результат bool

CanPaste() публичный Метод

Return true if Paste method could be invoked.
public CanPaste ( ) : bool
Результат bool

CanPasteHex() публичный Метод

Return true if PasteHex method could be invoked.
public CanPasteHex ( ) : bool
Результат bool

CanSelectAll() публичный Метод

Returns true if Select method could be invoked.
public CanSelectAll ( ) : bool
Результат bool

Copy() публичный Метод

Copies the current selection in the hex box to the Clipboard.
public Copy ( ) : void
Результат void

CopyHex() публичный Метод

Copies the current selection in the hex box to the Clipboard in hex format.
public CopyHex ( ) : void
Результат void

Cut() публичный Метод

Moves the current selection in the hex box to the Clipboard.
public Cut ( ) : void
Результат void

Find() публичный Метод

Searches the current ByteProvider
public Find ( byte bytes, long startIndex ) : long
bytes byte the array of bytes to find
startIndex long the start index
Результат long

HexBox() публичный Метод

Initializes a new instance of a HexBox class.
public HexBox ( ) : System
Результат System

OnBorderStyleChanged() защищенный Метод

Raises the BorderStyleChanged event.
protected OnBorderStyleChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnByteProviderChanged() защищенный Метод

Raises the ByteProviderChanged event.
protected OnByteProviderChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnBytesPerLineChanged() защищенный Метод

Raises the BytesPerLineChanged event.
protected OnBytesPerLineChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnCopied() защищенный Метод

Raises the Copied event.
protected OnCopied ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnCopiedHex() защищенный Метод

Raises the CopiedHex event.
protected OnCopiedHex ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnCurrentLineChanged() защищенный Метод

Raises the CurrentLineChanged event.
protected OnCurrentLineChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnCurrentPositionInLineChanged() защищенный Метод

Raises the CurrentPositionInLineChanged event.
protected OnCurrentPositionInLineChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnGotFocus() защищенный Метод

Raises the GotFocus event.
protected OnGotFocus ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnHexCasingChanged() защищенный Метод

Raises the HexCasingChanged event.
protected OnHexCasingChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnHorizontalByteCountChanged() защищенный Метод

Raises the HorizontalByteCountChanged event.
protected OnHorizontalByteCountChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnInsertActiveChanged() защищенный Метод

Raises the InsertActiveChanged event.
protected OnInsertActiveChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnLineInfoVisibleChanged() защищенный Метод

Raises the LineInfoVisibleChanged event.
protected OnLineInfoVisibleChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnLostFocus() защищенный Метод

Raises the LostFocus event.
protected OnLostFocus ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnMouseDown() защищенный Метод

Raises the MouseDown event.
protected OnMouseDown ( MouseEventArgs e ) : void
e MouseEventArgs An EventArgs that contains the event data.
Результат void

OnMouseWheel() защищенный Метод

Raises the MouseWhell event
protected OnMouseWheel ( MouseEventArgs e ) : void
e MouseEventArgs An EventArgs that contains the event data.
Результат void

OnPaint() защищенный Метод

Paints the hex box.
protected OnPaint ( PaintEventArgs e ) : void
e PaintEventArgs A PaintEventArgs that contains the event data.
Результат void

OnPaintBackground() защищенный Метод

Paints the background.
protected OnPaintBackground ( PaintEventArgs e ) : void
e PaintEventArgs A PaintEventArgs that contains the event data.
Результат void

OnReadOnlyChanged() защищенный Метод

Raises the ReadOnlyChanged event.
protected OnReadOnlyChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnResize() защищенный Метод

Raises the Resize event.
protected OnResize ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnSelectionLengthChanged() защищенный Метод

Raises the SelectionLengthChanged event.
protected OnSelectionLengthChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnSelectionStartChanged() защищенный Метод

Raises the SelectionStartChanged event.
protected OnSelectionStartChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnStringViewVisibleChanged() защищенный Метод

Raises the StringViewVisibleChanged event.
protected OnStringViewVisibleChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnUseFixedBytesPerLineChanged() защищенный Метод

Raises the UseFixedBytesPerLineChanged event.
protected OnUseFixedBytesPerLineChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnVScrollBarVisibleChanged() защищенный Метод

Raises the VScrollBarVisibleChanged event.
protected OnVScrollBarVisibleChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

OnVerticalByteCountChanged() защищенный Метод

Raises the VerticalByteCountChanged event.
protected OnVerticalByteCountChanged ( EventArgs e ) : void
e System.EventArgs An EventArgs that contains the event data.
Результат void

Paste() публичный Метод

Replaces the current selection in the hex box with the contents of the Clipboard.
public Paste ( ) : void
Результат void

PasteHex() публичный Метод

Replaces the current selection in the hex box with the hex string data of the Clipboard.
public PasteHex ( ) : void
Результат void

ScrollByteIntoView() публичный Метод

Scrolls the selection start byte into view
public ScrollByteIntoView ( ) : void
Результат void

ScrollByteIntoView() публичный Метод

Scrolls the specific byte into view
public ScrollByteIntoView ( long index ) : void
index long the index of the byte
Результат void

Select() публичный Метод

Selects the hex box.
public Select ( long start, long length ) : void
start long the start index of the selection
length long the length of the selection
Результат void

SelectAll() публичный Метод

Selects all bytes.
public SelectAll ( ) : void
Результат void