|
-
May 30th, 2020, 01:30 PM
#1
Redesign of Resource Editor - Suggestions
For a challenge, I want to create a resource editor for VB. Looking for a wish-list from those that routinely use resources. Elroy, you listening? Here is what I have in mind & a lot of it is already done.
Wish List - Done
Bitmaps: see all bitmaps in a tile-view and large preview of selected item
Icons/Cursors: see all in a tile-view, show subimages, allow rearranging subimages
-- warn if using a PNG-encoded icon/cursor (XP and lower cannot support them)
-- allow deleting of individual subimages
Manifests: allow editing, ensure DWord padding, warn if non-standard IDs are used
-- possibly include a generic application manifest that can be added from the tool & tweaked
HTML: allow editing, ensure DWord padding
String Tables
-- allow carriage returns
-- edit entries with multiline textbox, unicode compatible
"Custom" resource types
-- show content as read-only hex dump if content is unknown
-- show content graphically if PNG, TIF, GIF, BMP
-- show content as RTF if RTF formatted & allow editing
-- show content as text and allow editing
enable full 65k range for resource/type names, string table entries etc
-- VB limits are due to TextBox & Grid control limitations used for input
Wish List - VB Bugs to Fix
Automatically fix incorrect icon/cursor directory entries (height is always wrong)
Enable full range of numeric resource types: 1 to 65535 vs using hacks like "#24"
Wish List - To Do
Restore Points: similar to undo actions
-- each restore point is a complete res file in proper format
-- at any point during editing can move between restore points
Importing: allow bulk importing
-- enable importing data from existing resources (other res files, exes, dlls, etc)
-- enable importing from restore points (see above); may use registered clipboard messages
-- enable importing from rc scripts? likely not, may require user to compile to res file first
Exporting: allow exporting & bulk exporting of resource types and individual items
-- export as own resource file
-- export in preferred format, i.e., .bmp, ico, cur, .html, .manifest, etc
-- export/import string tables with a user-friendly format (suggestions?)
-- :: remember that carriage returns are allowed & multiple languages can exist (i.e., unicode)
Renumbering: not just for string table entries
Updating: enable updating compiled executables (UpdateResource APIs)
Satellites: allow creation of resource-only DLLs (aka satellite DLLs)
Tagging
-- as implies, allow tags to be assigned to individual resource items (with limitations)
-- allow tags to be stored externally, i.e., INI file or internally as a custom resource
-- internally stored tags can be accessed at design-time & run-time
-- tagging can be used to cache CRC values, file sizes, versions, and more
Access: enable as an Add-In and stand-alone executable
-- idea is for the Add-in to simply shell out to the editor and they talk with each other
-- stand-alone can be associated to .res files if you choose
Provide ready-made class/module for extracting resource file entries that VB cannot support
-- these classes would either be copied to clipboard or extracted to file, on demand
-- :: for example: extracting a specific icon subimage and string table entries of other locales & more
-- possibly include ready-made class for runtime accessing of satellite DLLs
Wish List- Others
jpbro: shell resource to default editor option. See posts #3 & #4 below
Elroy: have some way to say which resources to overwrite when uploading/importing. Post #10
LeandroA: import PNG as an icon group. Post #16
Wish List - Will not Do
icon editing
generate rc scripts
include optional creation of RT_VERSION resource. VB creates this when app is compiled
include editing of many resource types that VB doesn't natively support, but not all
-- i.e., RT_FONT/FONTDIR, RT_DIALOG, and more
-- however, may offer creating/editing of RT_MESSAGETABLE
-- any types not supported by the new tool can always be imported from elsewhere
-- in other cases, still may provide a read-only visual other than hex dump
CONS with any replacement of VB's resource editor. There really aren't any major ones except: VB's resource editor may not be able to display the resource file. This would mean you cannot use VB's resource editor to make changes to the resource file later. However, the file itself is valid and can be compiled into any VB application and used with any tool that can read/edit resources. Stuff that may make it incompatible with VB's resource editor are PNG-encoded & 32bpp icons and strings greater than 32k. But odds are that if this editor is well behaved, you may never go back to VB's editor again.
Commonsense and reality. Enabling the editor to allow 65k character strings in the string table and resource names up to 65k characters in length is valid. That doesn't mean VB will compile resource files where someone abuses those limits to stuff binary data and other things into them. More testing is needed to see if there is a true lower-limit that cannot be exceeded. Any true limitation will not be with VB since its resource editor isn't the deciding factor. Limits would be with the CVTRES utiilty that converts res files to COFF objects during project compilation.
Some screenshots of work in progress. Notice the various ways we can choose to display the resources in the treeview




Last edited by LaVolpe; Jun 1st, 2020 at 12:44 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|