Pelles C forum

Pelles C => Announcements => Topic started by: Pelle on December 20, 2020, 07:19:09 pm

Title: Preview of PE/COFF Viewer
Post by: Pelle on December 20, 2020, 07:19:09 pm
This is a preview of Pelles PE/COFF Viewer (pope.exe): a GUI program for looking into executable, archive (library), object, and debug files. It will be included in a future setup of Pelles C.

I see this as a complement to the podump utility, which I will continue to use myself (I mainly work from the command line). Not everything can and will be included in pope.exe, but if you have any requests please post them here. I will consider everything, and possibly implement it too. Like all programs this is obviously bug free, but when you find a bug you can post it here too...  ;)

www.smorgasbordet.com/pellesc/extra/pope.zip (http://www.smorgasbordet.com/pellesc/extra/pope.zip)  (this link will obviously go dead at some point in the future, but will stay there for now)

A bit early, but I take this opportunity to wish you all a Merry Christmas!

/Pelle
Title: Re: Preview of PE/COFF Viewer
Post by: frankie on December 20, 2020, 10:04:18 pm
Hello Pelle,
nice piece of software  8).
I really missed it!  :(
I expect that you will bind it with your libraries to allow access to icons, dialogs, disassembly etc. directly from it ;) (just click on an object...)
Thanks for all efforts spent and shared with us.
And all best wishes for a merry Christmas with peace and calm, that is what we really need this times...
Title: Re: Preview of PE/COFF Viewer
Post by: John Z on December 21, 2020, 10:49:56 am
Thanks Pelle!

Grabbed a copy already.  My only early input is font size :-) right hand window could use a way to increase the font size, even if it means horizontal scrolling.  Doesn't need to be like the IDE with CTRL+scroll wheel, but some way to adjust the font size for those of us that already need eyesight augmentation (uh - glasses )  :) .

Your work and contributions are very much appreciated!

In a few days Christmas  -  So Merry Christmas to you and yours, and here's praying for a Happy New Year 2021 for us all.


John Z
Title: Re: Preview of PE/COFF Viewer
Post by: TimoVJL on December 21, 2020, 01:41:27 pm
Nice to see an another view to PE/COFF :)
Title: Re: Preview of PE/COFF Viewer
Post by: Vortex on December 21, 2020, 05:21:53 pm
Hi Pelle,

Great job and many thanks.
Title: Re: Preview of PE/COFF Viewer
Post by: Pelle on December 22, 2020, 02:37:34 pm
I expect that you will bind it with your libraries to allow access to icons, dialogs, disassembly etc. directly from it ;) (just click on an object...)
Disassembly is on the wish-list, the only problem is handling scrolling fast enough. It's easy to do in the hex-dump when every line is 16 bytes, less so with variable length instructions. It's done in the debugger, but I don't really want to include all that support code in this little tool - I need to find another way...

Since the IDE can handle resources in executables (if that's what you mean), I think this is enough. I don't want code duplication, and making this a reusable library is more work than necessary...
Title: Re: Preview of PE/COFF Viewer
Post by: Pelle on December 22, 2020, 02:41:08 pm
My only early input is font size :-) right hand window could use a way to increase the font size, even if it means horizontal scrolling.  Doesn't need to be like the IDE with CTRL+scroll wheel, but some way to adjust the font size for those of us that already need eyesight augmentation (uh - glasses )  :) .
Umm... what? Shouldn't your general Windows settings handle this?
Title: Re: Preview of PE/COFF Viewer
Post by: John Z on December 23, 2020, 01:01:27 pm
Yes, it does in a global sort of way.  Ever since high resolutions displays became the norm there is one global setting in the display settings to "Change the size of text, apps and other items."  It works to a point but also changes much more than text.  I'm currently using a display 2048 x 1152 so the 'optimum' adjustment per M$ is 125%.  Changing the display to 3840 x 2160 the 'optimum' is 250%. 

It is not that the default is unreadable, it looks like a system font at 6 or 8pt is used in the multicolumn listview. 
Chalk it up to a 'nice to have'  :) 


John Z

P.S. The screen capture image shows larger than the actual ;(
Title: Re: Preview of PE/COFF Viewer
Post by: John Z on December 23, 2020, 06:33:17 pm
There was a sample program called enumdesk  which uses a treeview and a listbox similar to the pope.exe.

I added a module font.c , a menu item, and a call to execute the font dialogue box and change the listbox font on the fly.
It might be useful....but it is somewhat of a hack because I took the font code out of a vcard program I wrote and dropped into the enumdesk program.   In the vCard program I also save the font selection in the ini file, but I've not included that here.  In the enumdesk.c search for <ZZ> for the inserted calls.

BTW if you do use vcf or xml vCards you might check out vCardz_i on sourceforge (Made with Pelles C of course), it is approaching 7000 downloads across 139 countries.  :D :D :D

https://sourceforge.net/projects/vcardz/ 

John Z
Title: Re: Preview of PE/COFF Viewer
Post by: John Z on December 24, 2020, 01:10:29 pm
Well can't leave well enough alone …. here is a version that implement Ctrl+Wheel Scroll to change just the font size.
Ctrl+scroll away shrinks, Ctrl+scroll towards enlarges.

John Z

G-Data antivirus complains about this program btw.  The original sources are from http://smorgasbordet.com/pellesc/
Windows Shell - enumdesk
Title: Re: Preview of PE/COFF Viewer
Post by: John Z on December 29, 2020, 04:05:06 pm
G-Data has fixed the false positive on this file. - Just FYI.
Title: Re: Preview of PE/COFF Viewer
Post by: bitcoin on January 29, 2021, 04:40:18 pm
Hello Pelle
this is very good tool

can you add copy-paste of hex values? As example - I want open "text" section and copy all hex (binary) data to dizasembler.
Title: Re: Preview of PE/COFF Viewer
Post by: Pelle on January 29, 2021, 07:37:21 pm
can you add copy-paste of hex values? As example - I want open "text" section and copy all hex (binary) data to dizasembler.
Maybe, if it's not too complicated (I will check later, when doing other work on this tool).
If I can get my own disassembler to work, maybe less need for this feature?
Title: Re: Preview of PE/COFF Viewer
Post by: bitcoin on January 29, 2021, 11:54:16 pm
If I can get my own disassembler to work, maybe less need for this feature?
Yes.
Also, Timo posted some samples with Zydis disasm..or you want to write own from scratch?
Title: Re: Preview of PE/COFF Viewer
Post by: TimoVJL on January 30, 2021, 05:15:31 pm
TLPEView support plugins, so Zydis disassembler is just a one example for it.
Title: Re: Preview of PE/COFF Viewer
Post by: bitcoin on January 30, 2021, 07:45:58 pm
H
TLPEView support plugins, so Zydis disassembler is just a one example for it.
But how to write it?
I saw your Zydis sample and TLPview, but how to connect it.
Title: Re: Preview of PE/COFF Viewer
Post by: TimoVJL on February 02, 2021, 06:50:52 am
Copy TLPEPlgZydis3.dll and Zydis3.dll to same folder where TLPEView is.
After that a mouse right click over SECTION .text shows name of TLPEPlgZydis3.dll in context menu.
Title: Re: Preview of PE/COFF Viewer
Post by: bitcoin on February 02, 2021, 11:03:47 pm
TLPEPlgDisAsm64.dll - this ? It works.. But very good to add vertical scroll bar.