Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

ImageList :: Save/Load/LoadRes/SaveAsBMP + Viewer


  • Please log in to reply
49 replies to this topic
SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005
Usage Demo:

himl := IL_Create( 10, 0, 1 )
Loop 40
 IL_Add( himl, "shell32.dll", A_Index )
[color=darkred]IML_Save([/color] "test.iml", himl [color=darkred])[/color]
IL_Destroy( himl )

himl2 := [color=darkred]IML_Load([/color] "test.iml" [color=darkred])[/color]
Gui, Add, ListView, w480 h510 Icon, Icon
LV_SetImageList( himl2, 0 )
Loop 40
 LV_Add("Icon" . A_Index )
Gui, Show

The Functions:

;   ___  __  __  _
;  |_ _||  \/  || |           [color=darkred]A collection of standalone functions to Save/Load ImageLists[/color]
;   | | | |\/| || |                     [color=indigo]by SKAN - Suresh Kumar A N, [email protected][/color]
;   | | | |  | || |___               Topic: www.autohotkey.com/forum/viewtopic.php?t=72282
;  |___||_|  |_||_____|                                Wrapper Last Updated : 11 June 2011
;
;  Functions  : IML_Save() / IML_Load() / IML_LoadRes() / IML_SaveAsBMP()
;  IML Viewer : www.autohotkey.net/~Skan/Scripts/IMLViewer/IMLViewer.zip
;_________________________________________________________________________________________


IML_Save( File, himl ) {         ; by SKAN  www.autohotkey.com/forum/viewtopic.php?t=72282
 SplitPath, File,,,Ext
 Off := ( Ext = "BMP" ) ? 28 : 0
 DllCall( "ole32\CreateStreamOnHGlobal", UInt,0, Int,1, UIntP,pStream ) ;  CD: 24-May-2011
 DllCall( "ImageList_Write", UInt,himl, UInt,pStream )                  ;  LM: 03-Jun-2011
 DllCall( "ole32\GetHGlobalFromStream", UInt,pStream, UIntP,hData )
 pData := DllCall( "GlobalLock", UInt,hData )
 nSize := DllCall( "GlobalSize", UInt,hData )
 If ( hF := DllCall( "CreateFile", Str,File, UInt,0x40000000, UInt,2
                    , Int,0, UInt,2, Int,0, Int,0 ) ) > 0
   Bytes := DllCall( "_lwrite", UInt,hF, UInt,pData+Off, UInt,nSize-Off )
         ,  DllCall( "CloseHandle",UInt,hF )
 DllCall( "GlobalUnlock", UInt,hData )
 DllCall( NumGet( NumGet( 1*pStream ) + 8 ), UInt,pStream )
 DllCall( "GlobalFree",   UInt,hData )
Return Bytes > 0 ? Bytes : 0
}


IML_Load( File ) {               ; by SKAN  www.autohotkey.com/forum/viewtopic.php?t=72282
 If ( hF := DllCall( "CreateFile", Str,File, UInt,0x80000000, UInt,3    ;  CD: 24-May-2011
                    , Int,0, UInt,3, Int,0, Int,0 ) ) < 1               ;  LM: 25-May-2011
 || ( nSiz := DllCall( "GetFileSize", UInt,hF, Int,0, UInt ) ) < 1
  Return ( ErrorLevel := 1 ) >> 64,  DllCall( "CloseHandle",UInt,hF )
 hData := DllCall("GlobalAlloc", UInt,2, UInt,nSiz )
 pData := DllCall("GlobalLock",  UInt,hData )
 DllCall( "_lread", UInt,hF, UInt,pData, UInt,nSiz )
 DllCall( "GlobalUnlock", UInt,hData ), DllCall( "CloseHandle",UInt,hF )
 DllCall( "ole32\CreateStreamOnHGlobal", UInt,hData, Int,True, UIntP,pStream )
 himl := DllCall( "ImageList_Read", UInt,pStream )
 DllCall( NumGet( NumGet( 1*pStream ) + 8 ), UInt,pStream )
 DllCall( "GlobalFree", UInt,hData )
Return himl
}


