I made a simple application with a window and some buttons on it.
main.c.gz [1.26 KiB]
Downloaded 48 times
On my Debian Linux the button looks nice, but if compiled and ran on Windows 7, it is very simple (and "ugly").
I want to use my own code for drawing
the buttons. To do that, I connected a signal to the expose event.
In the event callback function, I draw a decorated rectangle and then call the "child" expose event:
// Calling the expose event of the button's child (in my case, label)
This works the same as this:
// Calling the expose event of a "container" class
Everything works, but there is a small difference:
On Linux, when the button is pressed down (when you hold the mouse button
), the label moves
to the left and bottom by 1px.
it stays still
How can I make it consistent?
My idea was to turn off
(remove) the theme
(style). I think it would make the Linux version look like Windows version (with poor button syle), and the label would stay still in both systems.