returning desktop settings

Blitz3D Forums/Blitz3D Programming/returning desktop settings

D4NM4N(Posted 2005) [#1]
is there a way to return the current desktop width height and c.depth?


KuRiX(Posted 2005) [#2]
Of course:

hdc = api_GetDC(api_GetActiveWindow())
cx = api_getdevicecaps(hdc,8)
cy = api_getdevicecaps(hdc,10)
Col = api_getdevicecaps(hdc,12)


You will need user32.decls on your userlibs. Check the codearchives.

Cheers.


D4NM4N(Posted 2005) [#3]
nice one


D4NM4N(Posted 2005) [#4]
hmm, it returns cannot find api_getdevicecaps, it seems to like the other two calls tho?


KuRiX(Posted 2005) [#5]
perhaps api_getdevicecaps is included on the gdi32.dll


D4NM4N(Posted 2005) [#6]
lol i just worked that out as u wrote this post.. thanks man