[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

gEDA-cvs: CVS update: globals.c



  User: ahvezda 
  Date: 06/08/06 12:45:30

  Modified:    .        globals.c gschem.c i_callbacks.c o_basic.c o_copy.c
                        o_delete.c o_grips.c o_misc.c o_move.c o_picture.c
                        x_attribedit.c x_dialog.c x_event.c x_fileselect.c
                        x_image.c x_menus.c x_print.c x_window.c
  Log:
  Applied Patch#1533798: Remove pre-GTK2 code from geda by Peter Brett.  Thanks.
  
  GTK+ 1.2.x specific code is now completely gone from gEDA/gaf. 
  
  
  
  
  Revision  Changes    Path
  1.17      +0 -2      eda/geda/gaf/gschem/src/globals.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: globals.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/globals.c,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- globals.c	14 Jul 2006 02:23:54 -0000	1.16
  +++ globals.c	6 Aug 2006 16:45:29 -0000	1.17
  @@ -53,9 +53,7 @@
   /* these are required by libgeda */
   void (*arc_draw_func)()      = o_arc_draw;
   void (*box_draw_func)()      = o_box_draw;
  -#ifndef HAS_GTK12
   void (*picture_draw_func)()  = o_picture_draw;
  -#endif
   void (*circle_draw_func)()   = o_circle_draw;
   void (*complex_draw_func)()  = o_complex_draw;
   void (*line_draw_func)()     = o_line_draw;
  
  
  
  1.34      +0 -4      eda/geda/gaf/gschem/src/gschem.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: gschem.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/gschem.c,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- gschem.c	15 Jul 2006 18:51:41 -0000	1.33
  +++ gschem.c	6 Aug 2006 16:45:29 -0000	1.34
  @@ -107,9 +107,7 @@
     /* setlocale for LC_NUMERIC (which is important for proper PS output. */
     /* This may look funny here, given we make a call to gtk_set_locale() */
     /* above.  I don't know yet, if this is really the right thing to do. */
  -#ifdef HAS_GTK22
     gtk_disable_setlocale(); 
  -#endif
   
   #endif
   
  @@ -369,10 +367,8 @@
     setlocale(LC_NUMERIC, "POSIX");
     bindtextdomain(PACKAGE, LOCALEDIR);
     textdomain(PACKAGE);
  -#ifdef HAS_GTK22
     bind_textdomain_codeset(PACKAGE, "UTF-8");
   #endif
  -#endif
   
     /* disable the deprecated warnings in guile 1.6.3 */
     /* Eventually the warnings will need to be fixed */
  
  
  
  1.59      +0 -4      eda/geda/gaf/gschem/src/i_callbacks.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: i_callbacks.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/i_callbacks.c,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -b -r1.58 -r1.59
  --- i_callbacks.c	15 Jul 2006 18:51:41 -0000	1.58
  +++ i_callbacks.c	6 Aug 2006 16:45:29 -0000	1.59
  @@ -1843,14 +1843,11 @@
     gchar *filename;
     int page_control;
     int up;
  -#ifdef HAS_GTK22
     int response;
     GtkWidget* dialog;
  -#endif
   
     exit_if_null(w_current);
   
  -#ifdef HAS_GTK22
    dialog = gtk_message_dialog_new ((GtkWindow*) w_current->main_window,
                                     GTK_DIALOG_DESTROY_WITH_PARENT,
                                     GTK_MESSAGE_QUESTION,
  @@ -1869,7 +1866,6 @@
      /* just fall through */
      break;
    }
  -#endif
   
     /* save this for later */
     filename = g_strdup (w_current->page_current->page_filename);
  
  
  
  1.20      +0 -2      eda/geda/gaf/gschem/src/o_basic.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: o_basic.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/o_basic.c,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- o_basic.c	14 Jul 2006 02:23:54 -0000	1.19
  +++ o_basic.c	6 Aug 2006 16:45:29 -0000	1.20
  @@ -706,9 +706,7 @@
   
        case(DRAWPICTURE):
        case(ENDPICTURE):
  -#ifndef HAS_GTK12
           o_picture_eraserubber(w_current);
  -#endif
        break;
   
        case(DRAWCIRCLE):
  
  
  
  1.26      +1 -2      eda/geda/gaf/gschem/src/o_copy.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: o_copy.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/o_copy.c,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- o_copy.c	6 Aug 2006 15:43:12 -0000	1.25
  +++ o_copy.c	6 Aug 2006 16:45:29 -0000	1.26
  @@ -303,7 +303,6 @@
           
           break;
   
  -#ifndef HAS_GTK12
         case(OBJ_PICTURE):
           new_object = (OBJECT *) o_picture_copy(w_current,
   					       return_tail(new_objects_head),
  @@ -326,7 +325,7 @@
           o_picture_draw(w_current, new_object);
           
           break;
  -#endif
  +
         case(OBJ_CIRCLE):
           new_object = (OBJECT *) o_circle_copy(w_current,
                                                 return_tail(new_objects_head),
  
  
  
  1.22      +0 -4      eda/geda/gaf/gschem/src/o_delete.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: o_delete.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/o_delete.c,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- o_delete.c	14 Jul 2006 02:23:55 -0000	1.21
  +++ o_delete.c	6 Aug 2006 16:45:29 -0000	1.22
  @@ -165,7 +165,6 @@
     (OBJECT *) return_tail(w_current->page_current->object_head);
   }
   
  -#ifndef HAS_GTK12
   
   /*! \todo Finish function documentation!!!
    *  \brief
  @@ -181,7 +180,6 @@
     w_current->page_current->object_tail =
     (OBJECT *) return_tail(w_current->page_current->object_head);
   }
  -#endif
   
   /*! \todo Finish function documentation!!!
    *  \brief
  @@ -276,9 +274,7 @@
           break;
   
         case(OBJ_PICTURE):
  -#ifndef HAS_GTK12
           o_delete_picture(w_current, object);
  -#endif
           break;
   
         case(OBJ_CIRCLE):
  
  
  
  1.10      +1 -16     eda/geda/gaf/gschem/src/o_grips.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: o_grips.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/o_grips.c,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- o_grips.c	14 Jul 2006 02:23:55 -0000	1.9
  +++ o_grips.c	6 Aug 2006 16:45:29 -0000	1.10
  @@ -121,11 +121,9 @@
   		  
           case(OBJ_PICTURE):
             /* check the grips of the picture object */
  -#ifndef HAS_GTK12
             found = o_grips_search_picture(w_current, object,
                                            x, y, size, whichone);
             if(found != NULL) return found;
  -#endif
             break;
   		  
           case(OBJ_CIRCLE):
  @@ -326,7 +324,6 @@
     return NULL;
   }
   
  -#ifndef HAS_GTK12
   /*! \brief Check if pointer is inside picture grip.
    *  \par Function Description
    *  This function checks if the pointer event occuring at (<B>x</B>,<B>y</B>)
  @@ -405,7 +402,6 @@
   
     return NULL;
   }
  -#endif
   
   /*! \brief Check if pointer is inside circle grip.
    *  \par Function Description
  @@ -565,13 +561,11 @@
   				
         case(OBJ_PICTURE):
   	/* start the modification of a grip on a picture */
  -#ifndef HAS_GTK12
           o_grips_start_picture(w_current, object, x, y, whichone);
   				
           whichone_changing = whichone;
           object_changing = object;
           return(TRUE);
  -#endif
           break;
   				
         case(OBJ_CIRCLE):
  @@ -786,7 +780,6 @@
   
   }
   
  -#ifndef HAS_GTK12
   /*! \brief Initialize grip motion process for a picture.
    *  \par Function Description
    *  This function initializes the grip motion process for a picture.
  @@ -854,7 +847,7 @@
     o_picture_rubberbox_xor(w_current);
   
   }
  -#endif
  +
   /*! \brief Initialize grip motion process for a circle.
    *  \par Function Description
    *  This function initializes the grip motion process for a circle.
  @@ -984,9 +977,7 @@
   		
       case(OBJ_PICTURE):
       /* erase, update and draw a box */
  -#ifndef HAS_GTK12
       o_grips_motion_picture(w_current, x, y, whichone_changing);
  -#endif
       break;
   		
       case(OBJ_CIRCLE):
  @@ -1063,7 +1054,6 @@
     o_box_rubberbox(w_current, x, y);
   }
   
  -#ifndef HAS_GTK12
   /*! \brief Modify previously selected picture according to mouse position.
    *  \par Function Description
    *  This function is the refreshing part of the grip motion process. It is
  @@ -1087,7 +1077,6 @@
     /* erase, update and draw the temporary picture */
     o_picture_rubberbox(w_current, x, y);
   }
  -#endif
   
   /*! \brief Modify previously selected circle according to mouse position.
    *  \par Function Description
  @@ -1179,9 +1168,7 @@
   	  
       case(OBJ_PICTURE):
       /* modify a picture object */
  -#ifndef HAS_GTK12
       o_grips_end_picture(w_current, object, whichone_changing);
  -#endif
       break;
   	  
       case(OBJ_CIRCLE):
  @@ -1543,7 +1530,6 @@
     o_redraw_single(w_current, o_current);
   }
   
  -#ifndef HAS_GTK12
   /*! \todo Finish function documentation!!!
    *  \brief End process of modifying picture object with grip.
    *  \par Function Description
  @@ -1596,7 +1582,6 @@
     w_current->pixbuf_filename = NULL;
     w_current->pixbuf_wh_ratio = 0;
   }
  -#endif
   
   /*! \brief End process of modifying circle object with grip.
    *  \par Function Description
  
  
  
  1.34      +0 -6      eda/geda/gaf/gschem/src/o_misc.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: o_misc.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/o_misc.c,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- o_misc.c	15 Jul 2006 18:51:41 -0000	1.33
  +++ o_misc.c	6 Aug 2006 16:45:29 -0000	1.34
  @@ -123,9 +123,7 @@
       break;
   
       case(OBJ_PICTURE):
  -#ifndef HAS_GTK12
       picture_change_filename_dialog(w_current);
  -#endif
       break;
       case(OBJ_TEXT):
       if(strchr(o_current->text->string,'=')) {
  @@ -449,7 +447,6 @@
   
         case(OBJ_PICTURE):
   				/* erase the current selection */
  -#ifndef HAS_GTK12
   	
   	if (!w_current->DONT_REDRAW) {
   	  o_picture_erase_grips(w_current, object);
  @@ -462,7 +459,6 @@
   	if (!w_current->DONT_REDRAW) {
   	  o_picture_draw(w_current, object);
   	}
  -#endif
           break;
   
         case(OBJ_CIRCLE):
  @@ -834,13 +830,11 @@
           break;
   
         case(OBJ_PICTURE):
  -#ifndef HAS_GTK12
           o_picture_erase_grips(w_current, object);
           o_picture_erase(w_current, object);
           o_picture_mirror(w_current,
   			 centerx, centery, object);
           o_picture_draw(w_current, object);
  -#endif
           break;
   
         case(OBJ_CIRCLE):
  
  
  
  1.29      +0 -2      eda/geda/gaf/gschem/src/o_move.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: o_move.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/o_move.c,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- o_move.c	14 Jul 2006 02:23:55 -0000	1.28
  +++ o_move.c	6 Aug 2006 16:45:29 -0000	1.29
  @@ -127,9 +127,7 @@
           break;
   
         case (OBJ_PICTURE):
  -#ifndef HAS_GTK12
           o_picture_translate_world(w_current, diff_x, diff_y, object);
  -#endif
           break;
   
         case (OBJ_CIRCLE):
  
  
  
  1.4       +0 -30     eda/geda/gaf/gschem/src/o_picture.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: o_picture.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/o_picture.c,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- o_picture.c	15 Jul 2006 20:49:52 -0000	1.3
  +++ o_picture.c	6 Aug 2006 16:45:29 -0000	1.4
  @@ -21,14 +21,10 @@
   #include <stdio.h>
   
   #include <libgeda/libgeda.h>
  -#ifndef HAS_GTK12
   #include <gdk-pixbuf/gdk-pixbuf.h>
  -#endif
   #include "../include/globals.h"
   #include "../include/prototype.h"
   
  -#ifndef HAS_GTK12
  -
   /* This works, but using one macro inside of other doesn't */
   #define GET_PICTURE_WIDTH(w)			\
   	abs((w)->last_x - (w)->start_x) 
  @@ -160,7 +156,6 @@
     o_undo_savestate(w_current, UNDO_ALL);
   
   }
  -#endif
   
   /*! \todo Finish function documentation!!!
    *  \brief
  @@ -169,28 +164,6 @@
    */
   void picture_selection_dialog (TOPLEVEL *w_current)
   {
  -#ifdef HAS_GTK12
  -  GtkWidget *dialog, *label, *okay_button;
  -  
  -  /* Create the widgets */
  -  
  -  dialog = gtk_dialog_new();
  -  label = gtk_label_new (_("Gschem doesn't support pictures if it has been compiled using GTK 1.2"));
  -  okay_button = gtk_button_new_with_label(_("OK"));
  -   
  -  /* Ensure that the dialog box is destroyed when the user clicks ok. */
  -  
  -  gtk_signal_connect_object (GTK_OBJECT (okay_button), "clicked",
  -			     GTK_SIGNAL_FUNC (gtk_widget_destroy), dialog);
  -  gtk_container_add (GTK_CONTAINER (GTK_DIALOG(dialog)->action_area),
  -		     okay_button);
  -  
  -  /* Add the label, and show everything we've added to the dialog. */
  -  
  -  gtk_container_add (GTK_CONTAINER (GTK_DIALOG(dialog)->vbox),
  -		     label);
  -  gtk_widget_show_all (dialog);
  -#else
     GtkWidget *file_selector;
     
     /* Create the selector */
  @@ -234,10 +207,8 @@
     } else {
       gdk_window_raise(w_current->pfswindow->window);
     }
  -#endif
   }
   
  -#ifndef HAS_GTK12
   /*! \todo Finish function documentation!!!
    *  \brief
    *  \par Function Description
  @@ -903,4 +874,3 @@
        gdk_window_raise(w_current->pcfswindow->window);
      }
   }
  -#endif
  
  
  
  1.3       +0 -16     eda/geda/gaf/gschem/src/x_attribedit.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_attribedit.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_attribedit.c,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- x_attribedit.c	15 Jul 2006 18:51:41 -0000	1.2
  +++ x_attribedit.c	6 Aug 2006 16:45:29 -0000	1.3
  @@ -358,11 +358,7 @@
       }
       s_current = s_current->next;
     }
  -#ifdef HAS_GTK22
     aewindow = gtk_window_new (GTK_WINDOW_TOPLEVEL);
  -#else
  -  aewindow = gtk_window_new (GTK_WINDOW_DIALOG);
  -#endif
     gtk_object_set_data (GTK_OBJECT (aewindow), "aewindow", aewindow);
     gtk_window_set_title (GTK_WINDOW (aewindow), _("Single Attribute Editor"));
     gtk_window_set_position (GTK_WINDOW (aewindow), GTK_WIN_POS_MOUSE);
  @@ -393,11 +389,7 @@
     gtk_box_pack_start (GTK_BOX (hbox1), hbuttonbox1, TRUE, TRUE, 0);
     gtk_container_set_border_width (GTK_CONTAINER (hbuttonbox1), 1);
   
  -#ifdef HAS_GTK12
  -  okbutton = gtk_button_new_with_label ("OK");
  -#else
     okbutton = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
     gtk_widget_ref (okbutton);
     gtk_object_set_data_full (GTK_OBJECT (aewindow), "okbutton", okbutton,
                               (GtkDestroyNotify) gtk_widget_unref);
  @@ -408,11 +400,7 @@
     gtk_button_set_relief (GTK_BUTTON (okbutton), GTK_RELIEF_HALF);
   
     if (list) { /* gschem specific */
  -#ifdef HAS_GTK12
  -    deletebutton = gtk_button_new_with_label (_("Delete"));
  -#else
       deletebutton = gtk_button_new_from_stock (GTK_STOCK_DELETE);
  -#endif
       gtk_widget_ref (deletebutton);
       gtk_object_set_data_full (GTK_OBJECT (aewindow), "deletebutton", deletebutton,
                                 (GtkDestroyNotify) gtk_widget_unref);
  @@ -422,11 +410,7 @@
       GTK_WIDGET_SET_FLAGS (deletebutton, GTK_CAN_DEFAULT);
     }
   
  -#ifdef HAS_GTK12
  -  cancelbutton = gtk_button_new_with_label (_("Cancel"));
  -#else
     cancelbutton = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
     gtk_widget_ref (cancelbutton);
     gtk_object_set_data_full (GTK_OBJECT (aewindow), "cancelbutton", cancelbutton,
                               (GtkDestroyNotify) gtk_widget_unref);
  
  
  
  1.58      +1 -218    eda/geda/gaf/gschem/src/x_dialog.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_dialog.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_dialog.c,v
  retrieving revision 1.57
  retrieving revision 1.58
  diff -u -b -r1.57 -r1.58
  --- x_dialog.c	15 Jul 2006 18:51:41 -0000	1.57
  +++ x_dialog.c	6 Aug 2006 16:45:29 -0000	1.58
  @@ -115,20 +115,14 @@
     int len;
     char *string = NULL;
     GtkWidget *tientry;
  -#ifdef HAS_GTK22
     GtkTextBuffer *textbuffer;
     GtkTextIter start, end;
  -#endif
   
     tientry = gtk_object_get_data(GTK_OBJECT(w_current->tiwindow),"tientry");
   
  -#ifdef HAS_GTK22
     textbuffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(tientry));
     gtk_text_buffer_get_bounds (textbuffer, &start, &end);
     string =  gtk_text_iter_get_text (&start, &end);
  -#else
  -  string = gtk_entry_get_text(GTK_ENTRY(tientry));
  -#endif
   
     if (string[0] != '\0' ) {
       len = strlen(string);
  @@ -152,15 +146,8 @@
   
       o_attrib_set_string(w_current, string);
       w_current->page_current->CHANGED=1;
  -#ifdef HAS_GTK22
       gtk_text_buffer_set_text(textbuffer, w_current->current_attribute, -1);
       select_all_text_in_textview(GTK_TEXT_VIEW(tientry));
  -#else
  -    gtk_entry_set_text(GTK_ENTRY(tientry),
  -                       w_current->current_attribute);
  -    gtk_entry_select_region(GTK_ENTRY(tientry),
  -                            0, len);
  -#endif
       gtk_widget_grab_focus(tientry);
   
       w_current->event_state = DRAWTEXT;
  @@ -202,12 +189,10 @@
     GtkWidget *buttonok     = NULL;
     GtkWidget *buttoncancel = NULL;
     GtkWidget *vbox, *action_area;
  -#ifdef HAS_GTK22
     GtkWidget *viewport1 = NULL;
     GtkWidget *scrolled_window = NULL;
     PangoTabArray *tab_array;
     int real_tab_width;
  -#endif
   
     if (!w_current->tiwindow) {
       w_current->tiwindow = x_create_dialog_box(&vbox, &action_area);
  @@ -246,7 +231,6 @@
       gtk_box_pack_start(GTK_BOX(vbox), label, FALSE, TRUE, 5);
       gtk_widget_show (label);
   
  -#ifdef HAS_GTK22
       viewport1 = gtk_viewport_new (NULL, NULL);
       gtk_widget_show (viewport1);
       
  @@ -278,26 +262,13 @@
       }
       pango_tab_array_free (tab_array);
       gtk_container_add(GTK_CONTAINER(scrolled_window), tientry);
  -#else
  -    tientry = gtk_entry_new_with_max_length (79);
  -    gtk_editable_select_region(GTK_EDITABLE(tientry),
  -			       0, -1);
  -    gtk_signal_connect(GTK_OBJECT(tientry), "activate",
  -                       GTK_SIGNAL_FUNC(text_input_dialog_apply),
  -                       w_current);
  -    gtk_box_pack_start(GTK_BOX(vbox), tientry, TRUE, TRUE, 10);
  -#endif
   
       gtk_widget_show(tientry);
       gtk_widget_grab_focus(tientry);
       gtk_object_set_data(GTK_OBJECT(w_current->tiwindow),
                           "tientry",tientry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label(_("Apply"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_APPLY);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -308,11 +279,7 @@
       gtk_widget_show (buttonok);
       gtk_widget_grab_default (buttonok);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Close"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -502,22 +469,16 @@
     char *text_size_string = NULL;
     int new_text_alignment;
     int num_selected;
  -#ifdef HAS_GTK22
     GtkTextBuffer *textbuffer;
     GtkTextIter start, end;
  -#endif
   
     num_selected = o_selection_return_num(w_current->page_current->selection2_head);
   
     /* text string entry will only show up if one object is selected */
     if (num_selected == 1) {
  -#ifdef HAS_GTK22
       textbuffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(w_current->teentry));
       gtk_text_buffer_get_bounds (textbuffer, &start, &end);
       text_string =  gtk_text_iter_get_text (&start, &end);
  -#else
  -    text_string = (char *) gtk_entry_get_text(GTK_ENTRY(w_current->teentry));
  -#endif
     } /* else the string will be null which is okay */
     
     text_size_string = (char *) gtk_entry_get_text(GTK_ENTRY(w_current->tsentry));
  @@ -574,11 +535,9 @@
     GtkWidget *vbox, *action_area;
     GtkWidget *optionmenu = NULL;
     GtkWidget *align_menu = NULL;
  -#ifdef HAS_GTK22
     GtkWidget *viewport1 = NULL;
     GtkWidget *scrolled_window = NULL;
     GtkTextBuffer *textbuffer;
  -#endif
     char *text_size_string;
     int len;
     int num_selected;
  @@ -621,7 +580,6 @@
         gtk_box_pack_start(GTK_BOX(vbox), label, FALSE, TRUE, 3);
         gtk_widget_show (label);
   
  -#ifdef HAS_GTK22
         viewport1 = gtk_viewport_new (NULL, NULL);
         gtk_widget_show (viewport1);
   
  @@ -641,14 +599,6 @@
         /* See first the code in text_input_dialog and get it working before adding it here. */
   
         gtk_container_add(GTK_CONTAINER(scrolled_window), w_current->teentry);
  -#else
  -      w_current->teentry = gtk_entry_new();
  -      gtk_editable_select_region(GTK_EDITABLE(w_current->teentry), 0, -1);
  -      gtk_signal_connect(GTK_OBJECT(w_current->teentry), "activate",
  -                         GTK_SIGNAL_FUNC(text_edit_dialog_ok),
  -                         w_current);
  -      gtk_box_pack_start(GTK_BOX(vbox), w_current->teentry, TRUE, TRUE, 10);
  -#endif
   
         gtk_widget_show (w_current->teentry);
         gtk_widget_grab_focus(w_current->teentry);
  @@ -700,11 +650,7 @@
       gtk_widget_show(optionmenu);
   
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label (_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -715,11 +661,7 @@
       gtk_widget_show(buttonok);
       gtk_widget_grab_default(buttonok);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
       GTK_WIDGET_SET_FLAGS(buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -736,16 +678,9 @@
       if (string != NULL) {
         len = strlen(string);
         if (num_selected == 1) { /* only if one thing is selected */
  -#ifdef HAS_GTK22
   	textbuffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(w_current->teentry));
   	gtk_text_buffer_set_text(GTK_TEXT_BUFFER(textbuffer), string, -1);
   	select_all_text_in_textview(GTK_TEXT_VIEW(w_current->teentry));
  -#else
  -        gtk_entry_set_text(GTK_ENTRY(w_current->teentry),
  -			   string);
  -	gtk_entry_select_region(GTK_ENTRY(w_current->teentry),
  -				0, len);
  -#endif
         }
       }
   
  @@ -1071,11 +1006,7 @@
                        space_entry,
                        TRUE, TRUE, 10);
   
  -#ifdef HAS_GTK12
  -  buttonok = gtk_button_new_with_label (_("OK"));
  -#else
     buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
     GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
     gtk_box_pack_start(GTK_BOX(action_area),
                        buttonok,
  @@ -1085,11 +1016,7 @@
                        line_type_data);
     gtk_widget_grab_default(buttonok);
   
  -#ifdef HAS_GTK12
  -  buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
     buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
     GTK_WIDGET_SET_FLAGS(buttoncancel, GTK_CAN_DEFAULT);
     gtk_box_pack_start(GTK_BOX(action_area),
                        buttoncancel,
  @@ -1522,11 +1449,7 @@
                         fill_type_data);
   
   		
  -#ifdef HAS_GTK12
  -  buttonok = gtk_button_new_with_label (_("OK"));
  -#else
     buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
     GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
     gtk_box_pack_start (GTK_BOX (action_area),
                         buttonok,
  @@ -1536,11 +1459,7 @@
                         fill_type_data);
     gtk_widget_grab_default (buttonok);
   
  -#ifdef HAS_GTK12
  -  buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
     buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
     GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
     gtk_box_pack_start (GTK_BOX (action_area),
                         buttoncancel,
  @@ -1731,22 +1650,14 @@
       gtk_box_pack_start (GTK_BOX (vbox1), hbuttonbox1, FALSE, FALSE, 0);
       gtk_container_set_border_width (GTK_CONTAINER (hbuttonbox1), 10);
   
  -#ifdef HAS_GTK12
  -    button1 = gtk_button_new_with_label (_("OK"));
  -#else
       button1 = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       gtk_widget_show (button1);
       gtk_container_add (GTK_CONTAINER (hbuttonbox1), button1);
       GTK_WIDGET_SET_FLAGS (button1, GTK_CAN_DEFAULT);
       gtk_signal_connect(GTK_OBJECT (button1), "clicked",
                          GTK_SIGNAL_FUNC(exit_dialog_ok), w_current);
   
  -#ifdef HAS_GTK12
  -    button2 = gtk_button_new_with_label (_("Cancel"));
  -#else
       button2 = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
       gtk_widget_show (button2);
       gtk_container_add (GTK_CONTAINER (hbuttonbox1), button2);
       GTK_WIDGET_SET_FLAGS (button2, GTK_CAN_DEFAULT);
  @@ -1893,11 +1804,7 @@
                          w_current);
       gtk_widget_show(w_current->aaentry_sweep);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label (_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start (
   			GTK_BOX(action_area),
  @@ -1908,11 +1815,7 @@
       gtk_widget_show (buttonok);
       gtk_widget_grab_default (buttonok);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start (GTK_BOX (action_area),
                           buttoncancel, TRUE, TRUE, 0);
  @@ -2046,11 +1949,7 @@
       gtk_widget_show (w_current->trentry);
       gtk_widget_grab_focus(w_current->trentry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label (_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start (GTK_BOX (action_area),
                           buttonok, TRUE, TRUE, 0);
  @@ -2060,11 +1959,7 @@
       gtk_widget_show (buttonok);
       gtk_widget_grab_default (buttonok);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -2203,11 +2098,7 @@
       gtk_widget_show (w_current->tsentry);
       gtk_widget_grab_focus(w_current->tsentry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label (_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -2218,11 +2109,7 @@
       gtk_widget_show (buttonok);
       gtk_widget_grab_default (buttonok);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -2360,11 +2247,7 @@
       gtk_widget_show(w_current->tsentry);
       gtk_widget_grab_focus(w_current->tsentry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label (_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -2375,11 +2258,7 @@
       gtk_widget_show (buttonok);
       gtk_widget_grab_default (buttonok);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -2528,11 +2407,7 @@
       gtk_widget_show (w_current->seentry);
       gtk_widget_grab_focus(w_current->seentry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label (_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -2543,11 +2418,7 @@
       gtk_widget_show (buttonok);
       gtk_widget_grab_default (buttonok);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start (GTK_BOX (action_area), buttoncancel, 
                           TRUE, TRUE, 0);
  @@ -2665,11 +2536,7 @@
                          label, TRUE, TRUE, 5);
       gtk_widget_show (label);
   
  -#ifdef HAS_GTK12
  -    buttonclose = gtk_button_new_with_label (_("Close"));
  -#else
       buttonclose = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonclose, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -2804,11 +2671,7 @@
       gtk_widget_show(w_current->coord_world);
       gtk_widget_show(frame);
   
  -#ifdef HAS_GTK12
  -    buttonclose = gtk_button_new_with_label (_("Close"));
  -#else
       buttonclose = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonclose, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX ( vbox2 ),
                          buttonclose, TRUE, TRUE, 0);
  @@ -3142,11 +3005,7 @@
                          optionmenu, TRUE, TRUE, 0);
       gtk_widget_show (optionmenu);
   
  -#ifdef HAS_GTK12
  -    buttonapply = gtk_button_new_with_label (_("Apply"));
  -#else
       buttonapply = gtk_button_new_from_stock (GTK_STOCK_APPLY);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonapply, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -3157,11 +3016,7 @@
       gtk_widget_show (buttonapply);
       gtk_widget_grab_default(buttonapply);
   
  -#ifdef HAS_GTK12
  -    buttonclose = gtk_button_new_with_label (_("Close"));
  -#else
       buttonclose = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
       gtk_box_pack_start(
                          GTK_BOX(action_area),
                          buttonclose, TRUE, TRUE, 0);
  @@ -3334,11 +3189,7 @@
         }
       }
   
  -#ifdef HAS_GTK12
  -    buttonclose = gtk_button_new_with_label (_("Close"));
  -#else
       buttonclose = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonclose, GTK_CAN_DEFAULT);
       gtk_box_pack_start(
                          GTK_BOX(action_area),
  @@ -3684,11 +3535,7 @@
       gtk_widget_show(w_current->tsentry);
       gtk_widget_grab_focus(w_current->tsentry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label(_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS(buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX(action_area), buttonok, TRUE, TRUE, 0);
       gtk_signal_connect(GTK_OBJECT(buttonok), "clicked",
  @@ -3842,21 +3689,13 @@
       /*          gtk_object_set_data (GTK_OBJECT (w_current->tswindow), "descend", w_current->preview_checkbox);*/
       gtk_box_pack_start(GTK_BOX(vbox), checkdescend, TRUE, TRUE, 0);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label(_("Find"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_FIND);
  -#endif
       GTK_WIDGET_SET_FLAGS(buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX(action_area), buttonok, TRUE, TRUE, 0);
       gtk_signal_connect(GTK_OBJECT(buttonok), "clicked",
   		       GTK_SIGNAL_FUNC(find_text_ok), w_current);
   
  -#ifdef HAS_GTK12
  -    buttondone = gtk_button_new_with_label(_("Done"));
  -#else
       buttondone = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
       GTK_WIDGET_SET_FLAGS(buttondone, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX(action_area), buttondone, TRUE, TRUE, 0);
       gtk_signal_connect(GTK_OBJECT(buttondone), "clicked",
  @@ -3981,11 +3820,7 @@
       gtk_widget_show(w_current->tsentry);
       gtk_widget_grab_focus(w_current->tsentry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label(_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS(buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX(action_area), buttonok, TRUE, TRUE, 0);
       gtk_signal_connect(GTK_OBJECT(buttonok), "clicked",
  @@ -4105,11 +3940,7 @@
       gtk_widget_show(w_current->tsentry);
       gtk_widget_grab_focus(w_current->tsentry);
   
  -#ifdef HAS_GTK12
  -    buttonok = gtk_button_new_with_label(_("OK"));
  -#else
       buttonok = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS(buttonok, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX(action_area), buttonok, TRUE, TRUE, 0);
       gtk_signal_connect(GTK_OBJECT(buttonok), "clicked",
  @@ -4428,7 +4259,7 @@
   /*********** End of autonumber text dialog box *******/
   
   /*********** Start of some Gtk utils  *******/
  -#ifdef HAS_GTK22
  +
   /*! \todo Finish function documentation!!!
    *  \brief
    *  \par Function Description
  @@ -4446,9 +4277,7 @@
     mark = gtk_text_buffer_get_selection_bound(textbuffer);
     gtk_text_buffer_move_mark(textbuffer, mark, &end);
   }
  -#endif
   
  -#ifdef HAS_GTK22
   /*! \todo Finish function documentation!!!
    *  \brief
    *  \par Function Description
  @@ -4487,46 +4316,10 @@
     return tab_width;
   
   }
  -#endif
   
   /*********** End of some Gtk utils *******/
   
   /*********** Start of major symbol changed dialog box *******/
  -#ifdef HAS_GTK12
  -/*! \todo Finish function documentation!!!
  - *  \brief
  - *  \par Function Description
  - *
  - */
  -void quick_message_dialog(char *message)
  -{
  -  GtkWidget *dialog, *label, *close_button;
  -   
  -  /* Create the widgets */
  -   
  -  dialog = gtk_dialog_new();
  -  label = gtk_label_new (message);
  -#ifdef HAS_GTK12
  -  close_button = gtk_button_new_with_label("Close");
  -#else
  -  close_button = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
  -   
  -  /* Ensure that the dialog box is destroyed when the user clicks ok. */
  -   
  -  gtk_signal_connect_object (GTK_OBJECT (close_button), "clicked",
  -                             GTK_SIGNAL_FUNC (gtk_widget_destroy), 
  -                             (gpointer) dialog);
  -  gtk_container_add (GTK_CONTAINER (GTK_DIALOG(dialog)->action_area),
  -                     close_button);
  -
  -  /* Add the label, and show everything we've added to the dialog. */
  -
  -  gtk_container_add (GTK_CONTAINER (GTK_DIALOG(dialog)->vbox),
  -                     label);
  -  gtk_widget_show_all (dialog);
  -}
  -#endif
   
   /*! \todo Finish function documentation!!!
    *  \brief
  @@ -4564,7 +4357,6 @@
       g_free(refdes_string);
       refdes_string = tmp;
   
  -#ifdef HAS_GTK22
       dialog = gtk_message_dialog_new ((GtkWindow*) w_current->main_window,
                                        GTK_DIALOG_DESTROY_WITH_PARENT,
                                        GTK_MESSAGE_ERROR,
  @@ -4577,15 +4369,6 @@
       g_signal_connect_swapped (dialog, "response",
                                 G_CALLBACK (gtk_widget_destroy),
                                 dialog);
  -#else
  -    tmp = g_strconcat(
  -      "\n  Major symbol changes detected in refdes:  \n\n", 
  -      refdes_string, 
  -      NULL);
  -    g_free(refdes_string);
  -    refdes_string = tmp;
  -    quick_message_dialog(refdes_string);
  -#endif
   
       if (refdes_string) g_free(refdes_string);
     }
  
  
  
  1.38      +0 -10     eda/geda/gaf/gschem/src/x_event.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_event.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_event.c,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -b -r1.37 -r1.38
  --- x_event.c	6 Aug 2006 15:55:56 -0000	1.37
  +++ x_event.c	6 Aug 2006 16:45:29 -0000	1.38
  @@ -271,23 +271,19 @@
           break;
   
         case(DRAWPICTURE):
  -#ifndef HAS_GTK12
           o_picture_start(w_current,
                       (int) event->x,
                       (int) event->y);
           w_current->event_state = ENDPICTURE;
           w_current->inside_action = 1;
  -#endif
           break;
   
         case(ENDPICTURE):
  -#ifndef HAS_GTK12
           o_picture_end(w_current,
                     (int) event->x,
                     (int) event->y);
           w_current->inside_action = 0;
           w_current->event_state = DRAWPICTURE;
  -#endif
           break;
   
         case(DRAWCIRCLE):
  @@ -631,11 +627,9 @@
   
           case(DRAWPICTURE):
           case(ENDPICTURE):
  -#ifndef HAS_GTK12
           w_current->inside_action = 0;
   	i_set_state(w_current, DRAWPICTURE);
           o_picture_eraserubber(w_current);
  -#endif
           break;
   
           case(DRAWCIRCLE):
  @@ -1129,12 +1123,10 @@
       break;
   
       case(ENDPICTURE):
  -#ifndef HAS_GTK12
       if (w_current->inside_action)
       o_picture_rubberbox( w_current,
                           (int) event->x,
                           (int) event->y);
  -#endif
       break;
   
       case(ENDCIRCLE):
  @@ -1538,7 +1530,6 @@
     return(0);
   }
   
  -#ifdef HAS_GTK22
   
   /*! \todo Finish function documentation!!!
    *  \brief
  @@ -1632,4 +1623,3 @@
   
     return(0);
   }
  -#endif
  
  
  
  1.22      +0 -46     eda/geda/gaf/gschem/src/x_fileselect.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_fileselect.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_fileselect.c,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- x_fileselect.c	15 Jul 2006 18:51:41 -0000	1.21
  +++ x_fileselect.c	6 Aug 2006 16:45:29 -0000	1.22
  @@ -447,13 +447,8 @@
       text[0] = temp; 
       gtk_clist_append (GTK_CLIST (f_current->dir_list), text);
   
  -#ifdef HAS_GTK22
       width = gdk_string_width(gtk_style_get_font(f_current->dir_list->style),
                                f_current->directory_entries[i]);
  -#else
  -    width = gdk_string_width(f_current->dir_list->style->font,
  -                             f_current->directory_entries[i]);
  -#endif
   
       if (width > max_width) {
         gtk_clist_set_column_width(GTK_CLIST(f_current->
  @@ -472,13 +467,8 @@
       text[0] = f_current->file_entries[i]; 
       gtk_clist_append (GTK_CLIST (f_current->file_list), text);
   
  -#ifdef HAS_GTK22
       width = gdk_string_width(gtk_style_get_font(f_current->dir_list->style), 
                                f_current->file_entries[i]);
  -#else
  -    width = gdk_string_width(f_current->dir_list->style->font,
  -                             f_current->file_entries[i]);
  -#endif
   
       if (width > max_width) {
         gtk_clist_set_column_width(GTK_CLIST(f_current->
  @@ -1285,13 +1275,8 @@
       
       gtk_clist_append (GTK_CLIST (f_current->dir_list), text);
   
  -#ifdef HAS_GTK22
       width = gdk_string_width(gtk_style_get_font(f_current->dir_list->style), 
                                text[0]);
  -#else
  -    width = gdk_string_width(f_current->dir_list->style->font,
  -                             text[0]);
  -#endif
   
       if (width > max_width) {
         gtk_clist_set_column_width(GTK_CLIST(f_current->
  @@ -1365,14 +1350,9 @@
       /* add filename to the clist */
       gtk_clist_append (GTK_CLIST (f_current->file_list), text);
       
  -#ifdef HAS_GTK22
       width = gdk_string_width (gtk_style_get_font (
                                   f_current->file_list->style),
                                 (gchar*) filename->data);
  -#else
  -    width = gdk_string_width (f_current->file_list->style->font,
  -                              (gchar*) filename->data);
  -#endif
       if (width > max_width) {
         /* increase the width of the column */
         gtk_clist_set_column_width (GTK_CLIST (f_current->file_list),
  @@ -2112,11 +2092,7 @@
   
       /*  ----- Here we create the "open"/"save as"/"apply" buttons -----  */
       if (filesel_type == OPEN) {
  -#ifdef HAS_GTK12
  -      buttonapply = gtk_button_new_with_label (_("Open"));
  -#else
         buttonapply = gtk_button_new_from_stock (GTK_STOCK_OPEN);
  -#endif
         gtk_signal_connect(GTK_OBJECT(buttonapply),
                            /* Here we attach callback fileselect_open_file to
                               the "Open" button */
  @@ -2129,21 +2105,13 @@
                  (filesel_type == SAVEAS_OPEN) ||
                  (filesel_type == SAVEAS_CLOSE) ||
                  (filesel_type == SAVEAS_NEW)) { 
  -#ifdef HAS_GTK12
  -      buttonapply = gtk_button_new_with_label (_("SaveAs"));
  -#else
         buttonapply = gtk_button_new_from_stock (GTK_STOCK_SAVE_AS);
  -#endif
         gtk_signal_connect(GTK_OBJECT(buttonapply),
                            "clicked",
                            GTK_SIGNAL_FUNC(x_fileselect_saveas),
                            f_current);
       } else if (type == COMPSELECT) {
  -#ifdef HAS_GTK12
  -      buttonapply = gtk_button_new_with_label (_("Apply"));
  -#else
         buttonapply = gtk_button_new_from_stock (GTK_STOCK_APPLY);
  -#endif
         gtk_signal_connect(GTK_OBJECT(buttonapply),
                            "clicked",
                            GTK_SIGNAL_FUNC(x_fileselect_comp_apply),
  @@ -2160,12 +2128,7 @@
       /*  ----- Here we create the "cancel"/"close" buttons -----  */
       if (type == FILESELECT) {
         if (filesel_type == OPEN) {
  -#ifdef HAS_GTK12
  -        buttonclose = gtk_button_new_with_label (
  -                                                 _("Cancel"));
  -#else
   	buttonclose = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
           GTK_WIDGET_SET_FLAGS(buttonclose, 
                                GTK_CAN_DEFAULT);
           gtk_box_pack_start(GTK_BOX(action_area),
  @@ -2183,12 +2146,7 @@
                    (filesel_type == SAVEAS_OPEN) ||
                    (filesel_type == SAVEAS_CLOSE) ||
                    (filesel_type == SAVEAS_NEW)) { 
  -#ifdef HAS_GTK12
  -        buttonclose = gtk_button_new_with_label (
  -                                                 _("Cancel"));
  -#else
   	buttonclose = gtk_button_new_from_stock (GTK_STOCK_CANCEL);
  -#endif
           GTK_WIDGET_SET_FLAGS(buttonclose, 
                                GTK_CAN_DEFAULT);
           gtk_box_pack_start(GTK_BOX(action_area),
  @@ -2205,11 +2163,7 @@
           x_fileselect_fill_lists(f_current);
         }
       } else {
  -#ifdef HAS_GTK12
  -      buttonclose = gtk_button_new_with_label (_("Close"));
  -#else
         buttonclose = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
         GTK_WIDGET_SET_FLAGS(buttonclose, GTK_CAN_DEFAULT);
         gtk_box_pack_start(GTK_BOX(action_area),
                            buttonclose, TRUE, TRUE, 0);
  
  
  
  1.24      +0 -8      eda/geda/gaf/gschem/src/x_image.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_image.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_image.c,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- x_image.c	15 Jul 2006 22:18:06 -0000	1.23
  +++ x_image.c	6 Aug 2006 16:45:29 -0000	1.24
  @@ -414,11 +414,7 @@
   
       gtk_window_set_title (GTK_WINDOW (w_current->iwindow), _("Write Image..."));
   
  -#ifdef HAS_GTK12
  -    buttonwrite = gtk_button_new_with_label (_("Write"));
  -#else
       buttonwrite = gtk_button_new_from_stock (GTK_STOCK_OK);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonwrite, GTK_CAN_DEFAULT);
       gtk_box_pack_start (GTK_BOX (action_area),
   			buttonwrite, TRUE, TRUE, 0);
  @@ -427,11 +423,7 @@
       gtk_widget_show (buttonwrite);
       gtk_widget_grab_default (buttonwrite);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Close"));
  -#else
       buttoncancel = gtk_button_new_from_stock (GTK_STOCK_CLOSE);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start (GTK_BOX (action_area),
   			buttoncancel, TRUE, TRUE, 0);
  
  
  
  1.38      +0 -31     eda/geda/gaf/gschem/src/x_menus.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_menus.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_menus.c,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -b -r1.37 -r1.38
  --- x_menus.c	27 Jul 2006 01:59:19 -0000	1.37
  +++ x_menus.c	6 Aug 2006 16:45:29 -0000	1.38
  @@ -106,13 +106,8 @@
     int i, j;
     int name_len, key_len, pad;
     int sum, diff, max_size, space_size;
  -#ifdef HAS_GTK22
     PangoLayout *layout;
     int name_width, keys_width;
  -#else
  -  GtkStyle *style;
  -  GdkFont *font=NULL;
  -#endif 
   
     menu_bar = gtk_menu_bar_new ();
     for (i = 0 ; i < s_menu_return_num(); i++) {
  @@ -129,20 +124,6 @@
       gtk_menu_append(GTK_MENU(menu), menu_item);
       gtk_widget_show(menu_item);
   
  -#ifdef HAS_GTK12
  -    /* get info for style/font */
  -    style = gtk_rc_get_style(w_current->main_window);
  -    if (style) {
  -       font = style->font;
  -    } else {
  -       font = GTK_WIDGET (w_current->main_window)->style->font;
  -    }
  -
  -    space_size = gdk_string_width(font, " ");
  -    max_size = gdk_string_width(font, "123456789012345678901234567890");
  -
  -#else
  -
       layout = gtk_widget_create_pango_layout(menu, " ");
       pango_layout_get_pixel_size(layout, &space_size, NULL);
       g_object_unref(layout);
  @@ -152,8 +133,6 @@
       pango_layout_get_pixel_size(layout, &max_size, NULL);
       g_object_unref(layout);
   
  -#endif
  -
       scm_items_len = (int) scm_ilength (scm_items);
       for (j = 0 ; j < scm_items_len; j++) {
   
  @@ -190,7 +169,6 @@
           name_len = strlen(menu_item_name);
           key_len = strlen(menu_item_keys);
   
  -#ifdef HAS_GTK22
           layout = gtk_widget_create_pango_layout(menu, menu_item_name);
           pango_layout_get_pixel_size(layout, &name_width, NULL);
           g_object_unref(layout);
  @@ -200,10 +178,6 @@
           g_object_unref(layout);
   
           sum = name_width + keys_width;
  -#else
  -        sum = gdk_string_width(font, menu_item_name) + 
  -              gdk_string_width(font, menu_item_keys);
  -#endif
   
   	diff = max_size - sum;
   	pad = diff/space_size;
  @@ -298,11 +272,6 @@
     */
     gtk_item_factory_create_items(item_factory, npopup_items, popup_items, w_current);
   
  -#ifdef HAS_GTK12
  -  /* Attach the new accelerator group to the window. */
  -  gtk_accel_group_attach (accel_group, GTK_OBJECT (w_current->main_window));
  -#endif
  -
     /* Finally, return the actual menu created by the item factory. */
     menu = (GtkWidget *) gtk_item_factory_get_widget(item_factory, "<popup>");
     return (menu);
  
  
  
  1.21      +0 -8      eda/geda/gaf/gschem/src/x_print.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_print.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_print.c,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- x_print.c	15 Jul 2006 18:51:41 -0000	1.20
  +++ x_print.c	6 Aug 2006 16:45:29 -0000	1.21
  @@ -355,11 +355,7 @@
       gtk_window_set_title(GTK_WINDOW(w_current->pwindow),
                            _("Print..."));
   
  -#ifdef HAS_GTK12    
  -    buttonprint = gtk_button_new_with_label (_("Print"));
  -#else
       buttonprint = gtk_button_new_from_stock (GTK_STOCK_PRINT);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttonprint, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX(action_area),
                          buttonprint, TRUE, TRUE, 0);
  @@ -368,11 +364,7 @@
       gtk_widget_show (buttonprint);
       gtk_widget_grab_default (buttonprint);
   
  -#ifdef HAS_GTK12
  -    buttoncancel = gtk_button_new_with_label (_("Cancel"));
  -#else
       buttoncancel = gtk_button_new_from_stock(GTK_STOCK_CANCEL);
  -#endif
       GTK_WIDGET_SET_FLAGS (buttoncancel, GTK_CAN_DEFAULT);
       gtk_box_pack_start(GTK_BOX(action_area),
                          buttoncancel, TRUE, TRUE, 0);
  
  
  
  1.34      +0 -16     eda/geda/gaf/gschem/src/x_window.c
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: x_window.c
  ===================================================================
  RCS file: /home/cvspsrv/cvsroot/eda/geda/gaf/gschem/src/x_window.c,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- x_window.c	6 Aug 2006 16:16:01 -0000	1.33
  +++ x_window.c	6 Aug 2006 16:45:29 -0000	1.34
  @@ -359,9 +359,7 @@
     struct event_reg_t main_window_events[] = {
       { "enter_notify_event",   G_CALLBACK(x_event_enter)           },
       { "key_press_event",      G_CALLBACK(x_event_key_press)       },
  -#ifdef HAS_GTK22
       { "scroll_event",         G_CALLBACK(x_event_scroll)          },
  -#endif
       { NULL,                   NULL                                } };
     struct event_reg_t *tmp;
   
  @@ -404,11 +402,7 @@
     pixmap = gdk_pixmap_create_from_xpm (window, &mask,
                                          background,
                                          filename);
  -#ifdef HAS_GTK22 
     wpixmap = gtk_image_new_from_pixmap (pixmap, mask);
  -#else
  -  wpixmap = gtk_pixmap_new (pixmap, mask);
  -#endif
   
     return wpixmap;
   }
  @@ -489,19 +483,9 @@
     }
    
     if (w_current->toolbars) {
  -#ifdef HAS_GTK22
   	toolbar = gtk_toolbar_new();
   	gtk_toolbar_set_orientation (GTK_TOOLBAR(toolbar), GTK_ORIENTATION_HORIZONTAL);
   	gtk_toolbar_set_style (GTK_TOOLBAR(toolbar), GTK_TOOLBAR_ICONS);
  -#else
  -  	toolbar = gtk_toolbar_new (GTK_ORIENTATION_HORIZONTAL, 
  -				   GTK_TOOLBAR_ICONS);
  -  	gtk_container_set_border_width (GTK_CONTAINER (toolbar), 5);
  -  	gtk_toolbar_set_space_size (GTK_TOOLBAR (toolbar), 5);
  -  	gtk_toolbar_set_button_relief (GTK_TOOLBAR (toolbar), GTK_RELIEF_NONE);
  -  	gtk_toolbar_set_space_style (GTK_TOOLBAR (toolbar), 
  -				     GTK_TOOLBAR_SPACE_LINE);
  -#endif
   
     	if (w_current->handleboxes) {
     		gtk_container_add (GTK_CONTAINER (handlebox), toolbar);
  
  
  


_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs