CopyAs

From wxHexEditor
Jump to: navigation, search

Before, sharing an hex information is a really painful experience when you compare it with wxHexEditor's solution. You have to take a screenshot, cut it, find a picture host at internet, upload it, generate an url for forum or Wiki page, paste it. If you take a snapshot of wrong region of the file, do it all over!

With wxHexEditor, you can copy a part of the file for showing at Internet, Wiki or for using in C/C++, ASM souce codes or as many other formats...

All you need to do is selecting the region that you want to export and just use CopyAs function! Than wxHexEditor will copy the block to system clipboard with selected formatting.

Here is some examples using part of testfile.swp file.

Full Text Format

CopyAs Full Text Format just copy the selection, without any TAG support. It's simple solution but you can customize the output with options. Don't need Text output? No problem. Or you might not want to have offset output...

Options: Offset, Hex and Text outputs with Byte Per Line support.

Here we show Hex + Text output with 16 byte per line only.

74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
7A AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   zªªªªªªªªªªªªªªª
AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   ªªªªªªªªªªªªªªªª
AA AA AA AA AB 69 6C 65 74 65 73 74 66 69 6C 65   ªªªª«iletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
74 65 73 74 66 69 BB BB BB BB BB BB BB BB BB BB   testfi»»»»»»»»»»
BB BB BB 74 66 69 6C 65 74                        »»»tfilet

Special Hex Format

Selected block converted to specially formated hex stream with this.

Options: RAW Hex, With Space, Quad Hex, with 0x, with 0x and period, also with Byte Per Line option.

In all examples used 16 byte per line settings.

RAW Hex

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAB696C657465737466696C65
7465737466696C657465737466696C65
7465737466696C657465737466696C65
7465737466696C657465737466696C65
746573746669BBBBBBBBBBBBBBBBBBBB
BBBBBB746669

With Space

AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA 
AA AA AA AA AB 69 6C 65 74 65 73 74 66 69 6C 65 
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 
74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 
74 65 73 74 66 69 BB BB BB BB BB BB BB BB BB BB 
BB BB BB 74 66 69 

Quad Hex

AAAA AAAA AAAA AAAA AAAA AAAA AAAA AAAA 
AAAA AAAA AB69 6C65 7465 7374 6669 6C65 
7465 7374 6669 6C65 7465 7374 6669 6C65 
7465 7374 6669 6C65 7465 7374 6669 6C65 
7465 7374 6669 6C65 7465 7374 6669 6C65 
7465 7374 6669 BBBB BBBB BBBB BBBB BBBB 
BBBB BB74 6669 

with 0x

0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 0xAA 
0xAA 0xAA 0xAA 0xAA 0xAB 0x69 0x6C 0x65 0x74 0x65 0x73 0x74 0x66 0x69 0x6C 0x65 
0x74 0x65 0x73 0x74 0x66 0x69 0x6C 0x65 0x74 0x65 0x73 0x74 0x66 0x69 0x6C 0x65 
0x74 0x65 0x73 0x74 0x66 0x69 0x6C 0x65 0x74 0x65 0x73 0x74 0x66 0x69 0x6C 0x65 
0x74 0x65 0x73 0x74 0x66 0x69 0x6C 0x65 0x74 0x65 0x73 0x74 0x66 0x69 0x6C 0x65 
0x74 0x65 0x73 0x74 0x66 0x69 0xBB 0xBB 0xBB 0xBB 0xBB 0xBB 0xBB 0xBB 0xBB 0xBB 
0xBB 0xBB 0xBB 0x74 0x66 0x69 

with 0x and period

0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 
0xAA, 0xAA, 0xAA, 0xAA, 0xAB, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 
0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 
0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 
0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 
0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 0xBB, 
0xBB, 0xBB, 0xBB, 0x74, 0x66, 0x69, 

Internet Format

WIKI Format

You can copy selection as a mediawiki stream with TAGs support. It's really useful if you want to show some hex values at a wiki page.

Options: Offset, Hex and Text outputs with Byte Per Line support.

Here an example output with all of the panels, using 16 byte per line representation.

TAG List:
Sample: First corruption on file.
Sample: Here second corruption at file
Third corruption
Different Corruption type