IML_LoadRes( File, Ord="" ) {    ; by SKAN  www.autohotkey.com/forum/viewtopic.php?t=72282
 IfNotExist, %File%, Return ( ErrorLevel := 1 ) >> 64                   ;  CD: 24-May-2011
 If ! hMod := DllCall( "GetModuleHandle", Str,File, UInt )
 If ! hMod := DllCall( "LoadLibraryEx", Str,File, Int,0, UInt,0x2, UInt )
   Return ( ErrorLevel := 2 ) >> 64
 hRes  := DllCall( "FindResource",  UInt,hMod, UInt,Ord, UInt,10 )
 hDat  := DllCall( "LoadResource",  UInt,hMod, UInt,hRes )
 pDat  := DllCall( "LockResource",  UInt,hDat )
 nSiz  := DllCall( "SizeofResource",UInt,hMod, UInt,hRes )
 IfLess,nSiz,1, Return ( ErrorLevel := 3 ) >> 64
 hData := DllCall("GlobalAlloc", UInt,2, UInt,nSiz )
 pData := DllCall("GlobalLock",  UInt,hData )
 DllCall( "RtlMoveMemory", UInt,pData, UInt,pDat, UInt,nSiz )
 DllCall( "GlobalUnlock", UInt,hData ), DllCall( "FreeLibrary", UInt,hMod )
 DllCall( "ole32\CreateStreamOnHGlobal", UInt,hData, Int,True, UIntP,pStream )
 himl := DllCall( "ImageList_Read", UInt,pStream )
 DllCall( NumGet( NumGet( 1*pStream ) + 8 ), UInt,pStream )
 DllCall( "GlobalFree", UInt,hData )
Return himl
}


IML_SaveAsBMP( File, himl, Alpha=1 ) { ; by SKAN
 ; Topic: www.autohotkey.com/forum/viewtopic.php?t=72282 | CD:09-Jun-2011 / LM:11-Jun-2011
 DllCall( "ImageList_GetIconSize", UInt,himl, IntP,W, IntP,TH )
 TW := W * ( Imgs := DllCall( "ImageList_GetImageCount", UInt,himl ) )
 hBM := DllCall( "CopyImage", UInt,DllCall( "CreateBitmap", Int,TW, Int,TH, UInt,1, UInt
                 ,Alpha ? 32 : 24, UInt,0 ), UInt,0, Int,0, Int,0, UInt,0x2000|0x8, UInt )
 DllCall( "SelectObject", UInt,Hdc := DllCall("CreateCompatibleDC",Int,0), UInt,hBM )
 Loop % ( Imgs + ( X:=0 ) )
  DllCall( "ImageList_Draw", UInt,himl, Int,A_Index-1,UInt,Hdc,Int,X,Int,0,Int,0 ), X:=X+W
 DllCall( "DeleteDC", UInt,Hdc )
 DllCall( "GetObject", UInt,hBM, Int,VarSetCapacity( DIB,84,0 ), UInt,&DIB )
 Numput( VarSetCapacity(BFH,14,0)+40, Numput((NumGet(DIB,44)+54),Numput(0x4D42,BFH)-2)+4 )
 If ( hF := DllCall( "CreateFile", Str,File,UInt,2**30,UInt,2,Int,0,UInt,2,Int64,0 ) ) > 0
   DllCall( "WriteFile", UInt,hF, UInt,&BFH,    UInt,14, IntP,0,Int,0 ) ; BITMAPFILEHEADER
 , DllCall( "WriteFile", UInt,hF, UInt,&DIB+24, UInt,40, IntP,0,Int,0 ) ; BITMAPINFOHEADER
 , DllCall( "WriteFile", UInt,hF, UInt,NumGet(DIB,20), UInt,NumGet(DIB,44), IntP,0,Int,0 )
 , DllCall( "CloseHandle", UInt,hF )
Return hBM 
}


Credit: Thanks to Sean for documenting CreateStreamOnHGlobal()

IML Viewer:

Handy tool to view 'Saved ImageLists'
Download: IML Viewer (264.27 KiB)
The zip contains an uncompiled script ( only 75 lines ). The rest are sample .iml files.

Posted Image

sumon
  • Moderators
  • 1317 posts
  • Last active: Dec 05 2016 10:14 PM
  • Joined: 18 May 2010
Can resources also be created? Is this equalivent to ResHacker?

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005

Can resources also be created? Is this equalivent to ResHacker?


