实例介绍
Wpf Hex编辑器是一个功能强大且完全可定制的用户控件,允许用户以十六进制、十进制和二进制形式编辑文件或数据流。这一工具不仅易于在Wpf或WinForm应用程序中使用,而且支持多种语言(包括英语、法语、俄语、波兰语、葡萄牙语和中文),使其成为国际化项目的理想选择。
Wpf Hex编辑器提供了众多特性,如AvalonDock支持、多种数据格式编辑(包括8位、16位和32位)、高级查找和替换对话框、自定义字符表(TBL)支持、无限撤销/重做、书签功能、数据块分组、部分文件/流视图编辑等。此外,用户还可以自定义界面颜色,包括字节颜色、背景色、标题色等,以满足个性化需求。
使用Wpf Hex编辑器非常简单,只需将WPFHexaEditor.dll添加到项目中,并在XAML中引入相应的命名空间即可轻松集成此控件:
<xmlns:control="clr-namespace:WpfHexaEditor;assembly=WPFHexaEditor"> <control:HexEditor/> <control:HexEditor Width="NaN" Height="NaN"/> <control:HexEditor Width="Auto" Height="Auto"/> <control:HexEditor FileName="{Binding FileNamePath}" Width="Auto" Height="Auto"/>【实例截图】
【核心代码】
文件清单
└── WpfHexEditorControl-835347edd04bda516e4e97ae748535e48eb7af69
├── CODE_OF_CONDUCT.md
├── _config.yml
├── CONTRIBUTING.md
├── Images
│ ├── Logo.docx
│ ├── Logo-Icon.ico
│ ├── Logo-Nuget.png
│ ├── Logo.png
│ ├── NewLogo.png
│ ├── Sample11-AvalonDock.png
│ ├── Sample11-NOTBL.png
│ ├── Sample12-BarChart.png
│ ├── Sample12-FIXEDTBL-BYTESHIFT.png
│ ├── Sample13-FindDialog.png
│ ├── Sample14-FindReplaceDialog.png
│ ├── Sample15-CustomBackgroundBlock.png
│ ├── Sample15-FindReplaceDialog.png
│ ├── Sample9-TBL.png
│ ├── TBLExplain.docx
│ └── TBLExplain.png
├── ISSUE_TEMPLATE.md
├── LICENSE
├── README.md
├── readme-nuget.md
├── SECURITY.md
└── Sources
├── MigrationBackup
│ └── 74a5b0ae
│ └── Samples
│ └── WpfHexEditor.Sample.CSharp
│ ├── packages.config
│ └── WpfHexEditor.Sample.CSharp.csproj
├── Samples
│ ├── WpfHexEditor.Sample.AvalonDock
│ │ ├── App.config
│ │ ├── App.xaml
│ │ ├── App.xaml.cs
│ │ ├── MainWindow.xaml
│ │ ├── MainWindow.xaml.cs
│ │ ├── packages.config
│ │ ├── Properties
│ │ │ ├── AssemblyInfo.cs
│ │ │ ├── Resources.Designer.cs
│ │ │ ├── Resources.resx
│ │ │ ├── Settings.Designer.cs
│ │ │ └── Settings.settings
│ │ └── WpfHexEditor.Sample.AvalonDock.csproj
│ ├── WpfHexEditor.Sample.BarChart
│ │ ├── App.xaml
│ │ ├── App.xaml.cs
│ │ ├── AssemblyInfo.cs
│ │ ├── MainWindow.xaml
│ │ ├── MainWindow.xaml.cs
│ │ └── WpfHexEditor.Sample.BarChart.csproj
│ ├── WpfHexEditor.Sample.BinaryFilesDifference
│ │ ├── App.xaml
│ │ ├── App.xaml.cs
│ │ ├── AssemblyInfo.cs
│ │ ├── BlockListItem.xaml
│ │ ├── BlockListItem.xaml.cs
│ │ ├── ByteDifferenceListItem.xaml
│ │ ├── ByteDifferenceListItem.xaml.cs
│ │ ├── MainWindow.xaml
│ │ ├── MainWindow.xaml.cs
│ │ └── WpfHexEditor.Sample.BinaryFilesDifference.csproj
│ ├── WPFHexEditor.Sample.CSharp
│ │ ├── App.xaml
│ │ ├── App.xaml.cs
│ │ ├── Configs
│ │ │ ├── NET45
│ │ │ │ └── App.config
│ │ │ └── NET47
│ │ │ └── App.config
│ │ ├── MainWindow.xaml
│ │ ├── MainWindow.xaml.cs
│ │ ├── Properties
│ │ │ ├── AssemblyInfo.cs
│ │ │ ├── Resources.Designer.cs
│ │ │ ├── Resources.resx
│ │ │ ├── Settings.Designer.cs
│ │ │ └── Settings.settings
│ │ ├── Resources
│ │ │ └── Icon
│ │ │ ├── 0x-Icon.ico
│ │ │ ├── Close-Icon.ico
│ │ │ ├── Logo-Icon.ico
│ │ │ ├── Open-File-Icon.ico
│ │ │ └── Save-Icon.ico
│ │ └── WpfHexEditor.Sample.csproj
│ ├── WpfHexEditor.Sample.InsertByteAnywhere
│ │ ├── App.xaml
│ │ ├── App.xaml.cs
│ │ ├── AssemblyInfo.cs
│ │ ├── MainWindow.xaml
│ │ ├── MainWindow.xaml.cs
│ │ └── WpfHexEditor.Sample.InsertByteAnywhere.csproj
│ ├── WpfHexEditor.Sample.VB
│ │ ├── App.config
│ │ ├── Application.xaml
│ │ ├── Application.xaml.vb
│ │ ├── GlobalSuppressions.vb
│ │ ├── MainWindow.xaml
│ │ ├── MainWindow.xaml.vb
│ │ ├── My Project
│ │ │ ├── AssemblyInfo.vb
│ │ │ ├── MyExtensions
│ │ │ │ └── MyWpfExtension.vb
│ │ │ ├── Resources.Designer.vb
│ │ │ ├── Resources.resx
│ │ │ ├── Settings.Designer.vb
│ │ │ └── Settings.settings
│ │ ├── Resources
│ │ │ └── Icon
│ │ │ ├── 0x-Icon.ico
│ │ │ ├── Close-Icon.ico
│ │ │ ├── Logo-Icon.ico
│ │ │ ├── Open-File-Icon.ico
│ │ │ └── Save-Icon.ico
│ │ └── WpfHexEditor.Sample.VB.vbproj
│ └── WpfHexEditor.Sample.Winform
│ ├── App.config
│ ├── MainForm.cs
│ ├── MainForm.Designer.cs
│ ├── MainForm.resx
│ ├── Program.cs
│ ├── Properties
│ │ ├── AssemblyInfo.cs
│ │ ├── Resources.Designer.cs
│ │ ├── Resources.resx
│ │ ├── Settings.Designer.cs
│ │ └── Settings.settings
│ └── WpfHexEditor.Sample.Winform.csproj
├── WPFHexaEditor
│ ├── BaseByte.cs
│ ├── Core
│ │ ├── BookMark.cs
│ │ ├── Bytes
│ │ │ ├── Byte_16bit.cs
│ │ │ ├── Byte_32bit.cs
│ │ │ ├── Byte_8bit.cs
│ │ │ ├── ByteConverters.cs
│ │ │ ├── ByteDifference.cs
│ │ │ ├── ByteModified.cs
│ │ │ └── ByteProvider.cs
│ │ ├── Caret.cs
│ │ ├── CharacterTable
│ │ │ ├── DTE.cs
│ │ │ ├── Enum.cs
│ │ │ └── TBLStream.cs
│ │ ├── ConstantReadOnly.cs
│ │ ├── Converters
│ │ │ ├── BooleanToVisibilityConverter.cs
│ │ │ ├── BoolInverterConverter.cs
│ │ │ ├── ByteToHexStringConverter.cs
│ │ │ ├── HexToLongStringConverter.cs
│ │ │ ├── LongToHexStringConverter.cs
│ │ │ ├── PathToFilenameConverter.cs
│ │ │ └── VisibilityToBooleanConverter.cs
│ │ ├── CustomBackgroundBlock.cs
│ │ ├── Enumeration.cs
│ │ ├── EventArguments
│ │ │ ├── ByteDifferenceEventArgs.cs
│ │ │ ├── ByteEventArgs.cs
│ │ │ └── CustomBackgroundBlockEventArgs.cs
│ │ ├── Interfaces
│ │ │ ├── IByteControl.cs
│ │ │ ├── IByte.cs
│ │ │ └── IByteModified.cs
│ │ ├── KeyValidator.cs
│ │ ├── MethodExtention
│ │ │ ├── ApplicationExtention.cs
│ │ │ ├── ByteArrayExtention.cs
│ │ │ ├── DoubleExtension.cs
│ │ │ ├── StringExtension.cs
│ │ │ ├── TrackExtention.cs
│ │ │ └── WithMethodExtention.cs
│ │ ├── Native
│ │ │ └── NativeMethods.cs
│ │ └── RandomBrushes.cs
│ ├── Dialog
│ │ ├── FindReplaceWindow.xaml
│ │ ├── FindReplaceWindow.xaml.cs
│ │ ├── FindWindow.xaml
│ │ ├── FindWindow.xaml.cs
│ │ ├── GiveByteWindow.xaml
│ │ ├── GiveByteWindow.xaml.cs
│ │ ├── ReplaceByteWindow.xaml
│ │ └── ReplaceByteWindow.xaml.cs
│ ├── FastTextLine.cs
│ ├── GlobalSuppressions.cs
│ ├── HexBox.xaml
│ ├── HexBox.xaml.cs
│ ├── HexByte.cs
│ ├── HexEditor.xaml
│ ├── HexEditor.xaml.cs
│ ├── LICENSE.txt
│ ├── Properties
│ │ ├── AssemblyInfo.cs
│ │ ├── Resources.Designer.cs
│ │ ├── Resources.fr-CA.Designer.cs
│ │ ├── Resources.fr-CA.resx
│ │ ├── Resources.pl-PL.Designer.cs
│ │ ├── Resources.pl-PL.resx
│ │ ├── Resources.pt-BR.Designer.cs
│ │ ├── Resources.pt-BR.resx
│ │ ├── Resources.resx
│ │ ├── Resources.ru-RU.Designer.cs
│ │ ├── Resources.ru-RU.resx
│ │ ├── Resources.zh-CN1.Designer.cs
│ │ ├── Resources.zh-CN.resx
│ │ ├── Settings.Designer.cs
│ │ └── Settings.settings
│ ├── Resources
│ │ ├── Dictionary
│ │ │ ├── BrushesDictionary.xaml
│ │ │ ├── MiscelanousDictionary.xaml
│ │ │ └── ToolTipDictionary.xaml
│ │ ├── EBCDIC-NoSpecialChar.tbl
│ │ ├── EBCDIC.tbl
│ │ └── Icon
│ │ ├── 0x-Icon.ico
│ │ ├── Add-Bookmark-Icon.ico
│ │ ├── Clear-Bookmark-Icon.ico
│ │ ├── Copy-Icon.ico
│ │ ├── Delete-Icon.ico
│ │ ├── Find-Icon.ico
│ │ ├── Logo-Icon.ico
│ │ ├── Logo-Icon.png
│ │ ├── Paste-Icon.ico
│ │ ├── Remove-Bookmark-Icon.ico
│ │ ├── Sans titre.png
│ │ ├── Settings-Icon.ico
│ │ └── Undo-Icon.ico
│ ├── StringByte.cs
│ └── WpfHexEditorCore.csproj
└── WpfHexEditorControl.sln
41 directories, 196 files
标签:
小贴士
感谢您为本站写下的评论,您的评论对其它用户来说具有重要的参考价值,所以请认真填写。
- 类似“顶”、“沙发”之类没有营养的文字,对勤劳贡献的楼主来说是令人沮丧的反馈信息。
- 相信您也不想看到一排文字/表情墙,所以请不要反馈意义不大的重复字符,也请尽量不要纯表情的回复。
- 提问之前请再仔细看一遍楼主的说明,或许是您遗漏了。
- 请勿到处挖坑绊人、招贴广告。既占空间让人厌烦,又没人会搭理,于人于己都无利。
关于好例子网
本站旨在为广大IT学习爱好者提供一个非营利性互相学习交流分享平台。本站所有资源都可以被免费获取学习研究。本站资源来自网友分享,对搜索内容的合法性不具有预见性、识别性、控制性,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,平台无法对用户传输的作品、信息、内容的权属或合法性、安全性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论平台是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二与二十三条之规定,若资源存在侵权或相关问题请联系本站客服人员,点此联系我们。关于更多版权及免责申明参见 版权及免责申明
网友评论
我要评论