dev.win32maxgui beta test

BlitzMax Forums/MaxGUI Module/dev.win32maxgui beta test

skidracer(Posted 2006) [#1]
If you have maxgui and using windows and would like to help beta test the next release of the win32maxgui module please save the two code boxes in this thread to blitzmax/mod/dev.mod/win32maxgui.mod/win32maxgui.bmx and build modules. Oh, and make sure you have done a syncmods for latest version of pub.win32.

This version is a complete rewrite in pure bmx of maxgui for windows users (unicode only at present) and should be significantly smaller and a magnitude more flexible for future planned releases.

here's a simple test, note the use of import to use the dev version of win32maxgui:

Strict

Import dev.win32maxgui

Global unicode$="Blitz M"+Chr(257)+"x"

Local window2:TGadget=CreateWindow(unicode,220,20,800,600,,15)'+WINDOW_HIDDEN)

SetStatusText window2,"hello me harties..."+unicode

Local treeview:TGadget=CreateTreeView(250,150,200,200,window2)

Local node1:TGadget=InsertTreeViewNode(0,unicode,TreeViewRoot(treeview))

InsertTreeViewNode 0,unicode,node1

While WaitEvent()
	Print currentevent.ToString()
	Select EventID()
		Case EVENT_WINDOWCLOSE
			End
		Case EVENT_GADGETACTION
'			DebugLog GadgetText(acombo)
	End Select
Wend

End



SebHoll(Posted 2006) [#2]
Thanks Skid, I haven't have time to test, but I did notice your debugging for WM_CTLCOLORSTATIC - nice to see you're having a shot at getting transparency/colours working. :-P

Thanks once again!


REDi(Posted 2006) [#3]
Great work Mr Skid, Thanks.

BUG REPORT: *edited* Sliders dont seem to work.




Yan(Posted 2006) [#4]
I've just compiled the BRL MaxIDE with this and noticed the following...

1) When the IDE is minimised then maximised again, the code panel takes up the whole width of the IDE, the tool panel can be dragged back in from the edge. This happens in both windowed and full screen.[edit]MaxEdit (BigTed) does this too[/edit]

2) The HTML view doesn't seem to have the same inset border as it used to. Not exactly earth shattering, I know, but still different behaviour.


[edit]
A quick run through of the GUI example code gave me...

CreateHTMLView example: Same border difference as observed above.

CreateSlider Example : Neither scroll bars work (as REDi reported), track bars and steppers are OK.

CreateTextArea Example: Two lines initially highlighted instead of one (TextAreaSelLen() reports this correctly).

CreateTextField Example: EVENT_GADGETACTION event not thrown when modifying the field.

CreateTreeView Example: The data field of every generated event is zero (I don't know what it's supposed to contain, but it's not zero with the original MaxGUIWin32 driver?).

RequestFont Example: RequestFont() is outputting DebugLog info (in case you'd forgotten ;o)).

SetPointer Example: Pointer initially changes but reverts back to an arrow when the mouse is moved.


Not exactly 'in depth', but should hopefully be of some help.
[/edit]


skidracer(Posted 2006) [#5]
Awesome, thanks guys.


Grisu(Posted 2006) [#6]
Great job there.
Skid, will you update the code here from time to time when you have fixed some bugs?
In addition please make the original post a sticky one.


Bug:
One issue I have found is the fact that listbox icons are not always shown "selected" when they are.

This bug also has been in the original maxgui module. You have solved it by adding a "full row" item selection.
Do you remember?

Old report:
http://www.blitzbasic.com/Community/posts.php?topic=61952#692369

Bug2:
There seeme to be an issue with client coordinates.
In my app I have a main and a child window.
1. I open up the child window
2. I move it around and close it again
3. I maximise the window
4. I open up the client window again and it is mostly "out of place", sometimes even nearly out of my desktop view.

Hope you can fix this as well. It is highly anoying.
The client window coordinates should stay the same (last position) regardless if I'm maximising or minimising the main window.

SuperStrict

'Framework BRL.Win32MaxGUI
Framework DEV.Win32Maxgui

Global wndMain:TGadget = CreateWindow("Test Window",10,10,640,480,Null,WINDOW_TITLEBAR|WINDOW_RESIZABLE)

	Global gadShowChild:TGadget = CreateButton("Show Child Window",10,10,200,20,wndMain,BUTTON_PUSH)

	Global wndChild:TGadget = CreateWindow("Child Window Test",100,100,300,200,wndMain,WINDOW_TITLEBAR|WINDOW_HIDDEN)			

Repeat

	Select WaitEvent()
	
		Case EVENT_WINDOWCLOSE
		
			Select EventSource()
			
				Case wndMain;End
				Case wndChild;HideGadget(wndChild)
			
			EndSelect
		
		Case EVENT_GADGETACTION
		
			Select EventSource()
			
				Case gadShowChild;ShowGadget(wndChild)
			
			EndSelect
			
	EndSelect

Forever



SebHoll(Posted 2006) [#7]
Just tested it with Max'd GUI and have remembered from the preliminary BETA version you sent me, child windows don't work - they don't differ at all from normal windows...

I know they aren't *officially* supported, but I would like to request them being added...

Thanks


FBEpyon(Posted 2006) [#8]
MID function:

I agree with Seb, even though Mac and Linux can't directly support them well Linux can, but it would be a very important function of the whole blitzmax win32gui.. I have been trying to make a editor for weeks, and it would be alot better if there was MDI functions... WINDOW_CHILD

It would be very nice if all the child gadgets on the child window also activated and didn't have a problem with this.. I have been going thru the brl.win32maxgui files and can't find anything about activating them.. :(


skidracer(Posted 2006) [#9]
I've posted new version 0.10

ModuleInfo "History: Fixed sliders"
ModuleInfo "History: Added TextField event handler"
ModuleInfo "History: Fixed CharAt(line) method in TWindowsTextArea"
ModuleInfo "History: Fixed scrollbars"

Hmm, apparently fixed the scrollbars twice.

Will update the "known issues" list from the above this weekend, thanks all for you help!


REDi(Posted 2006) [#10]
err, sliders still dont work here :? (test code posted above)


impixi(Posted 2006) [#11]
I'm having issues with panel pixmaps as can be demonstrated by compiling the following code with dev.win32maxgui.

My third post down in this thread: Seamless Tiles

The same problems do not occur with BRL.Win32MaxGUI.

Other than that eveything seems okay.


skidracer(Posted 2006) [#12]
REDi, did you build modules? that example works here now.


REDi(Posted 2006) [#13]
yeah I did, I just deleted the entire module and started again to make sure, same problem.

Code above produces this output...
Building untitled4
Compiling:untitled4.bmx
flat assembler version 1.67.14 (475319 kilobytes memory)
3 passes, 3510 bytes.
Linking:untitled4.debug.exe
Executing:untitled4.debug.exe
AppResume: data=0, mods=0, x=0, y=0, extra=""
WindowMove: data=0, mods=0, x=220, y=20, extra=""
GadgetAction: data=0, mods=0, x=0, y=0, extra=""
DebugLog:0

it seems event.data is always 0 for the sliders EVENT_GADGETACTION.

*EDIT* so does this mean we can use the new MinGW when this is done? :D


skidracer(Posted 2006) [#14]
hmm, try a debugstop before the SetSliderRange and step in twice, do you get here?

	Method SetRange(visible,total)
		Select slidertype
			Case SLIDER_SCROLLBAR
				Local info:SCROLLINFO=New SCROLLINFO
				info.cbSize=SizeOf(SCROLLINFO)
				info.fMask=SIF_PAGE|SIF_RANGE
				info.nMax=total-1
				info.nPage=visible				
				SetScrollInfo(_hwnd,SB_CTL,info,True)
			Case SLIDER_TRACKBAR
				SendMessageW _hwnd,TBM_SETRANGE,True,(total Shl 16)|visible
			Case SLIDER_STEPPER
				SendMessageW _hwnd,UDM_SETRANGE,True,(visible Shl 16)|total
		End Select		
	End Method



REDi(Posted 2006) [#15]
yes, SetRange in TWindowsSlider


skidracer(Posted 2006) [#16]
i'm confused this is the output I get:

Building Untitled102
Compiling:Untitled102.bmx
flat assembler version 1.66
3 passes, 2365 bytes.
Linking:Untitled102.debug.exe
Executing:Untitled102.debug.exe
AppResume: data=0, mods=0, x=0, y=0, extra=""
WindowMove: data=0, mods=0, x=220, y=20, extra=""
AppSuspend: data=0, mods=0, x=0, y=0, extra=""
AppResume: data=0, mods=0, x=0, y=0, extra=""
WindowActivate: data=0, mods=0, x=0, y=0, extra=""
WindowMove: data=0, mods=0, x=305, y=22, extra=""
GadgetAction: data=35, mods=0, x=0, y=0, extra=""
DebugLog:35
GadgetAction: data=63, mods=0, x=0, y=0, extra=""
DebugLog:63
GadgetAction: data=17, mods=0, x=0, y=0, extra=""
DebugLog:17
WindowClose: data=0, mods=0, x=0, y=0, extra=""




REDi(Posted 2006) [#17]
maybe it just me being stupid, lets see if anyone else has trouble with it first ;)


LarsG(Posted 2006) [#18]
Building untitled1
Compiling:untitled1.bmx
flat assembler version 1.66
3 passes, 3569 bytes.
Linking:untitled1.debug.exe
Executing:untitled1.debug.exe
AppResume: data=0, mods=0, x=0, y=0, extra=""
WindowMove: data=0, mods=0, x=220, y=20, extra=""
AppSuspend: data=0, mods=0, x=0, y=0, extra=""
AppResume: data=0, mods=0, x=0, y=0, extra=""
WindowActivate: data=0, mods=0, x=0, y=0, extra=""
GadgetAction: data=0, mods=0, x=0, y=0, extra=""
DebugLog:0
GadgetAction: data=0, mods=0, x=0, y=0, extra=""
DebugLog:0
AppSuspend: data=0, mods=0, x=0, y=0, extra=""
AppResume: data=0, mods=0, x=0, y=0, extra=""
WindowActivate: data=0, mods=0, x=0, y=0, extra=""
GadgetAction: data=0, mods=0, x=0, y=0, extra=""
DebugLog:0
GadgetAction: data=0, mods=0, x=0, y=0, extra=""
DebugLog:0
WindowClose: data=0, mods=0, x=0, y=0, extra=""

Process complete

Debuglog entered SetRange here as well..


Grisu(Posted 2006) [#19]
Sorry to say so but the new 0.10 is totally broken for me.

My app doesn't start anymore (it did before with the older dev module and normal bmx). It hangs in an endless loop right at the start. Could not track the issue so far.

Btw: The sliders of listboxes seem to be out of place (horizontal position). They overlay the listbox entries!

P.S.: It would be nice if you could host your original files somewhere on a freehost Skid, so testing newer versions is easier and we don't need to copy and paste the module each time by hand.


Grisu(Posted 2006) [#20]
Any update or news? *bump*


skidracer(Posted 2007) [#21]
Sorry for the time off, maxgui development this month includes getting above issues sorted and getting the new sleek bmx implementation of win32maxgui out of beta. Stay tuned!


Brucey(Posted 2007) [#22]
Hallo :-)

Just tried it on my Localization module tool, and it appears to work just fine.

Only thing I can see that needs fixing is to have ListBoxes select the entire width, rather than just the text part - you also have to click on the text of the row for it to select the row.

Cool !


Grisu(Posted 2007) [#23]
Thanks for the info!

Any updated devmaxgui to test for us?