been a while since i posted anything.

came across a desktop image when browsing the other day and saw this application desktop. it looked doable in vfp so i got stuck in and this is the result.

the class is based on the gdi+x classes from the vfpx site and requires vfp9 sp2 or you will not get transparency.

i kept the class simple with few properties to set but that can be easily changed by anyone because the source is included. all the properties are self explanatory.

so just create a form with a nice background and drop as many of these buttons as needed. in my sample i added 4 buttons. set the above properties as needed. you can resize the buttons but a size of 160 x 160 gives very good results.

of course place your code in the click method of each button if you want anything to happen.

note that the buttons are transparent and the images partly so. these settings are commented in the code so it is easy to make changes if needed. if you change the size too much the text may appear in the wrong place so open the class.beforedraw method and adjust the following 2 lines to place your text correctly.

lnleft = this.width/2
lntop = (this.height/6) * 5

here is my form running.

the buttons are interactive. when you mouse over them a halo appears over the button and it pops up ever so slightly so you know which button you are over. "diary" in the image below has the mouse over it.

the buttons also react when clicked as shown in this image below, where the top gradient section is flipped when clicked.

here is another form (attached) with the buttons. the complete source code can be downloaded from the attachment link below.

have fun.


7 Responses to Beautify your Application Desktop

Leave a Reply

Your email address will not be published. Required fields are marked *