How to edit Region Style fill pattern in MapInfo Pro

Products affected: MapInfo Pro™, MapInfo Professional®
This article explains the fill and line style patterns in MapInfo Pro™ 16 and how to edit them. 

Region Style fill pattern picker contains 3 different types of fill pattern:  

User-added image
  • The first two: A1 and B1 are None and Solid. They are hard-coded and can’t be modified. You’ll see the solid bitmap for B1 in MiAuxResources.dll but editing it will have no effect.
  • C1 – H1 are Windows built-in hatch patterns. They also cannot be edited.
  • The bitmaps starting with row 2 (A2) are bitmaps and can be edited.
In MapInfo Pro 16 we moved the bitmaps out of the core product (micore.dll) to make them easier to get to and edit. MiAuxResources.dll does not contain any line style patterns; it only contains the bitmaps shown in the picker above. MiAuxResources.dll is a resource DLL installed to the same directory as MapInfoPro.exe. In general the below process is the same for MapInfo Professional®, all versions below 16, but in this case the micore.dll needs to be edited.

You can edit them using the resource editor in Visual Studio. Just open the MiAuxResources.dll file and you should see something like this:

User-added image

Click on the Bitmap folder to see the full list of bitmap resources. 

User-added image

As already mentioned, Bitmap #1 in MiAuxResources.dll is a solid fill, but editing will have no effect in MapInfo Pro. Click on Bitmap 2 to see the fill pattern that corresponds to A2 in Region Style fill pattern picker. Bitmap #2 and beyond can be edited:

User-added image

The bitmaps must maintain a contiguous numbering, so users should not delete any from the middle, but they can remove from the end. However, removing is problematic; if the user gets a TAB or workspace that reference brush patterns they no longer have in their MiAuxResources.dll they will see solid fills instead. We’re also limited to a value of 255 as the highest brush pattern. The last brush pattern is 193 so there’s only so much room for more patterns.

Exit MapInfo Pro before editing. After editing, save MiAuxResources.dll and restart MapInfo Pro. 
UPDATED:  August 23, 2017