Once you save an ImageList to .iml file, you may place it in a 'Resource only DLL' as RT_RCDATA, with reshacker or ROD-Ex.
You may then load the ImageList into your process, like:

himl := IML_LoadRes( "ResourceOnly.dll", 6000 ) ; 6000 is Ordinal

Posted Image

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005
Code updated / Bug fixed
OpenFile() was crashing the script.. Resorted to CreateFile() now.

maraskan_user
  • Members
  • 52 posts
  • Last active: Dec 08 2014 11:18 PM
  • Joined: 20 Jun 2008

Code updated / Bug fixed
OpenFile() was crashing the script.. Resorted to CreateFile() now.


I just spend 2 hours fixing the same thing. :(
I also used ReadFile and WriteFile and replaced UInt with UPtr in the places I thought it might be neccessary, so it should work with AHK_L x64 as well...

IML_Save(File,himl) ; by SKAN  www.autohotkey.com/forum/viewtopic.php?t=72282
   {
   DllCall("ole32\CreateStreamOnHGlobal","UPtr",0,"Int",1,"UPtr*",pStream)
   DllCall("ImageList_Write","UPtr",himl,"UPtr",pStream)
   DllCall("ole32\GetHGlobalFromStream","UPtr",pStream,"UPtr*",hData)
   pData := DllCall("GlobalLock","UPtr",hData)
   nSize := DllCall("GlobalSize","UPtr",pData)

   If (hF := DllCall("CreateFile","Str",file,"Uint",0x40000000,"Uint",0,"UPtr",0,"UInt",4,"Uint",0,"UPtr",0)) > 0
      {
      DllCall("WriteFile","UPtr",hF,"UPtr",pdata,"UInt",nSize,"UInt*",BytesWritten,"UInt",0)
      DllCall("CloseHandle","UPtr",hF)
      }
   DllCall(NumGet(NumGet(1*pStream) + 2*A_PtrSize),"UPtr",pStream)
   DllCall("GlobalUnlock","UPtr",hData)
   DllCall("GlobalFree","UPtr",hData)
   Return BytesWritten > 0 ? BytesWritten : 0
   }

IML_Load(File) ; by SKAN  www.autohotkey.com/forum/viewtopic.php?t=72282
   {
   If ((hF := DllCall("CreateFile","Str",file,"Uint",0x80000000,"Uint",3,"UPtr",0,"UInt",3,"Uint",0,"UPtr",0)) < 0)
      Return (ErrorLevel := 1) >> 64

   VarSetCapacity(FileSize64,64,0)
   DllCall("GetFileSizeEx","UPtr",hF,"Str",FileSize64)
   If ((nSiz := NumGet(FileSize64,0,"Int64"))  < 1)
      Return (ErrorLevel := 1) >> 64

   hData := DllCall("GlobalAlloc","UInt",2,"UPtr",nSiz)
   pData := DllCall("GlobalLock","UPtr",hData)

   DllCall("ReadFile","UPtr",hF,"UPtr",pData,"UInt",nSiz,"UInt*",BytesRead,"UInt",0)

   DllCall("GlobalUnlock","UPtr",hData)
   DllCall("CloseHandle","UPtr",hF)

   if BytesRead>0
      {
      DllCall("ole32\CreateStreamOnHGlobal","UPtr",hData,"Int",1,"UPtr*",pStream)
      himl := DllCall("ImageList_Read","UPtr",pStream)
      DllCall(NumGet(NumGet(1*pStream) + 2*A_PtrSize),"UPtr",pStream)
      }
   else
      himl=0

   DllCall("GlobalFree","UPtr",hData)
   Return himl
   }

IML_LoadRes(File,Ord="") ; by SKAN  www.autohotkey.com/forum/viewtopic.php?t=72282
   {
   IfNotExist,%File%
      Return (ErrorLevel := 1) >> 64
   If ! hMod := DllCall("GetModuleHandle","Str",File,"UPtr")
   If ! hMod := DllCall("LoadLibraryEx","Str",File,"Int",0,"UInt",0x2,"UPtr")
      Return (ErrorLevel := 2) >> 64
   hRes  := DllCall("FindResource","UPtr",hMod,"UPtr",Ord,"UPtr",10)
   hDat  := DllCall("LoadResource","UPtr",hMod,"UPtr",hRes)
   pDat  := DllCall("LockResource","UPtr",hDat)
   nSiz  := DllCall("SizeofResource","UPtr",hMod,"UPtr",hRes)
   If nSiz<1
      Return (ErrorLevel := 3) >> 64
   hData := DllCall("GlobalAlloc","UInt",2,"UPtr",nSiz)
   pData := DllCall("GlobalLock","UPtr",hData)
   DllCall("RtlMoveMemory","UPtr",pData,"UPtr",pDat,"UPtr",nSiz)
   DllCall("GlobalUnlock","UPtr",hData)
   DllCall("FreeLibrary","UPtr",hMod)
   DllCall("ole32\CreateStreamOnHGlobal","UPtr",hData,"Int",1,"UPtr*",pStream)
   himl := DllCall("ImageList_Read","UPtr",pStream)
   DllCall(NumGet(NumGet(1*pStream) + 2*A_PtrSize),"UPtr",pStream)
   DllCall("GlobalFree","UPtr",hData)
   Return himl
   }


Edit: Changed to use GetFileSizeEx.

Edit: Seems to work fine on AHK_L x64

Lucid_Method
  • Members
  • 147 posts
  • Last active: Dec 06 2014 08:39 AM
  • Joined: 19 Apr 2010
Thanks SKAN, I'm not a big fan of image lists but necessary for Listviews/Treeviews, this should help :-)
Posted Image
Macro Everything
Lucid_Method Index

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005

Code updated / Bug fixed
OpenFile() was crashing the script.. Resorted to CreateFile() now.


I just spend 2 hours fixing the same thing. :(


Sorry! :oops:. Thanks for the efforts. :)

I'm not a big fan of image lists

Neither was I... but that was because AHK IL_xx functions did not support 32bit natively.

necessary for Listviews/Treeviews, this should help


I am suggesting Menu, Toolbar and Buttons. You can extract an image from ImageList with ImageList_GetIcon().
You can find a demo here: Import/Export AHK ImageList Content possible?
A 'Saved ImageList' can save us some code as well as the icon clutter in a Resource-Only DLL.

I am still exploring the possibilities and will reply soon with useful information.

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005
Sample: Creating/Saving ImageList with 32bit rectangular ( 96x124 ) icons.

#SingleInstance, Force
SetWorkingDir, %A_ScriptDir%

IconFiles=
(
http://dl.dropbox.com/u/6428211/Sample/ImageList/Icons/1306310755.ico
http://dl.dropbox.com/u/6428211/Sample/ImageList/Icons/1306310798.ico
http://dl.dropbox.com/u/6428211/Sample/ImageList/Icons/1306310806.ico
http://dl.dropbox.com/u/6428211/Sample/ImageList/Icons/1306310865.ico
http://dl.dropbox.com/u/6428211/Sample/ImageList/Icons/1306310888.ico
http://dl.dropbox.com/u/6428211/Sample/ImageList/Icons/1306378426.ico
)

; Download samples of 96x124 icons
Loop, Parse, IconFiles, `n
 UrlDownloadToFile, % A_LoopField, % SubStr( A_LoopField, -13 )


Wid  := 96                  ; Standard width for all images
Hei  := 124                 ; Standard height for all images
ILC_COLOR32 := 0x20         ; This flag is required as we are about to store 32bit Bitmaps
Init := 6                   ; Initial count of images. We are going to add 6 Images.

; ImageList_Create()        www.msdn.microsoft.com/en-us/library/bb761522

himl := DllCall( "ImageList_Create", Int,Wid, Int,Hei, UInt,ILC_COLOR32, Int,Init, Int,1 )


LR_LOADFROMFILE := 0x10, IMAGE_ICON := 1

Loop, *.ico
{

;  LoadImage()              www.msdn.microsoft.com/en-us/library/ms648045

   hIcon := DllCall( "LoadImage", Int,0, Str,A_LoopFileName
                    , Int,IMAGE_ICON          ; Source image is an ICON
                    , Int,0, Int,0            ; use Original Width & Height
                    , UInt,LR_LOADFROMFILE )

;  ImageList_ReplaceIcon()  www.msdn.microsoft.com/en-us/library/bb775215

   DllCall( "ImageList_ReplaceIcon", UInt,hIml, Int,-1, UInt,hIcon )
;  Note >> Calling ImageList_ReplaceIcon() with -1 will append the Icon to ImageList
}

; Now the ImageList contains 6 images equally sized at 96x124

; Let's save it!!

IML_Save( "test.iml", himl )

Return                                                 ; // end of auto-execute section //

; [color=red]Copy/Paste IML_Save() below[/color]


You can view the created test.iml with IML Viewer ( link available on first post ).
Posted Image
How did I create the icons in the first place ?

I picked the .PNG's from IconFinder website ( I repeat: I picked PNG, not ICO ) and converted them to .ICO with a portable freeware app XnView. There is also an online solution to convert rectangular PNG to ICO format: ConvertIcon!. My favorite tool Icon Sushi also allows me to save rectangular icons, but XnView is best suited for this purpose as it has explorer-like interface where we can select all .PNGs and convert them to .ICO's in one go.

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005
If we chop-off leading 28 bytes ( IL Header ) from a .iml file, the remaining data is a single bitmap containing all images stacked vertically. Vertically stacked images are not of much use, I guess.
Yet, IML_Save() has been updated. It can now save the ImageList as BMP if file parameter has .bmp extension.

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005
Sample: Using ImageList_LoadImage() to load an ImageList from a 'Wide Bitmap'

We may populate an ImageList from a wide bitmap with a single DllCall() to ImageList_LoadImage()

The following image was created by horizontally stacking eight 59x60 ( 32bit ) icons

hsbmp.bmp, 472x60, 32bit Alpha Bitmap
Posted Image
The following script downloads and uses the above image:

#SingleInstance, Force
SetWorkingDir, %A_ScriptDir%

IfNotExist,hsbmp.bmp
   UrlDownloadToFile, http://dl.dropbox.com/u/6428211/Sample/ImageList/hsbmp.bmp,hsbmp.bmp

himl := DllCall( "ImageList_LoadImage"  [color=#808080]( A_IsUnicode ? "W" : "A" )[/color]
                 , UInt,  0           ; HINSTANCE
                 , Str,  "hsbmp.bmp"  ; Bitmap file
                 , UInt, 59           ; The width of each image
                 , UInt,  1           ; The number of images by which the image list grows
                 , UInt, -1           ; CLR_NONE
                 , UInt,  0           ; IMAGE_BITMAP
                 , UInt, 0x2010 )     ; LR_LOADFROMFILE | LR_CREATEDIBSECTION


Gui +ToolWindow
Gui, Margin, 0, 0

Gui, Add, ListView, w330 h300 Icon +0x100 -E0x200  C225599 vLVC hwndhLVC BackgroundE2E2E2
LV_SetImageList( himl,0 )

Loop % DllCall( "ImageList_GetImageCount", UInt,himl )
    LV_Add( "Icon" A_Index, A_Index-1 )

Gui, Show,, Testing hsbmp.bmp


Screenshot of above script:
Posted Image
How to Create a Wide Bitmap?

No, one does not have to learn Photoshop for this trivial task.

Create and Load an ImageList your usual/manual way, but do not attach it to any ListView/TreeView or Toolbar.
Call -> IML_SaveAsBMP( "filename.bmp", himl ) and the ImageList will be saved as a 32bit Wide Bitmap.

If your ImageList does not have any transparent Images, or for some reason you do not want to save the transparency
Call -> IML_SaveAsBMP( "filename.bmp", himl, False ) and the ImageList will be saved as a 24bit Wide Bitmap.

If you need to step down the BPP any further ( to reduce filesize ), you will have to process the Wide Bitmap with a third party image editor, maybe irfanview.

Lucid_Method
  • Members
  • 147 posts
  • Last active: Dec 06 2014 08:39 AM
  • Joined: 19 Apr 2010
I like the way this post is progressing, keep it up SKAN 8)
Posted Image
Macro Everything
Lucid_Method Index

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005
Thank you Lucid_Method. The best is yet to come. :)

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005
Sample: Using ImageList to create LED buttons via BCM_SETIMAGELIST Message

bil.bmp 96x16, 32bit Alpha Bitmap : Posted Image

The 6 icons in above Image(List) will be used by system as follows:

[*:xf5j801s]Icon 1 = When Button is Normal
[*:xf5j801s]Icon 2 = On Mouse Hover
[*:xf5j801s]Icon 3 = When Button is Pressed
[*:xf5j801s]Icon 4 = When Button is Disabled
[*:xf5j801s]Icon 5 = When Button has Keyboard Focus
[*:xf5j801s]Icon 6 = I do not know

Note: 3 & 5 are same, just my preference.Screenshot of LED Buttons:
Posted Image

The Script:[/list]
; [color=darkred]BCM_SETIMAGELIST := 0x1602[/color]

IfNotExist, bil.bmp, URLDownloadToFile
 , https://ahknet.autohotkey.com/~Skan/Sample/ImageList/bil.bmp, bil.bmp
 
; ImageList_LoadImage()      ; www.msdn.microsoft.com/en-us/library/bb761557
[color=red]himl[/color] := DllCall( "ImageList_LoadImage"  ( A_IsUnicode ? "W" : "A" ), UInt,0, Str,"bil.bmp"
                                       , UInt,16, UInt,1, Int,-1, UInt,0, UInt,0x2010 )

; BUTTON_IMAGELIST Structure : www.msdn.microsoft.com/en-us/library/bb775953
VarSetCapacity( BIL, 24, 0 ), NumPut( [color=red]himl[/color], BIL )                   ;

; Button-Image margins: Left / Top / Right / Bottom
NumPut( [color=darkred]5[/color], BIL, 4 ),   NumPut( [color=darkred]0[/color], BIL, 8 ),   NumPut( [color=darkred]0[/color], BIL,12 ),   NumPut( [color=darkred]0[/color], BIL,16 )


Gui, +ToolWindow
Gui, Font, S10, Calibri

Gui, Add, Button, w120 h25 hwndErrorLevel,               Button 1
 SendMessage, 0x1602, 0, &BIL,, ahk_id %Errorlevel%

Gui, Add, Button, wp hp hwndErrorlevel,                  Button 2
 SendMessage, 0x1602, 0, &BIL,, ahk_id %Errorlevel%

Gui, Add, Button, wp hp hwndErrorlevel ,                 Button 3
 SendMessage, 0x1602, 0, &BIL,, ahk_id %Errorlevel%

Gui, Add, Button, wp hp hwndErrorlevel ,                 Button 4
 SendMessage, 0x1602, 0, &BIL,, ahk_id %Errorlevel%

Gui, Add, Button, wp hp Disabled hwndErrorlevel,         Button 5
 SendMessage, 0x1602, 0, &BIL,, ahk_id %Errorlevel%

Gui, Show,, % " LED Buttons"


Note: I have used errorlevel instead of several variables cluttering up the global space.
Reference:
A wrapper already exists and you can find more info in tkoi's ILButton()
:arrow: A trivial bug in ILButton() is that it uses PostMessage ( instead of SendMessage ) which causes redraw problems with buttons.

The 16x16 icons were resized from the original size of 128x128
The original PNG files : <!-- m -->http://www.bestfreei...ads/XSIMPLE.rar<!-- m -->


Note to self: Default button loses its 'default'ness once navigation happens. This phenomenon requires investigation.

Edit: Never use imgur.com or sites.google for uploading a bitmap. They compress it to PNG/JPG



sumon
  • Moderators
  • 1317 posts
  • Last active: Dec 05 2016 10:14 PM
  • Joined: 18 May 2010
Especially with your last example, I realize how great this is and can be. However, your last example could not be ran "out of the box". I did of course download the IML library file, and also tried commenting out BCM_SetImageList and renaming the function (IML_ instead of ImageList), I beforehand apologize for low brain activity, I might be missing something obvious.

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005

I realize how great this is and can be. However, your last example could not be ran "out of the box".


I might be missing something obvious.


Sorry about that. That sample is meant to be run "out of the box" in 32bit versions of Ansi & Unicode

It was me missing the obvious:
Seemingly, sites.google has compressed my alpha bitmap into jpeg.
<!-- m -->https://sites.google...nsuresh/bil.bmp<!-- m -->

I hate cluttering my autohotkey.net account, but alas, here follows the 32bit Alpha bitmap:

<!-- m -->https://ahknet.autoh... ... st/bil.bmp<!-- m -->

URL fixed. The sample should run properly now. :)