It is really simple to use.
Here is an example for dealing with a skinned button with mouseover and event handling:
Code:
; WUI - Example with button mouse-Over and event handling
; Loading Image Ressources
ImgButtonsSkin = LoadImage(#PB_Any,"button.bmp")
imgAdd = GrabImage(ImgButtonsSkin,#PB_Any,0,0,280,60)
imgBackground = GrabImage(ImgButtonsSkin,#PB_Any,0,0,1,60) ; extract background gradient
ResizeImage(imgBackground,50,60) ; scale background gradient
; Create a window
twindow = WUI_CreateWindow("TESTWIN",400,400,140,60,"WUI Example",#PB_Window_ScreenCentered | #PB_Window_SystemMenu)
; create a background image (left)
WUI_CreateImage("barleft",0,0,0,0,imgBackground,"")
; create a image button
WUI_CreateSkinnedButton("add",50,0,imgAdd,"")
; add mouse-over capability
WUI_GadgetMouseOverSet("add",40,imgAdd)
; add animation
WUI_GadgetAnimationSet("add",40,imgAdd,4,6,4) ; Image-Width=40 Pixel, Start-Image=4, End-Image=6, Actual-Image=4
; create a background image (right)
WUI_CreateImage("barright",90,0,0,0,imgBackground,"")
Repeat
; get window event (20 ms should be fine for a smooth animation
EventID = WaitWindowEvent(20)
; catch WUI events
WUI_EventCatch(WindowMouseX(twindow),WindowMouseY(twindow),EventID,EventType(),EventGadget(),EventMenu())
; get event object
eObject.s = WUI_EventObjectName()
; get event type:
; standard types: 1=Focus, 2=LostFocus, 3=MouseOver, 16=LeftClick, 17=LeftDoubleClick, 32=RightClick, 33=RightDoubleClick, 64=Change, 65=ReturnKey, 66=SizeItem, 67=CloseItem, 90=Scrolling (Scrollbars)
; special types: 91=ChangeTab, 96=AnimationFinished, 100=CellClick/Enter, 101=CellChange, 102=CellKept, 103=CellStartInput, 104=CellNoChangeAllowed, 105=Expand/Collapse)
eType.b = WUI_EventType()
If eObject = "add" And eType = 16
WUI_GadgetAnimationStart(eObject,3,50,0) ; Start animation with type=3 (forward/ping-pong), speed=50, no-repeat
EndIf
Until EventID=#PB_Event_CloseWindow
End
Here you can find a download-able demo file with separate ressource file.
http://www.xideas.de/PureBasic/mouseover.zip
As I mentioned, actually I prepare a help-file with example code and I think I will release the library within this week. I am thinking of dealing with Paypal payment. What do you think about this?