feel like button help

Started by
6 comments, last by Darragh 16 years, 1 month ago
in my program (with opengl, c++ ), i have few buttons (simple rectangles) whenever i click them , i change their colour.. but still iam not satusfied as it does not appear good is their some good way to make a feel for buttons pressed thanks
Advertisement
Beyond visual an auditory feedback on mouseover/mousedown/mouseup?

All three steps combined (as well as auditory) really make a UI 'feel' like it's supposed to.
If you want to stick with simple rectangles, without any shading or texture to make them seem raised, I'd probably go with just making a "pressed" button darker. No extreme color changes.

Otherwise, if you're asking about making a button look and feel like a button...

Just take a look at what everyone else is doing visually and imitate it, would be my suggestion. Just take a look at how your browser handles its own menus when you mouseover them and click them. The visual difference between a "pressed" and normal state can be pretty minor in most interfaces.
how can we use 2 rectangles very close by to represent a button
Something you can try is moving the rectangle slightly when its pressed gives you the feeling thats being pressed. Works really good if you don't have any textures or anything...at least it did for me...
actually my button has text written on it

any sugestion?
Have your buttons start off as simple rectangles. When the user hovers over one of the buttons, draw a border around it. If the user clicks it, make it a little smaller.
I think the best advice would be to study already existing user interfaces and see how they render buttons- and draw some ideas from there.

For example the standard Win32 button has the left and top edges shaded lightly and the bottom and right edges shaded darkly when it is in a raised state. This gives the appearance that the button is popping up out of the interface. Then when you click the button the shading reverses, which gives the opposite impression- that the button is depressed. Simple techniques such as this can give your buttons a much more 'button like' feel to them; the key really is in the shading.. Another little trick that Windows uses also is to offset the text position slightly (usually down 1 or 2 pixels) when the button is depressed.

This topic is closed to new replies.

Advertisement