000020h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C AA   testfiletestfilª
000030h   60 6F FA AA AA AA 6C 65 74 65 73 74 66 69 6C 65   `oúªªªletestfile
000040h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000050h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000060h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000070h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000080h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000090h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
0000A0h   74 65 73 74 66 69 6C 65 AA AA AA AA AA AA AA AA   testfileªªªªªªªª
0000B0h   AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   ªªªªªªªªªªªªªªªª
0000C0h   AA 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   ªestfiletestfile
0000D0h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
0000E0h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 11 65   testfiletestfi.e
0000F0h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000100h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000110h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000120h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000130h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000140h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000150h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
000160h   7A AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   zªªªªªªªªªªªªªªª
000170h   AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   ªªªªªªªªªªªªªªªª
000180h   AA AA AA AA AB 69 6C 65 74 65 73 74 66 69 6C 65   ªªªª«iletestfile
000190h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
0001A0h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
0001B0h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfile
0001C0h   74 65 73 74 66 69 BB BB BB BB BB BB BB BB BB BB   testfi»»»»»»»»»»
0001D0h   BB BB BB 74 66 69 6C 65 74                        »»»tfilet

Generated by wxHexEditor

phpBB Forum style Format

Copy format for phpBB forums. Unfortunately wxHexEditor does NOT support TAGS with phpBB Forum style format. Because of variable size of the characters at default styles. If there is a way to do that, please contact with the author (me) to he will add support for it!

Current format just add a '[code]' tags into simple formating. Nothing more.

Options: Offset, Hex and Text outputs with Byte Per Line support.

[code]000020h 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C AA testfiletestfilª[/code]Generated by [url=http://www.wxHexEditor.org]wxHexEditor[/url]

HTML Format

wxHexEditor could format the selection int HTML with TAGs support. Just select the blog and CopyAs Internet-> HTML format. HTML stream will pasted into system clipboard. That's all!

Options: Offset, Hex and Text outputs with Byte Per Line support.

Here an example output with all of the panels, using 32 byte per line representation.

(Also note that, there are unwanted stings on this show due using html tags under wikimedia to show you.)

<pre>TAG List:
Sample: First corruption on file.
Sample: Here second corruption at file
Third corruption
Different Corruption type

000020h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C AA 60 6F FA AA AA AA 6C 65 74 65 73 74 66 69 6C 65   testfiletestfilª`oúªªªletestfile
000040h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfiletestfiletestfile
000060h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfiletestfiletestfile
000080h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfiletestfiletestfile
0000A0h   74 65 73 74 66 69 6C 65 AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   testfileªªªªªªªªªªªªªªªªªªªªªªªª
0000C0h   AA 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   ªestfiletestfiletestfiletestfile
0000E0h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 11 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfi.etestfiletestfile
000100h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfiletestfiletestfile
000120h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfiletestfiletestfile
000140h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfiletestfiletestfile
000160h   7A AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA AA   zªªªªªªªªªªªªªªªªªªªªªªªªªªªªªªª
000180h   AA AA AA AA AB 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   ªªªª«iletestfiletestfiletestfile
0001A0h   74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65 74 65 73 74 66 69 6C 65   testfiletestfiletestfiletestfile
0001C0h   74 65 73 74 66 69 BB BB BB BB BB BB BB BB BB BB BB BB BB 74 66 69 6C 65 74                        testfi»»»»»»»»»»»»»tfilet

</pre>Generated by <a href="http://www.wxHexEditor.org">wxHexEditor</a>

ASM Source Format

Programming in ASM? Aahh it's really head ache sometimes. I wish this feature will make coding with ASM easier. You can also use CopyAs ASM Source for converting selected block binary into ASM program source.

Options: 8,16,32 and 64 bit hexs with Big Endian and Bytes per line options.

And here an ASM Source format example with 8 bit option:

;Generated by wxHexEditor
db 074h 066h 069h 06Ch 065h 074h 065h 073h 074h 066h 069h 06Ch 065h 074h 065h 073h 
db 074h 066h 069h 06Ch 065h 074h 065h 073h 074h 066h 069h 06Ch 065h 074h 065h 073h 
db 074h 066h 069h 06Ch 065h 07Ah 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 
db 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 
db 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0AAh 0ABh 069h 06Ch 065h 074h 065h 073h 
db 074h 066h 069h 06Ch 065h 074h 065h 073h 074h 066h 069h 06Ch 065h 074h 065h 073h 
db 074h 066h 069h 06Ch 065h 074h 065h 073h 074h 066h 069h 06Ch

C/C++ Source Format

Programming in C/C++ is a fun for us. Do you need some binary in your program? No problem. CopyAs C/C++ Source converts selected block into C/C++ constant definition that you can paste into your source code directly.

Options: 8,16,32 and 64 bit hexs with Big Endian and Bytes per line options.

Here is C/C++ Source format with 8 bit option example:

// Generated by wxHexEditor //
int8_t hexData[0x6c] = {
  0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 
  0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 
  0x74, 0x66, 0x69, 0x6C, 0x65, 0x7A, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 
  0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 
  0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAB, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 
  0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 
  0x74, 0x66, 0x69, 0x6C, 0x65, 0x74, 0x65, 0x73, 0x74, 0x66, 0x69, 0x6C }