GTK+ Forums

Discussion forum for GTK+ and Programming. Ask questions, troubleshoot problems, view and post example code, or express your opinions.
It is currently Wed Oct 01, 2014 8:22 pm

All times are UTC




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: in need for a little help writing a custom widget
PostPosted: Sun Oct 02, 2005 9:09 am 
Offline
Familiar Face

Joined: Wed Sep 21, 2005 4:14 am
Posts: 17
Location: Aachen, Germany
Greetings everybody!

I need help with drawing handle-styles for paned-handles. Take a look here to get an idea of the problem at hand. I wonder what maybe wrong with my handle-drawing code, which look like this:

Code:
GtkStateType state;

if (gtk_widget_is_focus (widget))
   state = GTK_STATE_SELECTED;
else if (xpaned->handle_prelit)
   state = GTK_STATE_PRELIGHT;
else
   state = GTK_WIDGET_STATE (widget);

gtk_paint_handle (widget->style,
            widget->window,
            state,
            GTK_SHADOW_NONE,
            &xpaned->handle_pos_east,
            widget,
            "xpaned",
            xpaned->handle_pos_east.x,
            xpaned->handle_pos_east.y,
            xpaned->handle_pos_east.height,
            xpaned->handle_pos_east.width,
            GTK_ORIENTATION_HORIZONTAL);

gtk_paint_handle (widget->style,
            widget->window,
            state,
            GTK_SHADOW_NONE,
            &xpaned->handle_pos_west,
            widget,
            "xpaned",
            xpaned->handle_pos_west.x,
            xpaned->handle_pos_west.y,
            xpaned->handle_pos_west.height,
            xpaned->handle_pos_west.width,
            GTK_ORIENTATION_HORIZONTAL);

gtk_paint_handle (widget->style,
            widget->window,
            state,
            GTK_SHADOW_NONE,
            &xpaned->handle_pos_north,
            widget,
            "xpaned",
            xpaned->handle_pos_north.x,
            xpaned->handle_pos_north.y,
            xpaned->handle_pos_north.height,
            xpaned->handle_pos_north.width,
            GTK_ORIENTATION_VERTICAL);

gtk_paint_handle (widget->style,
            widget->window,
            state,
            GTK_SHADOW_NONE,
            &xpaned->handle_pos_south,
            widget,
            "xpaned",
            xpaned->handle_pos_south.x,
            xpaned->handle_pos_south.y,
            xpaned->handle_pos_south.height,
            xpaned->handle_pos_south.width,
            GTK_ORIENTATION_VERTICAL);

gtk_paint_handle (widget->style,
            widget->window,
            state,
            GTK_SHADOW_NONE,
            &xpaned->handle_pos_middle,
            widget,
            "xpaned",
            xpaned->handle_pos_middle.x,
            xpaned->handle_pos_middle.y,
            xpaned->handle_pos_middle.height,
            xpaned->handle_pos_middle.width,
            GTK_ORIENTATION_HORIZONTAL);


Thanks in advance for your time and kind advice!

Best regards...

MacSlow

_________________
First they ignore you...
then they laugh at you...
then they fight you...
then you win!
(Gandhi)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group