You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(23) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(5) |
Feb
(22) |
Mar
(3) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(3) |
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(5) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <ho...@us...> - 2004-02-04 01:51:31
|
Update of /cvsroot/ganc/web In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22311 Modified Files: download.php ganc.css index.php news.php right_frame.php screenshots.php Log Message: Updated news.php and added some nicer format to CSS Index: download.php =================================================================== RCS file: /cvsroot/ganc/web/download.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** download.php 17 Dec 2003 00:20:03 -0000 1.1 --- download.php 4 Feb 2004 01:49:14 -0000 1.2 *************** *** 9,15 **** <body> <!-- include some local_variables --> ! <?php include 'local_variables.php'; ! $download_class="active"; ! ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> --- 9,14 ---- <body> <!-- include some local_variables --> ! <?php include 'local_variables.php' ?> ! <?php $download_class="active" ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> Index: ganc.css =================================================================== RCS file: /cvsroot/ganc/web/ganc.css,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** ganc.css 23 Nov 2003 00:23:05 -0000 1.1.1.1 --- ganc.css 4 Feb 2004 01:49:14 -0000 1.2 *************** *** 40,64 **** ul.news { /* list-style: none;*/ ! padding-left: 10%; } ! /* list elements */ ul.news li { text-align: left; ! padding-left: 2%; ! padding-right: 2%; ! margin-left: -10%; ! margin-right: 0; margin-top: 2em; margin-bottom: 1em; background-color: #CCCCCC; list-style: none; } ! ul.news li span { ! right: 26%; ! width: auto; ! text-align: right; font-weight: bold; } --- 40,63 ---- ul.news { /* list-style: none;*/ ! padding-left: 5%; } ! /* news list elements */ ul.news li { text-align: left; ! padding-left: 5%; margin-top: 2em; margin-bottom: 1em; background-color: #CCCCCC; list-style: none; + font-size: x-small; } ! /* news list emphasis */ ! ul.news em { ! padding-left: 0%; ! font-style: normal; font-weight: bold; + font-size: medium; } Index: index.php =================================================================== RCS file: /cvsroot/ganc/web/index.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** index.php 17 Dec 2003 00:20:03 -0000 1.1 --- index.php 4 Feb 2004 01:49:14 -0000 1.2 *************** *** 9,15 **** <body> <!-- include some local_variables --> ! <?php include 'local_variables.php'; ! $home_class="active"; ! ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> --- 9,14 ---- <body> <!-- include some local_variables --> ! <?php include 'local_variables.php' ?> ! <?php $home_class="active" ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> Index: news.php =================================================================== RCS file: /cvsroot/ganc/web/news.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** news.php 17 Dec 2003 00:20:03 -0000 1.1 --- news.php 4 Feb 2004 01:49:14 -0000 1.2 *************** *** 18,31 **** <h2>News</h2> <hr /> - <p class="date">Last stable version of ganc is <?php echo "$current_version" ?></p> <ul class="news"> ! <li>13th Dec 2003<span>ganc-0.7 released</span></li> ! A new hot right out of the oven release is out. Check it out in the download page. ! <li>21st Nov 2003<span>ganc's web page got updated</span></li> ganc's web page got a major makeover ! <li>19th Nov 2003<span>ganc goes on CVS</span></li> ganc's source code is in CVS!<br /> You can get it at SourceForge.net </ul> </div> --- 18,42 ---- <h2>News</h2> <hr /> <ul class="news"> ! <li>3rd Feb 2004 <br /> ! <em>ganc-0.8 released</em> ! Brand new ganc release. <br /> ! With this version ganc becomes pure gtk2. <br /> ! It doesn't use readline and libzvt2 anymore so it should be a lot easier to install for a lot of people. And it looks way nicer thanks to the wonderful gtk2 widget GtkTextView. ! ! <li>13th Dec 2003 <br /> ! <em>ganc-0.7 released</em></li> ! A new hot release right out of the oven. Check it out in the download page. ! ! <li>21st Nov 2003<br /> ! <em>ganc's web page got updated</em></li> ganc's web page got a major makeover ! ! <li>19th Nov 2003<br /> ! <em>ganc goes on CVS</em></li> ganc's source code is in CVS!<br /> You can get it at SourceForge.net + </ul> </div> Index: right_frame.php =================================================================== RCS file: /cvsroot/ganc/web/right_frame.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** right_frame.php 17 Dec 2003 00:20:03 -0000 1.1 --- right_frame.php 4 Feb 2004 01:49:14 -0000 1.2 *************** *** 6,10 **** [<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small> </p> ! <p class="<?php echo "$home_class" ?>"><a href="index.php">Home</a></p> <p class="<?php echo "$news_class" ?>"><a href="news.php">News</a></p> <p class="<?php echo "$screenshots_class" ?>"><a href="screenshots.php">Screenshots</a></p> --- 6,10 ---- [<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small> </p> ! <p class="<?php echo "$home_class" ?>"><a href="http://ganc.sourceforge.net">Home</a></p> <p class="<?php echo "$news_class" ?>"><a href="news.php">News</a></p> <p class="<?php echo "$screenshots_class" ?>"><a href="screenshots.php">Screenshots</a></p> Index: screenshots.php =================================================================== RCS file: /cvsroot/ganc/web/screenshots.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** screenshots.php 17 Dec 2003 00:20:03 -0000 1.1 --- screenshots.php 4 Feb 2004 01:49:14 -0000 1.2 *************** *** 9,15 **** <body> <!-- include some local_variables --> ! <?php include 'local_variables.php'; ! $screenshots_class="active"; ! ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> --- 9,14 ---- <body> <!-- include some local_variables --> ! <?php include 'local_variables.php' ?> ! <?php $screenshots_class="active" ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> |
|
From: <ho...@us...> - 2004-02-04 01:08:55
|
Update of /cvsroot/ganc/ganc/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14156/src Modified Files: parser_stuff.c syntax.y variables.c Log Message: Fixed 2 bugs: setting 'obase' was setting 'ibase' instead. If error when setting system variable its value would be corrupted in following expresion. Index: parser_stuff.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/parser_stuff.c,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** parser_stuff.c 4 Feb 2004 00:32:10 -0000 1.14 --- parser_stuff.c 4 Feb 2004 01:06:38 -0000 1.15 *************** *** 343,349 **** // update the value of variable 'ans' UpdateAnswerVariable (); - // update system variables in case they've been changed by user - UpdateSystemVariables (); } return error; } --- 343,350 ---- // update the value of variable 'ans' UpdateAnswerVariable (); } + // update system variables in case they've been changed by user + UpdateSystemVariables (); + return error; } Index: syntax.y =================================================================== RCS file: /cvsroot/ganc/ganc/src/syntax.y,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** syntax.y 20 Jan 2004 01:33:40 -0000 1.6 --- syntax.y 4 Feb 2004 01:06:38 -0000 1.7 *************** *** 87,91 **** format_token: '_' exp { SetResultOutputFormat (OUTPUT_FORMAT_BASE, $2); } ! | '#' { SetResultOutputFormat (OUTPUT_FORMAT_PRINTBASE, 1); } ; --- 87,91 ---- format_token: '_' exp { SetResultOutputFormat (OUTPUT_FORMAT_BASE, $2); } ! | '_' { SetResultOutputFormat (OUTPUT_FORMAT_PRINTBASE, 1); } ; Index: variables.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/variables.c,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** variables.c 20 Jan 2004 01:33:40 -0000 1.1 --- variables.c 4 Feb 2004 01:06:38 -0000 1.2 *************** *** 287,291 **** system_vars.ibase= (int) v->value; v= FindVariable ("obase"); ! system_vars.ibase= (int) v->value; } --- 287,291 ---- system_vars.ibase= (int) v->value; v= FindVariable ("obase"); ! system_vars.obase= (int) v->value; } |
|
From: <ho...@us...> - 2004-02-04 00:34:28
|
Update of /cvsroot/ganc/ganc/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6513/src Modified Files: callbacks.c parser_stuff.c Log Message: Fixed 2 minor bugs: pressing 'x' in keypad printed an 'x' as opposed to a '*'. Capital 'E' didn't work for exponent as in '1E3'. Removed debug output that forgot to take out Index: callbacks.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/callbacks.c,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** callbacks.c 3 Feb 2004 21:28:01 -0000 1.11 --- callbacks.c 4 Feb 2004 00:32:10 -0000 1.12 *************** *** 68,72 **** // convert text taken from labels into correct output ! if (!found && strcmp (text, "EE")==0 && ++found) strcpy (text, "E"); if (!found && strcmp (text, "1/x")==0 && ++found) strcpy (text, "^-1"); // add space to these ones --- 68,72 ---- // convert text taken from labels into correct output ! if (!found && strcmp (text, "EE")==0 && ++found) strcpy (text, "e"); if (!found && strcmp (text, "1/x")==0 && ++found) strcpy (text, "^-1"); // add space to these ones *************** *** 93,96 **** --- 93,97 ---- if (!found && strcmp (text, "x^y")==0 && ++found) strcpy (text, "^"); if (!found && strcmp (text, "x!")==0 && ++found) strcpy (text, "!"); + if (!found && strcmp (text, "x")==0 && ++found) strcpy (text, "*"); InsertText (text); *************** *** 110,119 **** void on_button_exe_clicked (GtkWidget *button, gpointer user_data) { - int ww, wh; - ExpressionReady (); - - gtk_window_get_size (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (button))), &ww, &wh); - printf ("%d, %d\n", ww, wh); } --- 111,115 ---- Index: parser_stuff.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/parser_stuff.c,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** parser_stuff.c 20 Jan 2004 01:33:40 -0000 1.13 --- parser_stuff.c 4 Feb 2004 00:32:10 -0000 1.14 *************** *** 164,168 **** if (epos>pos) { // check if we have an exponent coming up (only for base 10) ! if (input[epos - 1]=='e' && GetSystemVariable (SYSTEMVAR_IBASE)==10 && (input[epos]=='+' || input[epos]=='-')) { ++epos; --- 164,169 ---- if (epos>pos) { // check if we have an exponent coming up (only for base 10) ! if ((input[epos - 1]=='e' || input[epos - 1]=='E') && ! GetSystemVariable (SYSTEMVAR_IBASE)==10 && (input[epos]=='+' || input[epos]=='-')) { ++epos; |
|
From: <ho...@us...> - 2004-02-03 23:27:10
|
Update of /cvsroot/ganc/ganc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24586 Modified Files: Makefile.am Log Message: Took out 'ganc.glade2' from distribution. It stays (by now) in cvs but most probably we don't need it anymore Index: Makefile.am =================================================================== RCS file: /cvsroot/ganc/ganc/Makefile.am,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** Makefile.am 20 Nov 2003 03:31:39 -0000 1.1.1.1 --- Makefile.am 3 Feb 2004 23:24:53 -0000 1.2 *************** *** 3,5 **** SUBDIRS = src ! EXTRA_DIST = ganc.glade2 --- 3,5 ---- SUBDIRS = src ! #EXTRA_DIST = ganc.glade2 |
|
From: <ho...@us...> - 2004-02-03 21:57:37
|
Update of /cvsroot/ganc/ganc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5864 Removed Files: ChangeLog Log Message: Removed ChangeLog from repository. It'll be automatically generated with 'cvs2cl.pl' for each release --- ChangeLog DELETED --- |
|
From: <ho...@us...> - 2004-02-03 21:30:20
|
Update of /cvsroot/ganc/ganc/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14434/src Modified Files: callbacks.c display.c interface.c main.c Log Message: Fixed initial size and resizing problems with gtk2 Index: callbacks.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/callbacks.c,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** callbacks.c 20 Jan 2004 01:33:40 -0000 1.10 --- callbacks.c 3 Feb 2004 21:28:01 -0000 1.11 *************** *** 110,114 **** --- 110,119 ---- void on_button_exe_clicked (GtkWidget *button, gpointer user_data) { + int ww, wh; + ExpressionReady (); + + gtk_window_get_size (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (button))), &ww, &wh); + printf ("%d, %d\n", ww, wh); } Index: display.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/display.c,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** display.c 20 Jan 2004 01:33:40 -0000 1.1 --- display.c 3 Feb 2004 21:28:01 -0000 1.2 *************** *** 10,17 **** #include <gtk/gtk.h> #include <gdk/gdkkeysyms.h> #include "include/defines.h" #include "include/functions.h" ! --- 10,19 ---- #include <gtk/gtk.h> #include <gdk/gdkkeysyms.h> + #include <gconf/gconf-client.h> + #include <pango/pango.h> #include "include/defines.h" #include "include/functions.h" ! #include "support.h" *************** *** 317,320 **** --- 319,327 ---- for (i= 0; i<num_sublines; ++i) { line[sublines[i]]= '\0'; + // ignore empty sublines + if (LineIsEmpty (line + start)) { + start= sublines[i] + 1; + continue; + } error= ParseTypedExpression (line + start); *************** *** 328,332 **** size+= strlen (parse_errors[perror - 1]); output_text= (char *) malloc (size); ! sprintf (output_text, "error: %s\n", parse_errors[perror - 1]); } else { size= 30; --- 335,340 ---- size+= strlen (parse_errors[perror - 1]); output_text= (char *) malloc (size); ! //sprintf (output_text, "error: %s\n", parse_errors[perror - 1]); ! sprintf (output_text, "%s\n", parse_errors[perror - 1]); } else { size= 30; *************** *** 334,339 **** size+= strlen (extra); output_text= (char *) malloc (size); ! sprintf (output_text, "error: %s: %s\n", ! parse_errors[perror - 1], extra); free (extra); } --- 342,347 ---- size+= strlen (extra); output_text= (char *) malloc (size); ! //sprintf (output_text, "error: %s: %s\n", parse_errors[perror - 1], extra); ! sprintf (output_text, "%s: %s\n", parse_errors[perror - 1], extra); free (extra); } *************** *** 375,378 **** --- 383,458 ---- + // + // sets geometry hints for display (minimum size, size increment) + // + void SetDisplayGeometryHints (GtkWindow *window) + { + GdkGeometry hints; + PangoLayout *playout; + PangoContext *pcontext; + int width, height; + int ww, wh; + + // pcontext belongs to widget, so we don't free it + pcontext= gtk_widget_get_pango_context (GTK_WIDGET (display)); + playout= pango_layout_new (pcontext); + pango_layout_set_text(playout, "X", 1); + pango_layout_get_pixel_size(playout, &width, &height); + g_object_unref (G_OBJECT (playout)); // free created playout + + // geometry hints + hints.base_width= 0; + hints.base_height= 0; + hints.width_inc= width; // x increment size + hints.height_inc= height; // y increment size + hints.min_width= 20*hints.width_inc; // min x size + hints.min_height= 4*hints.height_inc; // min y size + gtk_window_set_geometry_hints(window, GTK_WIDGET(display), &hints, + GDK_HINT_RESIZE_INC|GDK_HINT_MIN_SIZE| + GDK_HINT_BASE_SIZE);//|GDK_HINT_USER_SIZE); + + // copied from gnome-terminal source (terminal-window.c) + GtkRequisition toplevel_request; + GtkRequisition widget_request; + int w, h, xpad, ypad; + int grid_width, grid_height; + + gtk_widget_set_size_request (GTK_WIDGET (display), 2000, 2000); + gtk_widget_size_request (window, &toplevel_request); + gtk_widget_size_request (GTK_WIDGET (display), &widget_request); + + w= toplevel_request.width - widget_request.width; + h= toplevel_request.height - widget_request.height; + + grid_width= 30; + grid_height= 10; + + xpad= 0; + ypad= 0; + + w+= xpad + width * grid_width; + h+= ypad + height * grid_height; + + //gtk_window_resize (window, w, h); + gtk_window_set_default_size (window, w, h); + } + + + // + // get monospace font (terminal font) from gnome preferences (gconf) + // set font for display + // + void SetDisplayDefaultFont (void) + { + PangoFontDescription *monospace_font_desc; + GConfClient *conf_client; + + conf_client= gconf_client_get_default (); + monospace_font_desc= pango_font_description_from_string (gconf_client_get_string (conf_client, "/desktop/gnome/interface/monospace_font_name", NULL)); + gtk_widget_modify_font (display, monospace_font_desc); + pango_font_description_free (monospace_font_desc); + g_object_unref (G_OBJECT (conf_client)); // free conf_client + } + /* Index: interface.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/interface.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** interface.c 20 Jan 2004 01:33:40 -0000 1.4 --- interface.c 3 Feb 2004 21:28:01 -0000 1.5 *************** *** 149,153 **** display = gtk_text_view_new (); ! gtk_widget_set_size_request (display, 250, 200); gtk_widget_show (display); gtk_container_add (GTK_CONTAINER (scrolledwindow1), display); --- 149,156 ---- display = gtk_text_view_new (); ! // don't quite understand how this size_request work ! // it seems to work fine as long as xsize and ysize are bigger than the ! // minimum size specified later with geometry hints ! //gtk_widget_set_size_request (display, -1, -1); gtk_widget_show (display); gtk_container_add (GTK_CONTAINER (scrolledwindow1), display); *************** *** 187,192 **** table1 = gtk_table_new (6, 7, TRUE); gtk_widget_show (table1); gtk_box_pack_start (GTK_BOX (vbox2), table1, FALSE, TRUE, 0); - button1 = make_empty_space (table1, 2, 3, 0, 1); button2 = make_empty_space (table1, 3, 4, 0, 1); --- 190,195 ---- table1 = gtk_table_new (6, 7, TRUE); gtk_widget_show (table1); + gtk_box_pack_start (GTK_BOX (vbox2), table1, FALSE, TRUE, 0); button1 = make_empty_space (table1, 2, 3, 0, 1); button2 = make_empty_space (table1, 3, 4, 0, 1); Index: main.c =================================================================== RCS file: /cvsroot/ganc/ganc/src/main.c,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** main.c 20 Jan 2004 01:33:40 -0000 1.9 --- main.c 3 Feb 2004 21:28:01 -0000 1.10 *************** *** 10,15 **** #ifdef BUILD_GUI #include <gtk/gtk.h> - #include <gconf/gconf-client.h> - #include <pango/pango-font.h> #include "callbacks.h" #include "support.h" --- 10,13 ---- *************** *** 96,101 **** // create interface window= create_window1 (); ! //TerminalSetGeometry (window); ! gtk_widget_show (window); // show main window // extract widgets --- 94,98 ---- // create interface window= create_window1 (); ! // extract widgets *************** *** 109,122 **** // get font from gnome preferences and set it ! { ! PangoFontDescription *monospace_font_desc; ! GConfClient *conf_client; - conf_client= gconf_client_get_default (); - monospace_font_desc= pango_font_description_from_string (gconf_client_get_string (conf_client, "/desktop/gnome/interface/monospace_font_name", NULL)); - gtk_widget_modify_font (display, monospace_font_desc); - pango_font_description_free (monospace_font_desc); - g_object_unref (G_OBJECT (conf_client)); - } display_text_buffer= gtk_text_view_get_buffer (GTK_TEXT_VIEW (display)); --- 106,116 ---- // get font from gnome preferences and set it ! SetDisplayDefaultFont(); ! ! // set geometry hints (min size, increment size) ! SetDisplayGeometryHints (GTK_WINDOW (window)); ! ! gtk_widget_show (window); // show main window display_text_buffer= gtk_text_view_get_buffer (GTK_TEXT_VIEW (display)); |
|
From: <ho...@us...> - 2004-02-03 21:30:19
|
Update of /cvsroot/ganc/ganc/src/include In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14434/src/include Modified Files: functions.h Log Message: Fixed initial size and resizing problems with gtk2 Index: functions.h =================================================================== RCS file: /cvsroot/ganc/ganc/src/include/functions.h,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** functions.h 20 Jan 2004 01:33:40 -0000 1.9 --- functions.h 3 Feb 2004 21:28:01 -0000 1.10 *************** *** 46,49 **** --- 46,51 ---- void ClearInputLine (void); void ExpressionReady (void); + void SetDisplayGeometryHints (GtkWindow *window); + void SetDisplayDefaultFont (void); // history.c |
|
From: <ho...@us...> - 2004-02-03 21:30:18
|
Update of /cvsroot/ganc/ganc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14434 Modified Files: configure.in Log Message: Fixed initial size and resizing problems with gtk2 Index: configure.in =================================================================== RCS file: /cvsroot/ganc/ganc/configure.in,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** configure.in 20 Jan 2004 01:33:40 -0000 1.17 --- configure.in 3 Feb 2004 21:28:01 -0000 1.18 *************** *** 29,34 **** CFLAGS="-Wall $CFLAGS" ! dnl When working with CVS version make all warnings errors and enable debug ! test "$VERSION" == "cvs" && CFLAGS="-Werror -g $CFLAGS" && COMPILE_DEBUG="yes" dnl bison stuff --- 29,34 ---- CFLAGS="-Wall $CFLAGS" ! dnl When working with CVS version enable debug ##and make all warnings errors ! test "$VERSION" == "cvs" && CFLAGS="-g $CFLAGS" && COMPILE_DEBUG="yes" dnl bison stuff |
|
From: <ho...@us...> - 2004-01-20 01:33:44
|
Update of /cvsroot/ganc/ganc/src
In directory sc8-pr-cvs1:/tmp/cvs-serv28642/src
Modified Files:
Makefile.am callbacks.c callbacks.h evaluate.c interface.c
main.c parser_stuff.c syntax.y
Added Files:
display.c history.c variables.c
Removed Files:
reader_communication.c reader_stuff.c terminal_stuff.c
Log Message:
Changed maaaaaaaaaaany things:
- Eliminated dependency on libzvt and readline, now the whole thing is
pure gtk (using GtkTextView for the display) and it looks nice
- Thus, now there's no 'forking' around and no pipes
- Major rearrangement of files (yes again!)
Added: display.c history.c variables.c defines.h parser.h
Removed: reader_communication.c reader_stuff.c terminal_stuff.c
evaluate_stuff.h mytypes.h pipe_stuff.h
- Now, and so far, is not possible to compile text only version
--- NEW FILE: display.c ---
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include "include/defines.h"
#include "include/functions.h"
/***********************************************************************
*
* External Variables
*
***********************************************************************/
extern GtkTextBuffer *display_text_buffer;
extern GtkWidget *display;
/***********************************************************************
*
* Global Variables
*
***********************************************************************/
GtkTextMark *start_mark;
GtkTextMark *end_mark;
GtkTextMark *insert_mark;
GtkTextMark *selection_mark;
GtkTextMark *cursor_mark;
/***********************************************************************
*
* Local Variables
*
***********************************************************************/
#define MAX_NUMBER_LINES 100
/***********************************************************************
*
* Local Variables
*
***********************************************************************/
static const char prompt[]="> ";
static char *parse_errors[]={ // Texts of parse errors
"unknown variable", // 1
"syntax error",
"parse error",
"isolated decimal dot",
"", // 5
"base out of range",
"base conversion error",
"invalid argument to LN",
"invalid argument to LOG",
"invalid argument to factorial", // 10
"invalid argument to SQRT",
"invalid argument to ASIN",
"invalid argument to ACOS",
"division by zero",
"overflow", // 15
"NaN",
"assignment of constant",
"illegal identifier",
"illegal constant"
};
/***********************************************************************
*
* Local Functions
*
***********************************************************************/
static void LimitNumberEntries (void);
static char *PreparePrintedResult (void);
static int *ExtractSublines (char *line, int *num_sublines);
static int LineIsEmpty (char *line);
//
// prints prompt in display
//
void PrintPrompt (GtkTextIter *point_iter)
{
gtk_text_buffer_insert (display_text_buffer, point_iter, prompt, -1);
}
//
//
//
void TravelEntryHistory (guint keyval)
{
char *line, *line2=NULL;
GtkTextIter start_iter, end_iter;
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &end_iter, end_mark);
line= gtk_text_buffer_get_text (display_text_buffer, &start_iter, &end_iter, FALSE);
if (keyval==GDK_Up) {
line2= PreviousHistory (line);
} else if (keyval==GDK_Down) {
line2= NextHistory (line);
} else if (keyval==GDK_Page_Up) {
line2= PreviousHistory (line);
} else if (keyval==GDK_Page_Down) {
line2= NextHistory (line);
}
free (line);
if (line2!=NULL) {
gtk_text_buffer_delete (display_text_buffer, &start_iter, &end_iter);
gtk_text_buffer_insert (display_text_buffer, &start_iter, line2, -1);
gtk_text_buffer_place_cursor (display_text_buffer, &start_iter);
}
}
//
// Inserts text in display at cursor's position
// checks insert point is not in forbidden zone
//
void InsertText (char *text)
{
GtkTextIter start_iter, sel_iter, insert_iter;
gtk_text_buffer_get_selection_bounds (display_text_buffer, &sel_iter, &insert_iter);
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
if (gtk_text_iter_compare (&sel_iter, &start_iter)<0 ||
gtk_text_iter_compare (&insert_iter, &start_iter)<0) {
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &insert_iter, end_mark);
gtk_text_buffer_place_cursor (display_text_buffer, &insert_iter);
}
gtk_text_buffer_insert_at_cursor (display_text_buffer, text, -1);
}
//
// deletes the input line
//
void ClearInputLine (void)
{
GtkTextIter start_iter, end_iter;
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &end_iter, end_mark);
gtk_text_buffer_delete (display_text_buffer, &start_iter, &end_iter);
gtk_text_buffer_place_cursor (display_text_buffer, &start_iter);
}
//
//
//
static void LimitNumberEntries (void)
{
int lines;
GtkTextIter iter, start_iter;
GtkTextTag *result_tag;
lines= gtk_text_buffer_get_line_count (display_text_buffer);
if (lines>MAX_NUMBER_LINES) {
gtk_text_buffer_get_iter_at_offset (display_text_buffer, &start_iter, 0);
gtk_text_buffer_get_iter_at_offset (display_text_buffer, &iter, 0);
result_tag= gtk_text_tag_table_lookup (gtk_text_buffer_get_tag_table (display_text_buffer), "result");
gtk_text_iter_forward_to_tag_toggle (&iter, result_tag); // start result
gtk_text_iter_forward_to_tag_toggle (&iter, result_tag); // end result
gtk_text_buffer_delete (display_text_buffer, &start_iter, &iter);
}
}
//
// prepare text that will be outputed as output
//
static char *PreparePrintedResult (void)
{
unsigned long result;
int digits, i, d, aux;
unsigned int base;
char *output_text;
int printbase, extra_size=0;
base= GetResultOutputFormat (OUTPUT_FORMAT_BASE);
printbase= GetResultOutputFormat (OUTPUT_FORMAT_PRINTBASE);
if (printbase) extra_size= 3;
if (base==10) { // base 10 -> EASY
output_text= (char *) malloc (50 + extra_size);
sprintf (output_text, "%15.10Lg\n", ResultValue ());
} else { // other base
result= ResultValue ();
// calculate number of digits number 'result' takes in base 'base'
digits= (int) (log (result)/log (base) + 1);
// malloc: 2 for '\n\0' and 2 for safety margin
output_text= (char *) malloc (digits + 2 + 2 + extra_size);
i= 0;
while (result >= base) {
d= result % base;
if (d<10) output_text[i++]= d + '0';
else output_text[i++]= (d - 10) + 'a';
result/= base;
}
if (result<10) output_text[i]= result + '0';
else output_text[i]= (result - 10) + 'a';
output_text[i + 1]= '\n';
output_text[i + 2]= '\0';
d= 0;
while (d<i) {
aux= output_text[i];
output_text[i]= output_text[d];
output_text[d]= aux;
--i;
d++;
}
}
if (printbase) {
i= strlen (output_text) - 1;
if (base<10) sprintf (output_text + i, "_%1d\n", base);
else sprintf (output_text + i, "_%2d\n", base);
}
return output_text;
}
//
// Extracts position of sublines (indicated by ';' character)
// Returns array with positions of ';' characters, i.e. ends of sublines
// and number of sublines found (minimum 1) in 'num_sublines'
// array contains at least one element, i.e. end of line
// Returned array needs to be freed later
//
static int *ExtractSublines (char *line, int *num_sublines)
{
int *sublines;
int count, i, j, size;
// store size of line
size= strlen (line);
// find sub-lines embeded in input
// run through the input to find ';' characters, store positions in 'sublines'
for (i= 0, count= 0; i<size; ++i) if (line[i]==';') ++count;
++count; // at least 1: case of no sub-lines
sublines= malloc (count*sizeof (int));
// If some sub-lines are found, store their positions
if (count>1) { // there were some ';'
for (i= 0, j= 0; i<size; ++i)
if (line[i]==';') {
sublines[j]= i;
++j;
}
}
// consider end of input as the end of another sub-line
// it makes the case with no sub-lines work
sublines[count - 1]= size;
*num_sublines= count;
return sublines;
}
//
// returns 1 if line is empty (0 or more spaces); returns 0 otherwise
//
static int LineIsEmpty (char *line)
{
int i;
i= strlen (line) - 1;
while (i>=0 && line[i]==' ') --i;
if (i>=0) return 0;
return 1;
}
//
// called when expression is ready to be evaluated (RETURN pressed)
//
void ExpressionReady (void)
{
GtkTextIter point_iter, start_iter;
gchar *line, *extra;
int error;
int num_sublines, start, i;
int *sublines = NULL;
char *output_text;
int perror, size;
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
gtk_text_buffer_get_iter_at_mark (display_text_buffer, &point_iter, end_mark);
line= gtk_text_buffer_get_text (display_text_buffer, &start_iter, &point_iter, FALSE);
// check line is not empty
if (LineIsEmpty (line)) return;
// add current line to history
AddHistory (line);
gtk_text_buffer_insert (display_text_buffer, &point_iter, "\n", -1);
// extract sub-lines from input
sublines= ExtractSublines (line, &num_sublines);
start= 0; // stores starting position of sub-line
for (i= 0; i<num_sublines; ++i) {
line[sublines[i]]= '\0';
error= ParseTypedExpression (line + start);
if (error) {
// see if there's any extra text to add to error output
perror= ParseError ();
extra= ParseErrorExtra ();
if (extra==NULL) {
size= 20;
size+= strlen (parse_errors[perror - 1]);
output_text= (char *) malloc (size);
sprintf (output_text, "error: %s\n", parse_errors[perror - 1]);
} else {
size= 30;
size+= strlen (parse_errors[perror - 1]);
size+= strlen (extra);
output_text= (char *) malloc (size);
sprintf (output_text, "error: %s: %s\n",
parse_errors[perror - 1], extra);
free (extra);
}
gtk_text_buffer_insert_with_tags_by_name
(display_text_buffer, &point_iter, output_text, -1, "result", "error", NULL);
} else { // No error, print result
output_text= PreparePrintedResult ();
gtk_text_buffer_insert_with_tags_by_name
(display_text_buffer, &point_iter, output_text, -1, "result", NULL);
}
// print output_text (it should already end in '\n') using tag 'result'
// free memory of output text
free (output_text);
// set start of next subline
start= sublines[i] + 1;
}
// free memory
free (sublines);
g_free (line);
PrintPrompt (&point_iter);
// set 'start' and 'end' marks and position cursor
gtk_text_buffer_move_mark (display_text_buffer, start_mark, &point_iter);
gtk_text_buffer_move_mark (display_text_buffer, end_mark, &point_iter);
gtk_text_buffer_place_cursor (display_text_buffer, &point_iter);
// scroll display to show cursor (if necessary)
gtk_text_view_scroll_to_mark (GTK_TEXT_VIEW (display), insert_mark,
0., FALSE, 0., 0.);
// make sure number of entries in display doesn't exceed a maximum
LimitNumberEntries ();
}
/*
Local Variables:
c-file-style: "gnu"
c-file-offsets: ((case-label . +))
End:
*/
--- NEW FILE: history.c ---
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <stdlib.h>
#include <string.h>
/***********************************************************************
*
* Local Types
*
***********************************************************************/
struct history_struct {
char *line; // contains name of variable
struct history_struct *ant; // previous member in list
struct history_struct *sig;
};
typedef struct history_struct history_type;
/***********************************************************************
*
* Local Variables
*
***********************************************************************/
static history_type *history_current; // current displayed entry
static history_type *history_first; // first entry in history
static history_type *history_last; // tail of history
static int history_size;
static int history_size_max=100;
//
// initialize history
//
void InitializeHistory (void)
{
history_type *h;
h= (history_type *) malloc (sizeof (history_type));
h->line= strdup ("");
h->ant= NULL;
h->sig= NULL;
history_current= history_last= history_first= h;
history_size= 1;
}
//
// add another entry (line) to the history
//
void AddHistory (char *text)
{
history_type *h;
// if text already in last entry is diff than given text make a new copy
if (strcmp (history_last->line, text)!=0) {
free (history_last->line);
history_last->line= strdup (text);
}
// if entering item is equal to previous in history, ignore this entry
if (history_last->ant!=NULL && strcmp (history_last->ant->line, text)==0) {
free (history_last->line);
history_last->line= strdup ("");
history_current= history_last;
return;
}
// create new entry
h= (history_type *) malloc (sizeof (history_type));
h->line= strdup ("");
h->ant= history_last;
h->sig= NULL;
history_last->sig= h;
// update control variables
history_current= history_last= h;
// if history is at maximum size, eliminate first element
if (history_size==history_size_max) {
h= history_first->sig;
h->ant= NULL;
free (history_first->line);
free (history_first);
history_first= h;
} else ++history_size;
}
//
// goes to previous item in history (if any)
// given text is stored if is not the same as it was before
// returns a pointer to the text of previous item in history (don't free!!)
//
char *PreviousHistory (char *text)
{
// if we're at the first entry, return NULL
if (history_current->ant==NULL) return NULL;
// if given text is diff than text in current entry, copy new
if (strcmp (history_current->line, text)!=0) {
free (history_current->line);
history_current->line= strdup (text);
}
history_current= history_current->ant;
return history_current->line;
}
//
// goes to next item in history (if any)
// given text is stored if is not the same as it was before
// returns a pointer to the text of next item in history (don't free!!)
//
char *NextHistory (char *text)
{
// if we're at the last entry, return NULL
if (history_current->sig==NULL) return NULL;
// if given text is diff than text in current entry, copy new
if (strcmp (history_current->line, text)!=0) {
free (history_current->line);
history_current->line= strdup (text);
}
history_current= history_current->sig;
return history_current->line;
}
//
// removes history from memory (frees the memory)
//
void RemoveHistory (void)
{
history_type *h;
h= history_first;
while (h!=NULL) {
history_first= h->sig;
free (h->line);
free (h);
h= history_first;
}
}
/*
Local Variables:
c-file-style: "gnu"
c-file-offsets: ((case-label . +))
End:
*/
--- NEW FILE: variables.c ---
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include "include/defines.h"
#include "include/functions.h"
/***********************************************************************
*
* Local Types
*
***********************************************************************/
// Name list used to keep the list of defined variables (typedef in mytypes.h)
struct var_list_struct {
char *name; // contains name of variable
short attr; // attributes of variable
VALUE_TYPE value; // value of variable
struct var_list_struct *ant; // previous member in list
};
typedef struct var_list_struct var_list;
/***********************************************************************
*
* Local Functions
*
***********************************************************************/
static int ValidVariableName (char *name);
static var_list *FindVariable (char *name);
static void DestroyVariableList (var_list *ini);
static void CreateNewVariable (char *new_name, VALUE_TYPE value, short attributes);
/***********************************************************************
*
* Local Variables
*
***********************************************************************/
static var_list *var_list_ini; // Initial node of variable list
static var_list *copy_var_list_ini;
// system variables
static struct {
int ibase;
int obase;
} system_vars;
//
// Checks whether 'name' is a valid variable identifier
// Returns: 1 if name is ok, 0 if name can't be a variable
//
static int ValidVariableName (char *name)
{
int i=1;
int ok=0;
if (isalpha (name[0]) || name[0]=='_') {
while (isalpha (name[i]) || isdigit (name[i]) || name[i]=='_') ++i;
if (name[i]=='\0') ok= 1;
}
return ok;
}
// Looks for a variable name in the variable list
// If variable found returns the address of its entry in var_list
// If not found returns NULL
static var_list *FindVariable (char *name)
{
var_list *v;
int found=0;
v= var_list_ini;
while (v!=NULL && !found) {
if (strcmp (v->name, name)==0) found= 1;
else v= v->ant;
}
if (!found) return NULL;
return v;
}
//
// Destroys the given variable list (the initial node is given)
//
static void DestroyVariableList (var_list *ini)
{
var_list *v;
while (ini!=NULL) {
free (ini->name);
v= ini->ant;
free (ini);
ini= v;
}
}
// Creates a new variable and adds it to the list
// It doesn't check if the variable exists, it's the programmer responsibility
// not to duplicate variables
static void CreateNewVariable (char *new_name, VALUE_TYPE value, short attributes)
{
var_list *v;
if (ValidVariableName (new_name)) { // new_name is a valid var identifier
v= malloc (sizeof (var_list));
v->name= strdup (new_name);
v->attr= attributes;
v->value= value;
v->ant= var_list_ini;
var_list_ini= v;
} else { // new_name is not a valid var identifier -> ERROR
NotifyError (PERROR_ILLEGAL_IDENTIFIER, new_name);
}
}
//
// Initialize variable list by setting top item of list to NULL
//
void InitMainVarList (void)
{
// variable list is empty to start with
var_list_ini= NULL;
// Add default variables to variable list
CreateNewVariable ("pi", CONSTANT_PI, VAR_ATTR_READONLY);
CreateNewVariable ("PI", CONSTANT_PI, VAR_ATTR_READONLY);
CreateNewVariable ("ans", (VALUE_TYPE) 0., VAR_ATTR_READONLY); // ans (previous answer)
CreateNewVariable ("ibase", (VALUE_TYPE) 10., VAR_ATTR_SYSTEM); // ibase (input base)
CreateNewVariable ("obase", (VALUE_TYPE) 10., VAR_ATTR_SYSTEM); // obase (output base)
}
//
// Destroy variable list (called at program exit to clean up)
//
void DestroyMainVarList (void)
{
DestroyVariableList (var_list_ini);
}
//
// Evaluates a variable and returns its value, if not defined call error
//
VALUE_TYPE EvaluateVariable (char *name)
{
var_list *v;
VALUE_TYPE value;
v= FindVariable (name);
if (v==NULL) { // New variable, ERROR
NotifyError (PERROR_UNKNOWN_VAR, name); // indicate error hapenned
value= 0.;
} else { // existing variable, return its value
value= v->value;
CheckNumber (value); // check value is well behavied
}
return value;
}
// Assigns a value to a variable, if it's a new variable creates it and
// adds it to the list
// Returns the newly updated value of the variable
VALUE_TYPE AssignVariable (char *name, VALUE_TYPE value)
{
var_list *v;
v= FindVariable (name);
if (v==NULL) { // new variable, create new one
CreateNewVariable (name, value, VAR_ATTR_NORMAL);
} else { // old variable, just assign new value
if (v->attr&VAR_ATTR_READONLY) { // readonly variable
NotifyError (PERROR_ASSIGNMENT_CONSTANT, NULL);
value= (VALUE_TYPE) 0.;
return value;
}
if (v->attr&VAR_ATTR_SYSTEM) { // system variable
if (strcmp (v->name, "ibase")==0) SetSystemVariable (SYSTEMVAR_IBASE, (int) value);
if (strcmp (v->name, "obase")==0) SetSystemVariable (SYSTEMVAR_OBASE, (int) value);
}
v->value= value;
}
return value;
}
//
// Makes a copy of current variable list
//
void MakeCopyVariableList (void)
{
var_list *copy;
var_list *v;
copy_var_list_ini= NULL;
v= var_list_ini;
while (v!=NULL) {
// make copy of v
copy= malloc (sizeof (var_list));
copy->name= strdup (v->name);
copy->attr= v->attr;
copy->value= v->value;
copy->ant= copy_var_list_ini;
copy_var_list_ini= copy;
// next v
v= v->ant;
}
}
//
// swaps main and copied variable list
//
void SwapVariableLists (void)
{
var_list *v;
v= var_list_ini;
var_list_ini= copy_var_list_ini;
copy_var_list_ini= v;
}
//
// destroys copied variable list
//
void DestroyCopyVariableList (void)
{
DestroyVariableList (copy_var_list_ini);
}
//
// Checks 'entry' to see if it's a known variable
// Returns: 1 if found, 0 if not found
//
int CheckVariable (char *entry)
{
var_list *v;
int found=0;
v= var_list_ini;
while (v!=NULL && !found) {
if (strcmp (v->name, entry)==0) found= 1;
else v= v->ant;
}
return found;
}
//
// Updates value of 'ans' variable
//
void UpdateAnswerVariable (void)
{
var_list *v;
// find 'ans' first
v= FindVariable ("ans");
// update value
v->value= ResultValue ();
}
//
// called after a succesful evaluation of an expression
// updates system variables in case they have been changed by user
//
void UpdateSystemVariables (void)
{
var_list *v;
v= FindVariable ("ibase");
system_vars.ibase= (int) v->value;
v= FindVariable ("obase");
system_vars.ibase= (int) v->value;
}
//
// set system variable
//
void SetSystemVariable (int which, int value)
{
switch (which) {
case SYSTEMVAR_IBASE:
if (value<2 || value>36) NotifyError (PERROR_BASE_RANGE, NULL);
system_vars.ibase= value;
break;
case SYSTEMVAR_OBASE:
if (value<2 || value>36) NotifyError (PERROR_BASE_RANGE, NULL);
system_vars.obase= value;
break;
}
}
//
// get system variable
//
int GetSystemVariable (int which)
{
int value=0;
switch (which) {
case SYSTEMVAR_IBASE:
value= system_vars.ibase;
break;
case SYSTEMVAR_OBASE:
value= system_vars.obase;
break;
}
return value;
}
//
// Initialize system variables
//
void InitializeSystemVars (void)
{
system_vars.ibase= 10;
system_vars.obase= 10;
}
/*
Local Variables:
c-file-style: "gnu"
c-file-offsets: ((case-label . +))
End:
*/
Index: Makefile.am
===================================================================
RCS file: /cvsroot/ganc/ganc/src/Makefile.am,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** Makefile.am 7 Dec 2003 21:52:22 -0000 1.3
--- Makefile.am 20 Jan 2004 01:33:40 -0000 1.4
***************
*** 10,14 ****
## GUI extra sources and headers
if BUILD_GUI
! GUISRC = support.c interface.c callbacks.c reader_communication.c
GUIHDR = callbacks.h interface.h support.h
else
--- 10,14 ----
## GUI extra sources and headers
if BUILD_GUI
! GUISRC = support.c interface.c callbacks.c
GUIHDR = callbacks.h interface.h support.h
else
***************
*** 18,23 ****
! ganc_SOURCES = main.c reader_stuff.c evaluate.c syntax.y parser_stuff.c \
! terminal_stuff.c $(GUISRC)
ganc_LDADD = @LIBS@ @PACKAGE_LIBS@
--- 18,23 ----
! ganc_SOURCES = main.c display.c evaluate.c syntax.y parser_stuff.c \
! history.c variables.c $(GUISRC)
ganc_LDADD = @LIBS@ @PACKAGE_LIBS@
Index: callbacks.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/callbacks.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** callbacks.c 12 Dec 2003 23:57:37 -0000 1.9
--- callbacks.c 20 Jan 2004 01:33:40 -0000 1.10
***************
*** 9,17 ****
#include <string.h>
#include "include/functions.h"
#include "callbacks.h"
#include "interface.h"
#include "support.h"
- #include "pipe_stuff.h"
--- 9,17 ----
#include <string.h>
+ #include "include/defines.h"
#include "include/functions.h"
#include "callbacks.h"
#include "interface.h"
#include "support.h"
***************
*** 25,29 ****
--- 25,44 ----
extern GtkWidget *inv_button;
extern GtkWidget *hyp_button;
+ extern GtkTextBuffer *display_text_buffer;
+ extern GtkTextView *display;
+ extern GtkTextMark *start_mark;
+ extern GtkTextMark *end_mark;
+ extern GtkTextMark *insert_mark;
+ extern GtkTextMark *selection_mark;
+ extern GtkTextMark *cursor_mark;
+
+
+ /***********************************************************************
+ *
+ * Local Variables
+ *
+ ***********************************************************************/
+ static int user_action=0;
***************
*** 44,55 ****
void button_clicked (GtkWidget *widget, gpointer data)
{
! char *text;
! int i, pos;
! /* GdkEventKey event; */
const char *label;
int found=0;
label= gtk_button_get_label (GTK_BUTTON (widget));
- text= (char *) malloc (strlen (label) + 3);
strcpy (text, label);
--- 59,68 ----
void button_clicked (GtkWidget *widget, gpointer data)
{
! int i;
const char *label;
+ char text[20];
int found=0;
label= gtk_button_get_label (GTK_BUTTON (widget));
strcpy (text, label);
***************
*** 57,64 ****
--- 70,79 ----
if (!found && strcmp (text, "EE")==0 && ++found) strcpy (text, "E");
if (!found && strcmp (text, "1/x")==0 && ++found) strcpy (text, "^-1");
+ // add space to these ones
if (!found && (strcmp (text, "exp")==0 || strcmp (text, "ln")==0 ||
strcmp (text, "sqrt")==0 || strcmp (text, "log")==0)
&& ++found)
strcpy (text + strlen (text), " ");
+ // check inv or hyp for these ones
if (!found && (strcmp (text, "sin")==0 || strcmp (text, "cos")==0 ||
strcmp (text, "tan")==0) && ++found) {
***************
*** 73,76 ****
--- 88,92 ----
strcpy (text + strlen (text), " ");
}
+ // modify these ones
if (!found && strcmp (text, "x^2")==0 && ++found) strcpy (text, "^2");
if (!found && strcmp (text, "10^x")==0 && ++found) strcpy (text, "10^");
***************
*** 78,113 ****
if (!found && strcmp (text, "x!")==0 && ++found) strcpy (text, "!");
! SendInputRequest (PIPE_REQUEST_TEXT, text);
!
! /*
! // emulate event to send text as input to terminal
! event.type= GDK_KEY_PRESS;
! event.window= widget->window;
! event.send_event= FALSE;
! event.time= GDK_CURRENT_TIME;
! event.state= 0;
! event.keyval= GDK_5; // text inserted is in event.string
! event.length= strlen (text);
! event.string= strdup (text);
! gtk_widget_event (terminal, (GdkEvent *) &event);
! */
!
! /*pos= gtk_editable_get_position (GTK_EDITABLE (entry));
! gtk_editable_insert_text (GTK_EDITABLE (entry), text, strlen (text), &pos);
! gtk_editable_set_position (GTK_EDITABLE (entry), pos);*/
! //pos= gtk_editable_get_position (GTK_EDITABLE (textbox));
! pos= 0;
! //gtk_editable_insert_text (GTK_EDITABLE (textbox), text, strlen (text), &pos);
! // gtk_editable_set_position (GTK_EDITABLE (textbox), pos);
!
! // g_print ("Button %s pressed\n", (char *) data);
if (GTK_TOGGLE_BUTTON (inv_button)->active)
g_signal_emit_by_name (GTK_OBJECT (inv_button), "clicked");
- //gtk_signal_emit_by_name (GTK_OBJECT (inv_button), "clicked");
if (GTK_TOGGLE_BUTTON (hyp_button)->active)
g_signal_emit_by_name (GTK_OBJECT (hyp_button), "clicked");
- //gtk_signal_emit_by_name (GTK_OBJECT (hyp_button), "clicked");
- free (text);
- //gtk_widget_grab_focus (entry);
}
--- 94,104 ----
if (!found && strcmp (text, "x!")==0 && ++found) strcpy (text, "!");
! InsertText (text);
!
! // untoggle 'inv' and 'hyp' buttons if set
if (GTK_TOGGLE_BUTTON (inv_button)->active)
g_signal_emit_by_name (GTK_OBJECT (inv_button), "clicked");
if (GTK_TOGGLE_BUTTON (hyp_button)->active)
g_signal_emit_by_name (GTK_OBJECT (hyp_button), "clicked");
}
***************
*** 119,138 ****
void on_button_exe_clicked (GtkWidget *button, gpointer user_data)
{
! /* GdkEventKey event;
! char ret[]="\n";*/
!
! SendInputRequest (PIPE_REQUEST_EXECUTE, NULL);
! /*
! // emulate event to send text as input to terminal
! event.type= GDK_KEY_PRESS;
! event.window= GTK_WIDGET (button)->window;
! event.send_event= FALSE;
! event.time= GDK_CURRENT_TIME;
! event.state= 0;
! event.keyval= GDK_Return;
! event.length= 0;
! event.string= strdup (ret);
! gtk_widget_event (terminal, (GdkEvent *) &event);
! */
}
--- 110,114 ----
void on_button_exe_clicked (GtkWidget *button, gpointer user_data)
{
! ExpressionReady ();
}
***************
*** 151,219 ****
//
! // Callback to clear button
//
! void on_button_clear_clicked (GtkWidget *widget, gpointer data)
{
! /*GdkEventKey event;
! char text='\0';*/
! SendInputRequest (PIPE_REQUEST_BACKSPACE, NULL);
! /*
! // emulate event to send text as input to terminal
! event.type= GDK_KEY_PRESS;
! event.window= widget->window;
! event.send_event= FALSE;
! event.state= 0;
! event.time= GDK_CURRENT_TIME;
! event.keyval= GDK_BackSpace;
! event.length= strlen (&text);
! event.string= strdup (&text);
! gtk_widget_event (terminal, (GdkEvent *) &event);
! */
}
//
! // Callback to AC button (all clear). It clears the whole display screen
//
! void on_button_AC_clicked (GtkWidget *widget, gpointer data)
{
! /*GdkEventKey event;
! char text[]=" ";*/
!
! // send input request to clear line
! SendInputRequest (PIPE_REQUEST_CLEAR, NULL);
! /*
! // emulate event to send text as input to terminal
! event.type= GDK_KEY_PRESS;
! event.window= widget->window;
! event.send_event= FALSE;
!
! // send C-a ('a' with control mask set)
! event.state= GDK_CONTROL_MASK;
! event.time= GDK_CURRENT_TIME;
! event.keyval= GDK_a;
! text[0]= (char) 1; // this is the text produced by C-a
! event.length= strlen (text);
! event.string= strdup (text);
! gtk_widget_event (terminal, (GdkEvent *) &event);
! // send C-k ('k' with control mask set)
! event.time= GDK_CURRENT_TIME;
! event.keyval= GDK_k;
! text[0]= (char) 11; // this is the text produced by C-k
! event.string= strdup (text);
! gtk_widget_event (terminal, (GdkEvent *) &event);
! */
}
! // Function that creates a VTE_TERMINAL widget
! // Necessary because widget is defined as custom in glade
! // The actual 'terminal' widget is created in terminal_stuff.c
! GtkWidget* create_display (gchar *widget_name, gchar *string1, gchar *string2,
! gint int1, gint int2)
{
! return (terminal);
}
--- 127,184 ----
//
! // Callback to BackSpace button
//
! void on_button_bs_clicked (GtkWidget *widget, gpointer data)
{
! GtkTextIter sel_iter, insert_iter, start_iter;
! gtk_text_buffer_get_selection_bounds (display_text_buffer, &sel_iter, &insert_iter);
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
! // if either mark is before start, just put insert at end and do nothing
! if (gtk_text_iter_compare (&sel_iter, &start_iter)<0 ||
! gtk_text_iter_compare (&insert_iter, &start_iter)<0) {
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &insert_iter, end_mark);
! gtk_text_buffer_place_cursor (display_text_buffer, &insert_iter);
! gtk_text_buffer_get_selection_bounds (display_text_buffer, &sel_iter, &insert_iter);
! }
! // if nothing selected move sel_iter one backward
! if (gtk_text_iter_equal (&sel_iter, &insert_iter) &&
! gtk_text_iter_compare (&sel_iter, &start_iter)>0) {
! gtk_text_iter_backward_char (&sel_iter);
! }
! gtk_text_buffer_delete (display_text_buffer, &sel_iter, &insert_iter);
}
//
! // Callback to DEL button
//
! void on_button_del_clicked (GtkWidget *widget, gpointer data)
{
! GtkTextIter sel_iter, insert_iter, start_iter;
! gtk_text_buffer_get_selection_bounds (display_text_buffer, &sel_iter, &insert_iter);
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
! // if either mark is before start, just put insert at end and do nothing
! if (gtk_text_iter_compare (&sel_iter, &start_iter)<0 ||
! gtk_text_iter_compare (&insert_iter, &start_iter)<0) {
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &insert_iter, end_mark);
! gtk_text_buffer_place_cursor (display_text_buffer, &insert_iter);
! } else {
! // if nothing selected move insert_iter one forward
! if (gtk_text_iter_equal (&sel_iter, &insert_iter)) {
! gtk_text_iter_forward_char (&insert_iter);
! }
! gtk_text_buffer_delete (display_text_buffer, &sel_iter, &insert_iter);
! }
}
! //
! // Callback to AC button (all clear). It clears the whole display screen
! //
! void on_button_AC_clicked (GtkWidget *widget, gpointer data)
{
! ClearInputLine ();
}
***************
*** 242,249 ****
//
! // handle normal keys, notify reader of incoming input
//
! return FALSE; // let the normal process go through
}
--- 207,361 ----
//
! // handle normal keys
//
+ GtkTextIter insert_iter, start_iter;
+
+ // when key pressed produces text or is one of the list check that the
+ // cursor is not in the 'forbidden zone'
+ if (event->length>0 ||
+ event->keyval==GDK_BackSpace || event->keyval==GDK_Delete ||
+ event->keyval==GDK_Left || event->keyval==GDK_Right ||
+ event->keyval==GDK_Up || event->keyval==GDK_Down ||
+ event->keyval==GDK_Home || event->keyval==GDK_End) {
+ GtkTextIter sel_start, sel_end;
+
+ gtk_text_buffer_get_selection_bounds (display_text_buffer, &sel_start, &sel_end);
+ gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
+ if (gtk_text_iter_compare (&sel_start, &start_iter)<0 ||
+ gtk_text_iter_compare (&sel_end, &start_iter)<0) {
+ gtk_text_buffer_get_iter_at_mark (display_text_buffer, &insert_iter, cursor_mark);
+ gtk_text_buffer_place_cursor (display_text_buffer, &insert_iter);
+ }
+ }
! // RETURN
! if (event->keyval==GDK_Return) {
! ExpressionReady ();
!
! // stop signal
! gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "key-press-event");
! return TRUE;
! }
! // LEFT cursor (with or without Ctrl) or backspace
! if (event->keyval==GDK_Left || event->keyval==GDK_BackSpace) {
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &insert_iter, insert_mark);
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
! if (gtk_text_iter_compare (&insert_iter, &start_iter)<=0) {
! gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "key-press-event");
! return TRUE;
! }
! }
! // UP, DOWN, PGUP, PGDN -> travel around history
! if (event->keyval==GDK_Up || event->keyval==GDK_Down ||
! event->keyval==GDK_Page_Up || event->keyval==GDK_Page_Down) {
! TravelEntryHistory (event->keyval);
! gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "key-press-event");
! return TRUE;
! }
! // HOME pressed
! if (event->keyval==GDK_Home) {
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
! if (event->state&GDK_SHIFT_MASK) {
! gtk_text_buffer_move_mark (display_text_buffer, insert_mark, &start_iter);
! } else {
! gtk_text_buffer_place_cursor (display_text_buffer, &start_iter);
! }
! gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "key-press-event");
! return TRUE;
! }
! // C-k pressed
! if (event->keyval==GDK_k && event->state&GDK_CONTROL_MASK) {
! gtk_text_buffer_get_selection_bounds (display_text_buffer, &start_iter, &insert_iter);
! if (gtk_text_iter_equal (&start_iter, &insert_iter))
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &insert_iter, end_mark);
! gtk_text_buffer_delete (display_text_buffer, &start_iter, &insert_iter);
! gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "key-press-event");
! return TRUE;
! }
!
! return FALSE; // let the default callback be called
! }
!
!
! //
! // callback function called before any insertion of text happens
! // makes sure text doesn't get inserted in the 'forbidden zone'
! //
! void insert_event (GtkTextBuffer *textbuffer, GtkTextIter *iter,
! gchar *text, gint len, gpointer user_data)
! {
! GtkTextIter start_iter;
! int i=0;
!
! if (user_action) {
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
! if (gtk_text_iter_compare (iter, &start_iter) < 0) {
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, iter, start_mark);
! }
! gtk_text_buffer_place_cursor (display_text_buffer, iter);
! while (text[i]!='\n' && i<len) ++i;
! if (i<len) {
! g_signal_stop_emission_by_name ((gpointer) textbuffer, "insert-text");
! g_signal_emit_by_name ((gpointer) textbuffer, "insert-text", iter, text, i);
! }
! if (len>1) gtk_text_view_scroll_to_mark (GTK_TEXT_VIEW (display), insert_mark,
! 0., FALSE, 0., 0.);
! }
! }
!
!
! //
! // callback function called before a range of text is deleted
! //
! void delete_range_event (GtkTextBuffer *textbuffer, GtkTextIter *selstart,
! GtkTextIter *selend, gpointer user_data)
! {
! }
!
!
! //
! // callback function called whenever a tag is applied
! // filters tags applied by user_action (like paste text from result tag area)
! //
! void apply_tag_event (GtkTextBuffer *textbuffer, GtkTextTag *tag,
! GtkTextIter *start, GtkTextIter *end, gpointer user_data)
! {
! if (user_action) {
! g_signal_stop_emission_by_name ((gpointer)textbuffer, "apply-tag");
! }
! }
!
!
! //
! // callback function called anytime a user action happens
! //
! void begin_user_action_event (GtkTextBuffer *textbuffer, gpointer user_data)
! {
! user_action= 1;
! }
!
!
! //
! // callback function called anytime a user action ends
! //
! void end_user_action_event (GtkTextBuffer *textbuffer, gpointer user_data)
! {
! user_action= 0;
! }
!
!
! //
! // callback function called before a select-all event happens
! // makes sure all means only current input line
! //
! void select_all_event (GtkTextView *textview, gboolean arg1, gpointer user_data)
! {
! GtkTextIter start_iter, end_iter;
!
! gtk_signal_emit_stop_by_name (GTK_OBJECT (textview), "select-all");
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &start_iter, start_mark);
! gtk_text_buffer_get_iter_at_mark (display_text_buffer, &end_iter, end_mark);
! gtk_text_buffer_move_mark (display_text_buffer, selection_mark, &start_iter);
! gtk_text_buffer_move_mark (display_text_buffer, insert_mark, &end_iter);
}
***************
*** 261,262 ****
--- 373,383 ----
gtk_dialog_run (GTK_DIALOG (about));
}
+
+
+
+ /*
+ Local Variables:
+ c-file-style: "gnu"
+ c-file-offsets: ((case-label . +))
+ End:
+ */
Index: callbacks.h
===================================================================
RCS file: /cvsroot/ganc/ganc/src/callbacks.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** callbacks.h 12 Dec 2003 23:57:37 -0000 1.2
--- callbacks.h 20 Jan 2004 01:33:40 -0000 1.3
***************
*** 6,10 ****
void on_radiobutton_toggled (GtkToggleButton *button, gpointer data);
! void on_button_clear_clicked (GtkWidget *widget, gpointer data);
void on_button_AC_clicked (GtkWidget *widget, gpointer data);
--- 6,12 ----
void on_radiobutton_toggled (GtkToggleButton *button, gpointer data);
! void on_button_bs_clicked (GtkWidget *widget, gpointer data);
!
! void on_button_del_clicked (GtkWidget *widget, gpointer data);
void on_button_AC_clicked (GtkWidget *widget, gpointer data);
***************
*** 19,22 ****
--- 21,38 ----
gpointer user_data);
+ void insert_event (GtkTextBuffer *textbuffer, GtkTextIter *arg1,
+ gchar *arg2, gint arg3, gpointer user_data);
+ void delete_range_event (GtkTextBuffer *textbuffer, GtkTextIter *arg1,
+ GtkTextIter *arg2, gpointer user_data);
+ void apply_tag_event (GtkTextBuffer *textbuffer, GtkTextTag *arg1,
+ GtkTextIter *arg2, GtkTextIter *arg3, gpointer user_data);
+ void begin_user_action_event (GtkTextBuffer *textbuffer, gpointer user_data);
+ void end_user_action_event (GtkTextBuffer *textbuffer, gpointer user_data);
+ void select_all_event (GtkTextView *textview, gboolean arg1, gpointer user_data);
+
+
+
+
+
void
call_about_dialog (GtkMenuItem *menuitem,
Index: evaluate.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/evaluate.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** evaluate.c 13 Dec 2003 23:55:56 -0000 1.8
--- evaluate.c 20 Jan 2004 01:33:40 -0000 1.9
***************
*** 5,21 ****
#include <math.h>
#include <stdlib.h>
- #include <signal.h>
#include <string.h>
! #include "include/evaluate_stuff.h"
!
!
! /***********************************************************************
! *
! * Extern functions
! *
! ***********************************************************************/
! void CreateNewVariable (char *new_name, VALUE_TYPE value, short attributes);
! int GetInputBase (void);
--- 5,12 ----
#include <math.h>
#include <stdlib.h>
#include <string.h>
! #include "include/defines.h"
! #include "include/functions.h"
***************
*** 27,66 ****
***********************************************************************/
static VALUE_TYPE rad_to_any; // factor used in angle conversion
- static VALUE_TYPE PI; // value of PI
- /*static int math_error=0; // stores error in case of math error
- // (not volatile anymore since we don't handle FPE exceptions)*/
- // obsolete piece of code
- /*
- // Floating points exception (FPE) handler
- void FPE_handler (int signum)
- {
- math_error= PERROR_MATH_FPE_ERROR;
- }
-
- // Installs the math handler
- void install_FPE_handler (void)
- {
- signal (SIGFPE, FPE_handler);
- }
-
- */
-
-
- //
- // Sets up value for PI (called at start up when Initializing variables)
- //
- void SetUpPI (void)
- {
- PI= ((VALUE_TYPE) 4.)*atanl ((VALUE_TYPE) 1.);
- // define PI variable in calculator
- CreateNewVariable ("pi", PI, VAR_ATTR_READONLY);
- CreateNewVariable ("PI", PI, VAR_ATTR_READONLY);
- }
-
-
//
// Sets up rad_to_any to perform the right angle conversion
--- 18,25 ----
***************
*** 69,78 ****
{
if (strcmp (label, "Deg")==0) { // deg selected
! rad_to_any= ((VALUE_TYPE) 360./2.)/PI;
} else {
if (strcmp (label, "Rad")==0) { // rad selected
! rad_to_any= 1.;
} else { // grad selected
! rad_to_any= ((VALUE_TYPE) 400./2.)/PI;
}
}
--- 28,37 ----
{
if (strcmp (label, "Deg")==0) { // deg selected
! rad_to_any= ((VALUE_TYPE) 360./2.)/CONSTANT_PI;
} else {
if (strcmp (label, "Rad")==0) { // rad selected
! rad_to_any= (VALUE_TYPE) 1.;
} else { // grad selected
! rad_to_any= ((VALUE_TYPE) 400./2.)/CONSTANT_PI;
}
}
***************
*** 266,291 ****
}
- /*
- //
- // Used to query if there has been a math error
- // returns the value of 'math_error'
- //
- int MathError (void)
- {
- return math_error;
- }
-
//
- // Resets the value of math_error.
- // Called when math error has been detected and handled
- //
- void ResetMathError (void)
- {
- math_error= 0;
- }
- */
-
// evaluates a number taking into account the default input basis
VALUE_TYPE EvaluateNumber (char *strnumber)
{
--- 225,232 ----
}
//
// evaluates a number taking into account the default input basis
+ //
VALUE_TYPE EvaluateNumber (char *strnumber)
{
***************
*** 295,299 ****
// get current input base
! base= GetInputBase ();
if (base==10) { // base 10, we can do non integer stuff
--- 236,240 ----
// get current input base
! base= GetSystemVariable (SYSTEMVAR_IBASE);
if (base==10) { // base 10, we can do non integer stuff
Index: interface.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/interface.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** interface.c 14 Dec 2003 00:26:55 -0000 1.3
--- interface.c 20 Jan 2004 01:33:40 -0000 1.4
***************
*** 95,102 ****
GtkWidget *handlebox1;
GtkWidget *menubar1;
GtkWidget *vbox2;
! GtkWidget *hbox2;
GtkWidget *display;
- GtkWidget *vscrollbar1;
GtkWidget *frame1;
GtkWidget *hbox1;
--- 95,102 ----
GtkWidget *handlebox1;
GtkWidget *menubar1;
+ GtkAccelGroup *accel_group;
GtkWidget *vbox2;
! GtkWidget *scrolledwindow1;
GtkWidget *display;
GtkWidget *frame1;
GtkWidget *hbox1;
***************
*** 109,113 ****
GtkWidget *button1;
GtkWidget *button2;
- GtkWidget *button3;
GtkWidget *button6;
--- 109,112 ----
***************
*** 129,137 ****
gtk_box_pack_start (GTK_BOX (vbox1), handlebox1, FALSE, TRUE, 0);
menubar1 = gtk_menu_bar_new ();
gtk_widget_show (menubar1);
gtk_container_add (GTK_CONTAINER (handlebox1), menubar1);
gnome_app_fill_menu (GTK_MENU_SHELL (menubar1), menubar1_uiinfo,
! NULL, FALSE, 0);
vbox2 = gtk_vbox_new (FALSE, 0);
--- 128,140 ----
gtk_box_pack_start (GTK_BOX (vbox1), handlebox1, FALSE, TRUE, 0);
+ // create accelerator group
+ accel_group = gtk_accel_group_new ();
+ gtk_window_add_accel_group (GTK_WINDOW (window1), accel_group);
+
menubar1 = gtk_menu_bar_new ();
gtk_widget_show (menubar1);
gtk_container_add (GTK_CONTAINER (handlebox1), menubar1);
gnome_app_fill_menu (GTK_MENU_SHELL (menubar1), menubar1_uiinfo,
! accel_group, FALSE, 0);
vbox2 = gtk_vbox_new (FALSE, 0);
***************
*** 140,156 ****
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 5);
! hbox2 = gtk_hbox_new (FALSE, 0);
! gtk_widget_show (hbox2);
! gtk_box_pack_start (GTK_BOX (vbox2), hbox2, TRUE, TRUE, 0);
! display = create_display ("display", "", NULL, 40, 20);
gtk_widget_show (display);
! gtk_box_pack_start (GTK_BOX (hbox2), display, TRUE, TRUE, 0);
! GTK_WIDGET_SET_FLAGS (display, GTK_CAN_FOCUS);
! GTK_WIDGET_SET_FLAGS (display, GTK_CAN_DEFAULT);
!
! vscrollbar1 = gtk_vscrollbar_new (GTK_ADJUSTMENT (gtk_adjustment_new (0, 0, 0, 0, 0, 0)));
! gtk_widget_show (vscrollbar1);
! gtk_box_pack_start (GTK_BOX (hbox2), vscrollbar1, FALSE, TRUE, 0);
frame1 = gtk_frame_new (NULL);
--- 143,155 ----
gtk_container_set_border_width (GTK_CONTAINER (vbox2), 5);
! scrolledwindow1 = gtk_scrolled_window_new (NULL, NULL);
! gtk_widget_show (scrolledwindow1);
! gtk_box_pack_start (GTK_BOX (vbox2), scrolledwindow1, TRUE, TRUE, 0);
! gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolledwindow1), GTK_POLICY_NEVER, GTK_POLICY_ALWAYS);
! display = gtk_text_view_new ();
! gtk_widget_set_size_request (display, 250, 200);
gtk_widget_show (display);
! gtk_container_add (GTK_CONTAINER (scrolledwindow1), display);
frame1 = gtk_frame_new (NULL);
***************
*** 192,199 ****
button1 = make_empty_space (table1, 2, 3, 0, 1);
button2 = make_empty_space (table1, 3, 4, 0, 1);
- button3 = make_empty_space (table1, 4, 5, 0, 1);
make_button (window1, "button4", _("AC"), on_button_AC_clicked,
table1, 5, 0);
! make_button (window1, "button5", _("C"), on_button_clear_clicked,
table1, 6, 0);
--- 191,199 ----
button1 = make_empty_space (table1, 2, 3, 0, 1);
button2 = make_empty_space (table1, 3, 4, 0, 1);
make_button (window1, "button4", _("AC"), on_button_AC_clicked,
+ table1, 4, 0);
+ make_button (window1, "button5", _("<-"), on_button_bs_clicked,
table1, 5, 0);
! make_button (window1, "button5", _("DEL"), on_button_del_clicked,
table1, 6, 0);
***************
*** 287,293 ****
GLADE_HOOKUP_OBJECT (window1, menuitem5_menu_uiinfo[0].widget, "menuitem6");
GLADE_HOOKUP_OBJECT (window1, vbox2, "vbox2");
- GLADE_HOOKUP_OBJECT (window1, hbox2, "hbox2");
GLADE_HOOKUP_OBJECT (window1, display, "display");
- GLADE_HOOKUP_OBJECT (window1, vscrollbar1, "vscrollbar1");
GLADE_HOOKUP_OBJECT (window1, frame1, "frame1");
GLADE_HOOKUP_OBJECT (window1, hbox1, "hbox1");
--- 287,291 ----
***************
*** 298,302 ****
GLADE_HOOKUP_OBJECT (window1, button1, "button1");
GLADE_HOOKUP_OBJECT (window1, button2, "button2");
- GLADE_HOOKUP_OBJECT (window1, button3, "button3");
GLADE_HOOKUP_OBJECT (window1, button6, "button6");
--- 296,299 ----
***************
*** 307,311 ****
GLADE_HOOKUP_OBJECT (window1, statusbar1, "statusbar1");
! gtk_widget_grab_default (display);
return window1;
}
--- 304,308 ----
GLADE_HOOKUP_OBJECT (window1, statusbar1, "statusbar1");
! //gtk_widget_grab_default (display);
return window1;
}
***************
*** 316,320 ****
const gchar *authors[] = {
"Xavier Martinez Hidalgo",
! "Jose Marino\t",
NULL
};
--- 313,317 ----
const gchar *authors[] = {
"Xavier Martinez Hidalgo",
! "Jose Marino",
NULL
};
Index: main.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/main.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** main.c 12 Dec 2003 19:10:01 -0000 1.8
--- main.c 20 Jan 2004 01:33:40 -0000 1.9
***************
*** 6,14 ****
#include <string.h>
#include <stdio.h>
- #include <signal.h>
#include <sys/wait.h>
#ifdef BUILD_GUI
#include <gtk/gtk.h>
#include "callbacks.h"
#include "support.h"
--- 6,15 ----
#include <string.h>
#include <stdio.h>
#include <sys/wait.h>
#ifdef BUILD_GUI
#include <gtk/gtk.h>
+ #include <gconf/gconf-client.h>
+ #include <pango/pango-font.h>
#include "callbacks.h"
#include "support.h"
***************
*** 16,21 ****
#endif
#include "include/functions.h"
! #include "include/evaluate_stuff.h"
--- 17,23 ----
#endif
+ #include "include/defines.h"
#include "include/functions.h"
!
***************
*** 29,34 ****
--- 31,43 ----
GtkWidget *inv_button;
GtkWidget *hyp_button;
+ GtkTextBuffer *display_text_buffer;
+ GtkWidget *display;
#endif
+ extern GtkTextMark *start_mark;
+ extern GtkTextMark *end_mark;
+ extern GtkTextMark *insert_mark;
+ extern GtkTextMark *selection_mark;
+ extern GtkTextMark *cursor_mark;
/***********************************************************************
***************
*** 38,41 ****
--- 47,51 ----
***********************************************************************/
static void InitializeVars (void);
+ static void SetUpInterface (void);
static void CleanUp (void);
***************
*** 50,61 ****
InitMainVarList ();
- /* // Add default variables to variable list
- CreateNewVariable ("ans", 0., VAR_ATTR_READONLY); // define ans (previous answer)
- */
// First calculator is in degree mode
SetUpAngleConversion ("Deg");
! // FPE signals are not raised, so we don't bother setting up the handler
! // install_FPE_handler ();
}
--- 60,71 ----
InitMainVarList ();
// First calculator is in degree mode
SetUpAngleConversion ("Deg");
! // initialize history
! InitializeHistory ();
!
! // initialize system vars
! InitializeSystemVars ();
}
***************
*** 68,71 ****
--- 78,83 ----
// free memory of variable list
DestroyMainVarList ();
+ // free history's memory
+ RemoveHistory ();
}
***************
*** 77,113 ****
// It set ups everything and then gives control to GUI (gtk_main)
//
! void RunMainProcess (FILE *from_reader, FILE *to_reader)
{
GtkWidget *window;
! GtkWidget *scrollbar1;
// create interface
window= create_window1 ();
! TerminalSetGeometry (window);
gtk_widget_show (window); // show main window
// extract widgets
! scrollbar1= lookup_widget (window, "vscrollbar1");
inv_button= lookup_widget (window, "togglebutton1");
hyp_button= lookup_widget (window, "togglebutton2");
- // do some stuff with terminal
- TerminalConnectScrollbar (terminal, scrollbar1);
! // pipe streams stored as data in window
! gtk_object_set_data (GTK_OBJECT (window), "from_reader",
! (gpointer) from_reader);
! gtk_object_set_data (GTK_OBJECT (window), "to_reader",
! (gpointer) to_reader);
! // Attach a callback to the pipe from the reader
! /* gtk_input_add_full (fileno (from_reader), GDK_INPUT_READ,
! ReaderHasLine, NULL, (gpointer) window, NULL);*/
! gtk_main (); // start gtk loop
}
#endif
//
// main function
--- 89,167 ----
// It set ups everything and then gives control to GUI (gtk_main)
//
! static void SetUpInterface (void)
{
GtkWidget *window;
! GtkTextIter start_iter;
// create interface
window= create_window1 ();
! //TerminalSetGeometry (window);
gtk_widget_show (window); // show main window
// extract widgets
! //scrollbar1= lookup_widget (window, "vscrollbar1");
inv_button= lookup_widget (window, "togglebutton1");
hyp_button= lookup_widget (window, "togglebutton2");
! // set up text buffer stuff
! display= lookup_widget (window, "display");
!
! // get font from gnome preferences and set it
! {
! PangoFontDescription *monospace_font_desc;
! GConfClient *conf_client;
!
! conf_client= gconf_client_get_default ();
! monospace_font_desc= pango_font_description_from_string (gconf_client_get_string (conf_client, "/desktop/gnome/interface/monospace_font_name", NULL));
! gtk_widget_modify_font (display, monospace_font_desc);
! pango_font_description_free (monospace_font_desc);
! g_object_unref (G_OBJECT (conf_client));
! }
! display_text_buffer= gtk_text_view_get_buffer (GTK_TEXT_VIEW (display));
! gtk_text_view_set_editable (GTK_TEXT_VIEW (display), TRUE);
! gtk_text_view_set_wrap_mode (GTK_TEXT_VIEW (display), GTK_WRAP_CHAR);
! // create tags
! gtk_text_buffer_create_tag (display_text_buffer, "error",
! "foreground", "red",
! NULL);
! gtk_text_buffer_create_tag (display_text_buffer, "result",
! "justification", GTK_JUSTIFY_RIGHT,
! "right-margin", 10,
! NULL);
!
! // create initial mark for start of line
! gtk_text_buffer_get_iter_at_offset (display_text_buffer, &start_iter, 0);
! PrintPrompt (&start_iter);
! start_mark= gtk_text_buffer_create_mark (display_text_buffer, "start-line",
! &start_iter, TRUE);
! end_mark= gtk_text_buffer_create_mark (display_text_buffer, "end-line",
! &start_iter, FALSE);
! cursor_mark= gtk_text_buffer_create_mark (display_text_buffer, "cursor",
! &start_iter, FALSE);
! insert_mark= gtk_text_buffer_get_insert (display_text_buffer);
! selection_mark= gtk_text_buffer_get_mark (display_text_buffer, "selection_bound");
!
!
! // signal connections
! g_signal_connect ((gpointer) display_text_buffer, "insert-text",
! G_CALLBACK (insert_event), NULL);
! g_signal_connect ((gpointer) display_text_buffer, "delete-range",
! G_CALLBACK (delete_range_event), NULL);
! g_signal_connect ((gpointer) display_text_buffer, "apply-tag",
! G_CALLBACK (apply_tag_event), NULL);
! g_signal_connect ((gpointer) display_text_buffer, "begin-user-action",
! G_CALLBACK (begin_user_action_event), NULL);
! g_signal_connect ((gpointer) display_text_buffer, "end-user-action",
! G_CALLBACK (end_user_action_event), NULL);
! g_signal_connect ((gpointer) display, "select-all",
! G_CALLBACK (select_all_event), NULL);
}
#endif
+
//
// main function
***************
*** 124,134 ****
InitializeVars ();
! // create terminal widget that'll be used as display
! CreateTerminal ();
! // fork processes:
! // - main_process (with gtk)
! // - reader_process (with readline)
! StartProcesses ();
// clean up everything before leaving
--- 178,186 ----
InitializeVars ();
! // set up gtk interface
! SetUpInterface ();
! // start gtk loop
! gtk_main ();
// clean up everything before leaving
Index: parser_stuff.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/parser_stuff.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -C2 -d -r1.12 -r1.13
*** parser_stuff.c 14 Jan 2004 20:16:22 -0000 1.12
--- parser_stuff.c 20 Jan 2004 01:33:40 -0000 1.13
***************
*** 4,13 ****
#include <stdlib.h>
- #include <stdio.h>
#include <string.h>
#include <ctype.h>
#include "include/functions.h"
- #include "include/evaluate_stuff.h"
#include "syntax.h" // include header file generated by bison
--- 4,13 ----
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
+ //#include <stdio.h>
+ #include "include/defines.h"
#include "include/functions.h"
#include "syntax.h" // include header file generated by bison
***************
*** 15,29 ****
/***********************************************************************
*
! * Local Types
*
***********************************************************************/
! // Name list used to keep the list of defined variables (typedef in mytypes.h)
! struct var_list_struct {
! char *name; // contains name of variable
! short attr; // attributes of variable
! VALUE_TYPE value; // value of variable
! struct var_list_struct *ant; // previous member in list
! };
// Name list used to keep track of names defined during parsing, (typedef in mytypes.h)
// it allows efficient memory usage in case of parsing error
--- 15,29 ----
/***********************************************************************
*
! * External Functions
*
***********************************************************************/
! int yyparse (void);
!
+ /***********************************************************************
+ *
+ * Local Types
+ *
+ ***********************************************************************/
// Name list used to keep track of names defined during parsing, (typedef in mytypes.h)
// it allows efficient memory usage in case of parsing error
***************
*** 32,35 ****
--- 32,36 ----
struct name_list_struct *ant;
};
+ typedef struct name_list_struct name_list;
***************
*** 40,51 ****
***********************************************************************/
static char *NewNameListEntry (char *newname);
- static int ValidVariableName (char *name);
- static var_list *MakeCopyVariableList (void);
- static void DestroyVariableList (var_list *ini);
static void DestroyNameList (void);
- static void UpdateAnswerVariable (void);
- static var_list *FindVariable (char *name);
static void ResetParseError (void);
! static void ResetOutputFormat (void);
--- 41,47 ----
***********************************************************************/
static char *NewNameListEntry (char *newname);
static void DestroyNameList (void);
static void ResetParseError (void);
! static void ResetResultData (void);
***************
*** 56,65 ****
*
***********************************************************************/
- static var_list *var_list_ini; // Initial node of variable list
static name_list *name_list_ini; // Initial node of name list (local to this file)
static int pos; // position on input text of parse position
static char *input; // input text to be parsed
- static VALUE_TYPE expression_value; // Variable where final result of parsing is given
- static int ibase=10, obase=10; // input and output base
static char *function_names[]={ // Names of defined functions
"abs", //0
--- 52,58 ----
***************
*** 83,123 ****
""
};
! static struct {
! int set;
! int base...
[truncated message content] |
|
From: <ho...@us...> - 2004-01-20 01:33:43
|
Update of /cvsroot/ganc/ganc/src/include
In directory sc8-pr-cvs1:/tmp/cvs-serv28642/src/include
Modified Files:
functions.h
Added Files:
defines.h parser.h
Removed Files:
evaluate_stuff.h mytypes.h pipe_stuff.h
Log Message:
Changed maaaaaaaaaaany things:
- Eliminated dependency on libzvt and readline, now the whole thing is
pure gtk (using GtkTextView for the display) and it looks nice
- Thus, now there's no 'forking' around and no pipes
- Major rearrangement of files (yes again!)
Added: display.c history.c variables.c defines.h parser.h
Removed: reader_communication.c reader_stuff.c terminal_stuff.c
evaluate_stuff.h mytypes.h pipe_stuff.h
- Now, and so far, is not possible to compile text only version
--- NEW FILE: defines.h ---
#ifndef __INCLUDED_DEFINES_H__
#define __INCLUDED_DEFINES_H__
// Basic type for operations in the calculator
#define VALUE_TYPE long double
// definition of infinity, it depens on what VALUE_TYPE is
//#define INFINITY HUGE_VALL
// defines zero in our type VALUE_TYPE
#define ZEROVALUE (VALUE_TYPE) 0.
// defines PI in long double format
#define CONSTANT_PI 3.1415926535897932384626433832795029L
// Definitions to identify functions
#define FUN_ABS 0
#define FUN_SIN 1
#define FUN_COS 2
#define FUN_TAN 3
#define FUN_ASIN 4
#define FUN_ACOS 5
#define FUN_ATAN 6
#define FUN_SINH 7
#define FUN_COSH 8
#define FUN_TANH 9
#define FUN_ASINH 10
#define FUN_ACOSH 11
#define FUN_ATANH 12
#define FUN_EXP 13
#define FUN_LN 14
#define FUN_EXP10 15
#define FUN_LOG 16
#define FUN_SQRT 17
// errors
#define PERROR_UNKNOWN_VAR 1
#define PERROR_SYNTAX_ERROR 2
#define PERROR_PARSE_ERROR 3
#define PERROR_ISOLATED_DOT 4
#define PERROR_EMPTY 5
#define PERROR_BASE_RANGE 6
#define PERROR_BASE_ERROR 7
#define PERROR_INVALID_ARG_LN 8
#define PERROR_INVALID_ARG_LOG 9
#define PERROR_INVALID_ARG_FACT 10
#define PERROR_INVALID_ARG_SQRT 11
#define PERROR_INVALID_ARG_ASIN 12
#define PERROR_INVALID_ARG_ACOS 13
#define PERROR_DIVISION_ZERO 14
#define PERROR_OVERFLOW 15
#define PERROR_NAN 16
#define PERROR_ASSIGNMENT_CONSTANT 17
#define PERROR_ILLEGAL_IDENTIFIER 18
#define PERROR_ILLEGAL_CONSTANT 19
// variable attributes
#define VAR_ATTR_NORMAL 0x0000
#define VAR_ATTR_READONLY 0x0001
#define VAR_ATTR_SYSTEM 0x0002
// output format items
#define OUTPUT_FORMAT_BASE 0x0001
#define OUTPUT_FORMAT_PRINTBASE 0x0002
// system variables
#define SYSTEMVAR_IBASE 0x0001
#define SYSTEMVAR_OBASE 0x0002
#endif /* end of defines.h */
/*
Local Variables:
c-file-style: "gnu"
c-file-offsets: ((case-label . +))
End:
*/
--- NEW FILE: parser.h ---
/* parser.h
* Header with all the stuff need by the parser (syntax.y)
*/
#ifndef __INCLUDED_PARSER_H__
#define __INCLUDED_PARSER_H__
#include "defines.h"
/* Definition of functions */
VALUE_TYPE AssignVariable (char *name, VALUE_TYPE value);
VALUE_TYPE EvaluateVariable (char *name);
VALUE_TYPE CalculateFactorial (VALUE_TYPE arg);
VALUE_TYPE EvaluateFunction (int id, VALUE_TYPE arg);
VALUE_TYPE Sumation (VALUE_TYPE arg1, VALUE_TYPE arg2);
VALUE_TYPE Substraction (VALUE_TYPE arg1, VALUE_TYPE arg2);
VALUE_TYPE Product (VALUE_TYPE arg1, VALUE_TYPE arg2);
VALUE_TYPE Division (VALUE_TYPE arg1, VALUE_TYPE arg2);
VALUE_TYPE Negation (VALUE_TYPE arg1);
VALUE_TYPE Modulus (VALUE_TYPE arg1, VALUE_TYPE arg2);
VALUE_TYPE Power (VALUE_TYPE arg1, VALUE_TYPE arg2);
VALUE_TYPE ChangeBase (char *based_number, VALUE_TYPE base);
void CheckNumber (VALUE_TYPE value);
VALUE_TYPE EvaluateNumber (char *number);
VALUE_TYPE BitwiseAnd (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE BitwiseOr (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE BitwiseXor (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE BitwiseNot (VALUE_TYPE value);
VALUE_TYPE BitwiseRightShift (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE BitwiseLeftShift (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicAnd (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicOr (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicDifferent (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicEqual (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicGT (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicLT (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicGE (VALUE_TYPE v1, VALUE_TYPE v2);
VALUE_TYPE LogicLE (VALUE_TYPE v1, VALUE_TYPE v2);
void OutputResult (VALUE_TYPE result);
void SetResultOutputFormat (int format, VALUE_TYPE value);
/* parser related functions */
int yyparse (void);
void yyerror (char *s);
int yylex (void);
void NotifyError (int error, char *extra);
int CheckForErrors (void);
#endif /* end of parser.h */
/*
Local Variables:
c-file-style: "gnu"
c-file-offsets: ((case-label . +))
End:
*/
Index: functions.h
===================================================================
RCS file: /cvsroot/ganc/ganc/src/include/functions.h,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** functions.h 7 Dec 2003 21:52:22 -0000 1.8
--- functions.h 20 Jan 2004 01:33:40 -0000 1.9
***************
*** 2,6 ****
#define __INCLUDED_FUNCTIONS_H__
! #include <stdio.h>
#ifdef BUILD_GUI
--- 2,6 ----
#define __INCLUDED_FUNCTIONS_H__
! //#include <stdio.h>
#ifdef BUILD_GUI
***************
*** 8,58 ****
#endif
! #include "mytypes.h"
// evaluate.c
- //void install_FPE_handler (void);
- void SetUpPI (void);
void SetUpAngleConversion (const char *label);
! //int MathError (void);
! //void ResetMathError (void);
!
! // main.c
! void RunMainProcess (FILE *from_reader, FILE *to_reader);
!
! // terminal_stuff.c
! void CreateTerminal (void);
! void StartProcesses (void);
! #ifdef BUILD_GUI
! void TerminalConnectScrollbar (GtkWidget *terminal, GtkWidget *scrollbar);
! void TerminalSetGeometry (GtkWidget *window);
! #endif
! // parser_stuff.c
void InitMainVarList (void);
void DestroyMainVarList (void);
int ParseTypedExpression (char *text);
void PopErrorDialog (char *s);
! VALUE_TYPE EvaluateVariable (char *name);
! void CreateNewVariable (char *new_name, VALUE_TYPE value, short attributes);
void OutputResult (VALUE_TYPE result);
! VALUE_TYPE ExpressionValue (void);
int ParseError (void);
char *ParseErrorExtra (void);
! int GetInputBase (void);
! int SetInputBase (int base);
! int SetOutputBase (int base);
! int GetOutputFormat (int format);
! void SetOutputFormat (int format, VALUE_TYPE value);
! // reader_stuff.c
! void RunReaderProcess (FILE *from_main, FILE *to_main);
- #ifdef BUILD_GUI
- // reader_communication.c
- void SendInputRequest (int request, char *text);
- //void ReaderHasLine (gpointer data, gint source, GdkInputCondition condition);
- void PassPipeVariables (FILE *f_reader, FILE *t_reader);
- void KillReaderProcess (void);
- #endif
#endif // End of functions.h
--- 8,57 ----
#endif
! #include "defines.h"
// evaluate.c
void SetUpAngleConversion (const char *label);
! void CheckNumber (VALUE_TYPE value);
! // variables.c
void InitMainVarList (void);
void DestroyMainVarList (void);
+ VALUE_TYPE EvaluateVariable (char *name);
+ VALUE_TYPE AssignVariable (char *name, VALUE_TYPE value);
+ void MakeCopyVariableList (void);
+ void SwapVariableLists (void);
+ void DestroyCopyVariableList (void);
+ int CheckVariable (char *entry);
+ void UpdateAnswerVariable (void);
+ void UpdateSystemVariables (void);
+ void SetSystemVariable (int which, int value);
+ int GetSystemVariable (int which);
+ void InitializeSystemVars (void);
+
+ // parser_stuff.c
int ParseTypedExpression (char *text);
void PopErrorDialog (char *s);
! void NotifyError (int error, char *extra);
void OutputResult (VALUE_TYPE result);
! VALUE_TYPE ResultValue (void);
int ParseError (void);
char *ParseErrorExtra (void);
! void SetResultOutputFormat (int format, VALUE_TYPE value);
! int GetResultOutputFormat (int format);
! // display.c
! void PrintPrompt (GtkTextIter *point_iter);
! void TravelEntryHistory (guint keyval);
! void InsertText (char *text);
! void ClearInputLine (void);
! void ExpressionReady (void);
!
! // history.c
! void InitializeHistory (void);
! void AddHistory (char *text);
! char *PreviousHistory (char *text);
! char *NextHistory (char *text);
! void RemoveHistory (void);
#endif // End of functions.h
--- evaluate_stuff.h DELETED ---
--- mytypes.h DELETED ---
--- pipe_stuff.h DELETED ---
|
|
From: <ho...@us...> - 2004-01-20 01:33:43
|
Update of /cvsroot/ganc/ganc
In directory sc8-pr-cvs1:/tmp/cvs-serv28642
Modified Files:
config.h.in configure.in ganc.glade2
Log Message:
Changed maaaaaaaaaaany things:
- Eliminated dependency on libzvt and readline, now the whole thing is
pure gtk (using GtkTextView for the display) and it looks nice
- Thus, now there's no 'forking' around and no pipes
- Major rearrangement of files (yes again!)
Added: display.c history.c variables.c defines.h parser.h
Removed: reader_communication.c reader_stuff.c terminal_stuff.c
evaluate_stuff.h mytypes.h pipe_stuff.h
- Now, and so far, is not possible to compile text only version
Index: config.h.in
===================================================================
RCS file: /cvsroot/ganc/ganc/config.h.in,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** config.h.in 7 Dec 2003 21:52:22 -0000 1.4
--- config.h.in 20 Jan 2004 01:33:40 -0000 1.5
***************
*** 7,13 ****
#undef HAVE_LIBM
- /* Define to 1 if you have the `readline' library (-lreadline). */
- #undef HAVE_LIBREADLINE
-
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
#undef NO_MINUS_C_MINUS_O
--- 7,10 ----
Index: configure.in
===================================================================
RCS file: /cvsroot/ganc/ganc/configure.in,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** configure.in 14 Dec 2003 00:26:55 -0000 1.16
--- configure.in 20 Jan 2004 01:33:40 -0000 1.17
***************
*** 5,9 ****
AC_INIT(src/main.c)
AM_CONFIG_HEADER(config.h)
! AM_INIT_AUTOMAKE([ganc], [env])
dnl ***** Do --enable --disable checks ******
--- 5,9 ----
AC_INIT(src/main.c)
AM_CONFIG_HEADER(config.h)
! AM_INIT_AUTOMAKE([ganc], [cvs])
dnl ***** Do --enable --disable checks ******
***************
*** 13,17 ****
dnl Check if GUI has been disabled by user (enabled by default)
AC_ARG_ENABLE([gui], AC_HELP_STRING([--disable-gui], [disable GUI (GUI is enabled by default)]),
! [BUILD_GUI=$enableval], [BUILD_GUI=yes])
dnl C stuff
--- 13,18 ----
dnl Check if GUI has been disabled by user (enabled by default)
AC_ARG_ENABLE([gui], AC_HELP_STRING([--disable-gui], [disable GUI (GUI is enabled by default)]),
! [BUILD_GUI=$enableval], [BUILD_GUI=yes])
! BUILD_GUI=yes
dnl C stuff
***************
*** 28,33 ****
CFLAGS="-Wall $CFLAGS"
! dnl Check headers
!
dnl bison stuff
--- 29,34 ----
CFLAGS="-Wall $CFLAGS"
! dnl When working with CVS version make all warnings errors and enable debug
! test "$VERSION" == "cvs" && CFLAGS="-Werror -g $CFLAGS" && COMPILE_DEBUG="yes"
dnl bison stuff
***************
*** 36,57 ****
YACC="$YACC -d -v"
- dnl check readline
- AC_CHECK_LIB([readline], [readline], , readline_found=no)
-
- dnl give a second chance to readline
- if test "$readline_found" = "no" ; then
- readline_found=yes
- AC_CHECK_LIB(termcap, tgetent, readline_lib=-ltermcap,
- [AC_CHECK_LIB(curses, tgetent, readline_lib=-lcurses,
- [AC_CHECK_LIB(ncurses, tgetent, readline_lib=-lncurses,
- readline_lib="")])])
-
- AC_CHECK_LIB([readline], [rl_getc], [], readline_found=no, $readline_lib)
- LIBS="$LIBS $readline_lib"
- fi
-
- dnl if readline not found yet, stop
- test "$readline_found" = "no" && AC_MSG_ERROR(GNU readline library not found)
-
dnl check for pkg-config
AC_CHECK_PROG(PKGCONFIG, pkg-config, yes, no)
--- 37,40 ----
***************
*** 60,64 ****
dnl Only check gnome stuff if GUI is enabled
if test "$BUILD_GUI" = "yes"; then
! pkg_modules="libgnomeui-2.0 libzvt-2.0"
dnl pkg_modules="libgnomeui-2.0 vte"
PKG_CHECK_MODULES(PACKAGE, [$pkg_modules], [BUILD_GUI=yes], [BUILD_GUI=no])
--- 43,47 ----
dnl Only check gnome stuff if GUI is enabled
if test "$BUILD_GUI" = "yes"; then
! pkg_modules="libgnomeui-2.0"
dnl pkg_modules="libgnomeui-2.0 vte"
PKG_CHECK_MODULES(PACKAGE, [$pkg_modules], [BUILD_GUI=yes], [BUILD_GUI=no])
Index: ganc.glade2
===================================================================
RCS file: /cvsroot/ganc/ganc/ganc.glade2,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** ganc.glade2 20 Nov 2003 03:31:39 -0000 1.1.1.1
--- ganc.glade2 20 Jan 2004 01:33:40 -0000 1.2
***************
*** 101,115 ****
<child>
! <widget class="Custom" id="display">
<property name="visible">True</property>
- <property name="can_default">True</property>
- <property name="has_default">True</property>
<property name="can_focus">True</property>
! <property name="creation_function">create_display</property>
! <property name="string1"></property>
! <property name="int1">40</property>
! <property name="int2">20</property>
! <property name="last_modification_time">Mon, 20 Oct 2003 18:49:12 GMT</property>
! <signal name="key_press_event" handler="on_display_key_press_event" last_modification_time="Mon, 20 Oct 2003 18:49:26 GMT"/>
</widget>
<packing>
--- 101,129 ----
<child>
! <widget class="GtkScrolledWindow" id="scrolledwindow1">
<property name="visible">True</property>
<property name="can_focus">True</property>
! <property name="hscrollbar_policy">GTK_POLICY_NEVER</property>
! <property name="vscrollbar_policy">GTK_POLICY_AUTOMATIC</property>
! <property name="shadow_type">GTK_SHADOW_NONE</property>
! <property name="window_placement">GTK_CORNER_TOP_LEFT</property>
!
! <child>
! <widget class="GtkTextView" id="textview1">
! <property name="visible">True</property>
! <property name="can_focus">True</property>
! <property name="editable">True</property>
! <property name="justification">GTK_JUSTIFY_LEFT</property>
! <property name="wrap_mode">GTK_WRAP_NONE</property>
! <property name="cursor_visible">True</property>
! <property name="pixels_above_lines">0</property>
! <property name="pixels_below_lines">0</property>
! <property name="pixels_inside_wrap">0</property>
! <property name="left_margin">0</property>
! <property name="right_margin">0</property>
! <property name="indent">0</property>
! <property name="text" translatable="yes"></property>
! </widget>
! </child>
</widget>
<packing>
|
|
From: <ho...@us...> - 2004-01-14 20:19:26
|
Update of /cvsroot/ganc/CVSROOT
In directory sc8-pr-cvs1:/tmp/cvs-serv28338
Modified Files:
loginfo
Log Message:
Commented line in 'loginfo' that tried to output commit info to file
$CVSROOT/CVSROOT/commitlog
It didn't work, giving a little error message in every commit.
Index: loginfo
===================================================================
RCS file: /cvsroot/ganc/CVSROOT/loginfo,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** loginfo 13 Dec 2003 22:59:24 -0000 1.6
--- loginfo 14 Jan 2004 20:19:20 -0000 1.7
***************
*** 29,32 ****
#DEFAULT (echo "") >> $CVSROOT/CVSROOT/history
! ALL (echo ""; id; echo %{sVv}; date; cat) >> $CVSROOT/CVSROOT/commitlog
ALL /cvsroot/sitedocs/CVSROOT/cvstools/syncmail %{sVv} gan...@li...
--- 29,32 ----
#DEFAULT (echo "") >> $CVSROOT/CVSROOT/history
! #ALL (echo ""; id; echo %{sVv}; date; cat) >> $CVSROOT/CVSROOT/commitlog
ALL /cvsroot/sitedocs/CVSROOT/cvstools/syncmail %{sVv} gan...@li...
|
|
From: <ho...@us...> - 2004-01-14 00:24:01
|
Update of /cvsroot/ganc/ganc/src
In directory sc8-pr-cvs1:/tmp/cvs-serv1995/src
Modified Files:
parser_stuff.c
Log Message:
Fixed bug that caused problems with numbers with signed exponent such as
2e-2 2e+2
Index: parser_stuff.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/parser_stuff.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -d -r1.10 -r1.11
*** parser_stuff.c 13 Dec 2003 23:55:56 -0000 1.10
--- parser_stuff.c 14 Jan 2004 00:23:58 -0000 1.11
***************
*** 313,316 ****
--- 313,321 ----
// we've got an 'entry', lets check it
if (epos>pos) {
+ // check if we have an exponent coming up
+ if (input[epos - 1]=='e' && (input[epos]=='+' || input[epos]=='-')) {
+ ++epos;
+ while (isdigit (input[epos])) ++epos;
+ }
// if 'syntactically' opened or closed
if (previous_token_closing) {
|
|
From: <ho...@us...> - 2003-12-17 00:21:26
|
Update of /cvsroot/ganc/web In directory sc8-pr-cvs1:/tmp/cvs-serv11217 Added Files: local_variables.php Log Message: OOPS, forgot to add one php file --- NEW FILE: local_variables.php --- <!-- define local variables --> <?php $current_version="0.7"; $home_class=""; $news_class=""; $screenshots_class=""; $download_class=""; ?> |
Update of /cvsroot/ganc/web In directory sc8-pr-cvs1:/tmp/cvs-serv10915 Added Files: download.php index.php news.php right_frame.php screenshots.php Removed Files: download.html index.html news.html screenshots.html Log Message: Converted web page from html into php --- NEW FILE: download.php --- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>Home - ganc</title> <link rel="Stylesheet" href="ganc.css" type="text/css" media="screen" /> <script src="scripts/x.js" type="text/javascript"></script> <script src="scripts/adjust-columns.js" type="text/javascript"></script> </head> <body> <!-- include some local_variables --> <?php include 'local_variables.php'; $download_class="active"; ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> <div id="leftframe-content"> <h2>Download</h2> <hr /> <p>To build ganc just do the usual: <br /><br /> ./configure <br /> make<br /> </p> <p>If you're building from CVS you may have to run autoconf and its buddies first. You can use a litle script already included:<br /><br /> ./reconf.sh<br /> ./configure<br /> make </p> <p> You can download ganc's source code from: </p> <ul> <li>Stable version <strong>0.7</strong>: <ul> <li>Source tarball: <a href="http://prdownloads.sourceforge.net/ganc/ganc-0.7.tar.gz?download">ganc-0.7.tar.gz</a></li> </ul> <li>Stable version <strong>0.6</strong>: <ul> <li>Source tarball: <a href="http://prdownloads.sourceforge.net/ganc/ganc-0.6.tar.gz?download">ganc-0.6.tar.gz</a></li> </ul> </li> <li>CVS at SourceForge.net: <ul> <li>Access the CVS repository anonymously at cvs.sf.net</li> To get the latest of the latest use:<br />    $ export CVS_RSH=ssh<br />    $ cvs -d:pserver:ano...@cv...:/cvsroot/ganc checkout ganc<br /> When asked for password just press Enter <li>Nightly tarball: <a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">ganc-cvsroot.tar.bz2</a></li> </ul> </li> </ul> <p>Check out <a href="http://sourceforge.net/project/showfiles.php?group_id=93373&release_id=193675">ganc's download page</a></p> </div> </div> <!---------------------------- Right frame -----------------------------> <?php include 'right_frame.php' ?> <!-------------------------------- Footer --------------------------------> <div id="footer"> <hr /> </div> </body> </html> --- NEW FILE: index.php --- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>Home - ganc</title> <link rel="Stylesheet" href="ganc.css" type="text/css" media="screen" /> <script src="scripts/x.js" type="text/javascript"></script> <script src="scripts/adjust-columns.js" type="text/javascript"></script> </head> <body> <!-- include some local_variables --> <?php include 'local_variables.php'; $home_class="active"; ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> <div id="leftframe-content"> <!-- this id is necessary for the javascript --> <h2>ganc</h2> <hr /> <p> ganc is a <strong>G</strong>nome-based <strong>A</strong>lgebraic <strong>N</strong>otation <strong>C</strong>alculator. <br /> Just a very very useful and simple algebraic calculator. But then again, not so simple. </p> <p> Have you ever done some simple calculation like adding a bunch of numbers. Then you made a mistake and all the numbers you'd typed so far got lost. Or maybe you finished, got your result and wondered if you made a mistake typing. Is the result correct? Well, I'm affraid the only way to know is do it again and hope you get the same result. </p> <p> Or maybe you were programing and wanted to transform that ugly hexadecimal or binary number into something more meaningful. Or viceversa. </p> <p>That's where ganc comes in. </p> <p> ganc has a very simple syntax. There's no learning curve. If you want to add two plus two you just type '2 + 2' and that's it! It can also handle more complicated stuff involving several expressions in the same line, functions, implicit product, variables, numbers in different bases, bitwise operations, logical operations, etc ... It even allows C-style in-line variable definition.<br /> Some examples of valid ganc expressions are: <table cellspacing="5"> <tr><td>2 + 2 * 3</td><td><em>precedence is handled adequately (= 8)<em></td></tr> <tr><td>sin 45</td><td><em>trigonometrical functions<em></td></tr> <tr><td>2 sin 45</td><td><em>implicit product</em></td></tr> <tr><td>a= 2 + 2 * 3</td><td><em>variable asignment</em></td></tr> <tr><td>2*a + 2a</td><td><em>variable use</em></td></tr> <tr><td>c= 2*b= a + 2a</td><td><em>in-line variable asignment (b=a + 2a and c= 2*(a + 2a))</em></td></tr> <tr><td>2 + 3; b= 1 - 2; 2b</td><td><em>several expressions at the same time</em></td></tr> <tr><td>1b5_16</td><td><em>hexadecimal number (base 16)</em></td></tr> <tr><td>3vgt_32; 1001_2</td><td><em>base 32 and binary</em></td></tr> <tr><td>23 :: _16</td><td><em>number 23 expressed in base 16</em></td></tr> <tr><td>f_16 & 1101_2</td><td><em>bitwise 'and' operation</em></td></tr> </table> <!-- <ul> <li><span>2 + 2 * 3</span><em>precedence is handled adequately (= 8)</em></li> <li><span>sin 45</span><em>trigonometrical functions</em></li> <li><span>2 sin 45</span><em>implicit product</em></li> <li><span>a= 2 + 2 * 3</span><em>variable asignment</em></li> <li><span>2*a + 2a</span><em>variable use</em></li> <li><span>c= 2*b= a + 2a</span><em>in-line variable asignment (b=a + 2a and c= 2*(a + 2a))</em></li> <li><span>2 + 3; b= 1 - 2; 2b</span><em>several expressions at the same time</em></li> <li><span>1b5_16</span><em>hexadecimal number (base 16)</em></li> <li><span>3vgt_32; 1001_2</span><em>base 32 and binary</em></li> <li><span>23 :: _16</span><em>number 23 expressed in base 16</em></li> <li><span>f_16 & 1101_2</span><em>bitwise 'and' operation</em></li> </ul> --> </p> <p> ganc also features a keypad so you don't have to type if you don't feel like it. You can achieve the same results just using your mouse. </p> <p> ganc adds the power and complexity of an algebraic calculator to the simplicity of a regular calculator. </p> </div> </div> <!---------------------------- Right frame -----------------------------> <?php include 'right_frame.php' ?> <!-------------------------------- Footer --------------------------------> <div id="footer"> <hr /> </div> </body> </html> --- NEW FILE: news.php --- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>Home - ganc</title> <link rel="Stylesheet" href="ganc.css" type="text/css" media="screen" /> <script src="scripts/x.js" type="text/javascript"></script> <script src="scripts/adjust-columns.js" type="text/javascript"></script> </head> <body> <!-- include some local_variables --> <?php include 'local_variables.php'; $news_class="active"; ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> <div id="leftframe-content"> <h2>News</h2> <hr /> <p class="date">Last stable version of ganc is <?php echo "$current_version" ?></p> <ul class="news"> <li>13th Dec 2003<span>ganc-0.7 released</span></li> A new hot right out of the oven release is out. Check it out in the download page. <li>21st Nov 2003<span>ganc's web page got updated</span></li> ganc's web page got a major makeover <li>19th Nov 2003<span>ganc goes on CVS</span></li> ganc's source code is in CVS!<br /> You can get it at SourceForge.net </ul> </div> </div> <!---------------------------- Right frame -----------------------------> <?php include 'right_frame.php' ?> <!-------------------------------- Footer --------------------------------> <div id="footer"> <hr /> </div> </body> </html> --- NEW FILE: right_frame.php --- <div id="rightframe"> <div id="rightframe-content"> <p> Download<br /> <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-<?php echo "$current_version" ?>.tar.gz?download">v<?php echo "$current_version" ?></a>]<br /> [<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small> </p> <p class="<?php echo "$home_class" ?>"><a href="index.php">Home</a></p> <p class="<?php echo "$news_class" ?>"><a href="news.php">News</a></p> <p class="<?php echo "$screenshots_class" ?>"><a href="screenshots.php">Screenshots</a></p> <p class="<?php echo "$download_class" ?>"><a href="download.php">Download</a></p> <p><a href="http://sourceforge.net/projects/ganc">Project page</a></p> <hr /> <div class="logo"> <!--<img src="images/local-sflogo.png" alt="SourceForge.net Logo" title="SourceForge.net" />--> <a href="http://sourceforge.net"> <img src="http://sourceforge.net/sflogo.php?group_id=93373&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></a> </div> </div> </div> --- NEW FILE: screenshots.php --- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>Home - ganc</title> <link rel="Stylesheet" href="ganc.css" type="text/css" media="screen" /> <script src="scripts/x.js" type="text/javascript"></script> <script src="scripts/adjust-columns.js" type="text/javascript"></script> </head> <body> <!-- include some local_variables --> <?php include 'local_variables.php'; $screenshots_class="active"; ?> <!---------------------------- Left frame -----------------------------> <div id="leftframe"> <div id="leftframe-content"> <h2>Screenshots</h2> <hr /> <p>Some screenshots of ganc in action</p> <div class="screenshot"> <img src="images/screenshot1.png" alt="screenshot1" title="screenshot1" /><br /> ganc demonstrating simple arithmetic operations, operator precedence, several expressions at a time, variable assignment, implicit product, and in-line assignment </div> <div class="screenshot"> <img src="images/screenshot2.png" alt="screenshot2" title="screenshot2" /><br /> arbitrary base expressions (up to base 36, after that we run out of letters :P) </div> </div> </div> <!---------------------------- Right frame -----------------------------> <?php include 'right_frame.php' ?> <!-------------------------------- Footer --------------------------------> <div class="footer"> <hr /> </div> </body> </html> --- download.html DELETED --- --- index.html DELETED --- --- news.html DELETED --- --- screenshots.html DELETED --- |
|
From: <ho...@us...> - 2003-12-15 05:16:19
|
Update of /cvsroot/ganc/web
In directory sc8-pr-cvs1:/tmp/cvs-serv8413
Modified Files:
index.html
Log Message:
Use table in index.html instead of relying on CSS (it doesn't work well in some browsers)
Index: index.html
===================================================================
RCS file: /cvsroot/ganc/web/index.html,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** index.html 14 Dec 2003 00:59:49 -0000 1.2
--- index.html 15 Dec 2003 05:16:16 -0000 1.3
***************
*** 31,35 ****
<p>
ganc has a very simple syntax. There's no learning curve. If you want to add two plus two
! you just type '2 + 2' and that's it!<br />
It can also handle more complicated stuff involving several expressions in the same line,
functions, implicit product, variables, numbers in different bases, bitwise operations,
--- 31,35 ----
<p>
ganc has a very simple syntax. There's no learning curve. If you want to add two plus two
! you just type '2 + 2' and that's it!
It can also handle more complicated stuff involving several expressions in the same line,
functions, implicit product, variables, numbers in different bases, bitwise operations,
***************
*** 37,40 ****
--- 37,54 ----
Some examples of valid ganc expressions are:
+ <table cellspacing="5">
+ <tr><td>2 + 2 * 3</td><td><em>precedence is handled adequately (= 8)<em></td></tr>
+ <tr><td>sin 45</td><td><em>trigonometrical functions<em></td></tr>
+ <tr><td>2 sin 45</td><td><em>implicit product</em></td></tr>
+ <tr><td>a= 2 + 2 * 3</td><td><em>variable asignment</em></td></tr>
+ <tr><td>2*a + 2a</td><td><em>variable use</em></td></tr>
+ <tr><td>c= 2*b= a + 2a</td><td><em>in-line variable asignment (b=a + 2a and c= 2*(a + 2a))</em></td></tr>
+ <tr><td>2 + 3; b= 1 - 2; 2b</td><td><em>several expressions at the same time</em></td></tr>
+ <tr><td>1b5_16</td><td><em>hexadecimal number (base 16)</em></td></tr>
+ <tr><td>3vgt_32; 1001_2</td><td><em>base 32 and binary</em></td></tr>
+ <tr><td>23 :: _16</td><td><em>number 23 expressed in base 16</em></td></tr>
+ <tr><td>f_16 & 1101_2</td><td><em>bitwise 'and' operation</em></td></tr>
+ </table>
+ <!--
<ul>
<li><span>2 + 2 * 3</span><em>precedence is handled adequately (= 8)</em></li>
***************
*** 50,53 ****
--- 64,68 ----
<li><span>f_16 & 1101_2</span><em>bitwise 'and' operation</em></li>
</ul>
+ -->
</p>
<p>
|
|
From: <ho...@us...> - 2003-12-15 04:49:06
|
Update of /cvsroot/ganc/web/images In directory sc8-pr-cvs1:/tmp/cvs-serv4805/images Modified Files: screenshot2.png Log Message: Updated web because of release ganc-0.7 Index: screenshot2.png =================================================================== RCS file: /cvsroot/ganc/web/images/screenshot2.png,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 Binary files /tmp/cvsdb19YK and /tmp/cvsKbSTHl differ |
|
From: <ho...@us...> - 2003-12-15 04:48:08
|
Update of /cvsroot/ganc/CVSROOT In directory sc8-pr-cvs1:/tmp/cvs-serv4669 Modified Files: cvswrappers Log Message: Made .gif, .png, .jpg files binary Index: cvswrappers =================================================================== RCS file: /cvsroot/ganc/CVSROOT/cvswrappers,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** cvswrappers 27 Oct 2003 16:13:35 -0000 1.1 --- cvswrappers 15 Dec 2003 04:48:05 -0000 1.2 *************** *** 22,23 **** --- 22,26 ---- # For example: #*.gif -k 'b' + *.gif -k 'b' + *.png -k 'b' + *.jpg -k 'b' |
|
From: <ho...@us...> - 2003-12-14 09:47:35
|
Update of /cvsroot/ganc/ganc In directory sc8-pr-cvs1:/tmp/cvs-serv14428 Modified Files: configure.in Removed Files: VERSION Log Message: Fixed some obsolete parse error names Index: configure.in =================================================================== RCS file: /cvsroot/ganc/ganc/configure.in,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** configure.in 13 Dec 2003 02:56:52 -0000 1.14 --- configure.in 13 Dec 2003 23:55:56 -0000 1.15 *************** *** 1,9 **** dnl Process this file with autoconf to produce a configure script. AC_INIT(src/main.c) AM_CONFIG_HEADER(config.h) ! AM_INIT_AUTOMAKE(ganc, cvs) ! dnl Do --enable --disable checks dnl Check if debug information has been enabled AC_ARG_ENABLE([debug], AC_HELP_STRING([--enable-debug], [compile with debug information '-g' (disabled by default)]), --- 1,11 ---- + dnl dnl Process this file with autoconf to produce a configure script. + dnl AC_INIT(src/main.c) AM_CONFIG_HEADER(config.h) ! AM_INIT_AUTOMAKE([ganc], [cvs]) ! dnl ***** Do --enable --disable checks ****** dnl Check if debug information has been enabled AC_ARG_ENABLE([debug], AC_HELP_STRING([--enable-debug], [compile with debug information '-g' (disabled by default)]), *************** *** 20,23 **** --- 22,26 ---- AC_PROG_CPP + dnl Print debug status AC_MSG_CHECKING(compiling with debugging information) AC_MSG_RESULT($COMPILE_DEBUG) *************** *** 27,30 **** --- 30,34 ---- dnl Check headers + dnl bison stuff AC_PROG_YACC *************** *** 86,90 **** echo echo ! echo $PACKAGE $VERSION echo echo Building GUI ............................ : $BUILD_GUI --- 90,94 ---- echo echo ! echo $PACKAGE-$VERSION echo echo Building GUI ............................ : $BUILD_GUI --- VERSION DELETED --- |
|
From: <ho...@us...> - 2003-12-14 09:47:35
|
Update of /cvsroot/ganc/ganc/src/include In directory sc8-pr-cvs1:/tmp/cvs-serv14428/src/include Modified Files: evaluate_stuff.h Log Message: Fixed some obsolete parse error names Index: evaluate_stuff.h =================================================================== RCS file: /cvsroot/ganc/ganc/src/include/evaluate_stuff.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** evaluate_stuff.h 12 Dec 2003 05:46:59 -0000 1.6 --- evaluate_stuff.h 13 Dec 2003 23:55:56 -0000 1.7 *************** *** 83,98 **** #define PERROR_PARSE_ERROR 3 #define PERROR_ISOLATED_DOT 4 ! #define PERROR_MATH_FPE_ERROR 5 ! #define PERROR_MATH_BASE_RANGE 6 ! #define PERROR_MATH_BASE_ERROR 7 ! #define PERROR_MATH_INVALID_ARG_LN 8 ! #define PERROR_MATH_INVALID_ARG_LOG 9 ! #define PERROR_MATH_INVALID_ARG_FACT 10 ! #define PERROR_MATH_INVALID_ARG_SQRT 11 ! #define PERROR_MATH_INVALID_ARG_ASIN 12 ! #define PERROR_MATH_INVALID_ARG_ACOS 13 ! #define PERROR_MATH_DIVISION_ZERO 14 ! #define PERROR_MATH_OVERFLOW 15 ! #define PERROR_MATH_NAN 16 #define PERROR_ASSIGNMENT_CONSTANT 17 #define PERROR_ILLEGAL_IDENTIFIER 18 --- 83,98 ---- #define PERROR_PARSE_ERROR 3 #define PERROR_ISOLATED_DOT 4 ! #define PERROR_EMPTY 5 ! #define PERROR_BASE_RANGE 6 ! #define PERROR_BASE_ERROR 7 ! #define PERROR_INVALID_ARG_LN 8 ! #define PERROR_INVALID_ARG_LOG 9 ! #define PERROR_INVALID_ARG_FACT 10 ! #define PERROR_INVALID_ARG_SQRT 11 ! #define PERROR_INVALID_ARG_ASIN 12 ! #define PERROR_INVALID_ARG_ACOS 13 ! #define PERROR_DIVISION_ZERO 14 ! #define PERROR_OVERFLOW 15 ! #define PERROR_NAN 16 #define PERROR_ASSIGNMENT_CONSTANT 17 #define PERROR_ILLEGAL_IDENTIFIER 18 |
|
From: <ho...@us...> - 2003-12-14 09:47:04
|
Update of /cvsroot/ganc/ganc/src
In directory sc8-pr-cvs1:/tmp/cvs-serv3117/src
Modified Files:
interface.c
Log Message:
Added Xavi to list of authors in About dialog
Index: interface.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/interface.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** interface.c 8 Dec 2003 19:58:49 -0000 1.2
--- interface.c 14 Dec 2003 00:26:55 -0000 1.3
***************
*** 315,322 ****
--- 315,324 ----
{
const gchar *authors[] = {
+ "Xavier Martinez Hidalgo",
"Jose Marino\t",
NULL
};
const gchar *documenters[] = {
+ "Xavier Martinez Hidalgo",
"Jose Marino",
NULL
|
|
From: <ho...@us...> - 2003-12-14 09:46:34
|
Update of /cvsroot/ganc/web
In directory sc8-pr-cvs1:/tmp/cvs-serv25017
Modified Files:
download.html index.html news.html screenshots.html
Log Message:
Some actualization of web page due to release of ganc-0.7
Index: download.html
===================================================================
RCS file: /cvsroot/ganc/web/download.html,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** download.html 23 Nov 2003 23:59:04 -0000 1.2
--- download.html 14 Dec 2003 00:59:49 -0000 1.3
***************
*** 26,29 ****
--- 26,33 ----
</p>
<ul>
+ <li>Stable version <strong>0.7</strong>:
+ <ul>
+ <li>Source tarball: <a href="http://prdownloads.sourceforge.net/ganc/ganc-0.7.tar.gz?download">ganc-0.7.tar.gz</a></li>
+ </ul>
<li>Stable version <strong>0.6</strong>:
<ul>
***************
*** 50,54 ****
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.6.tar.gz?download">v0.60</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
--- 54,58 ----
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.7.tar.gz?download">v0.70</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
Index: index.html
===================================================================
RCS file: /cvsroot/ganc/web/index.html,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** index.html 23 Nov 2003 00:23:04 -0000 1.1.1.1
--- index.html 14 Dec 2003 00:59:49 -0000 1.2
***************
*** 20,29 ****
Have you ever done some simple calculation like adding a bunch of numbers.
Then you made a mistake and all the numbers you'd typed so far got lost.
! Or maybe when you finished and got your result you wondered if you made a mistake typing.
! Is the result correct? Well, I'm affraid there's no way to know but to do it again.
</p>
<p>
Or maybe you were programing and wanted to transform that ugly hexadecimal or binary number into
! something more meaningful.
</p>
<p>That's where ganc comes in. </p>
--- 20,30 ----
Have you ever done some simple calculation like adding a bunch of numbers.
Then you made a mistake and all the numbers you'd typed so far got lost.
! Or maybe you finished, got your result and wondered if you made a mistake typing.
! Is the result correct? Well, I'm affraid the only way to know is do it again and
! hope you get the same result.
</p>
<p>
Or maybe you were programing and wanted to transform that ugly hexadecimal or binary number into
! something more meaningful. Or viceversa.
</p>
<p>That's where ganc comes in. </p>
***************
*** 32,37 ****
you just type '2 + 2' and that's it!<br />
It can also handle more complicated stuff involving several expressions in the same line,
! functions, implicit product, variables and numbers in different bases. It also allows C-style in-line
! variable definition. Some examples of valid ganc expressions are:
<ul>
<li><span>2 + 2 * 3</span><em>precedence is handled adequately (= 8)</em></li>
--- 33,40 ----
you just type '2 + 2' and that's it!<br />
It can also handle more complicated stuff involving several expressions in the same line,
! functions, implicit product, variables, numbers in different bases, bitwise operations,
! logical operations, etc ... It even allows C-style in-line variable definition.<br />
!
! Some examples of valid ganc expressions are:
<ul>
<li><span>2 + 2 * 3</span><em>precedence is handled adequately (= 8)</em></li>
***************
*** 42,47 ****
<li><span>c= 2*b= a + 2a</span><em>in-line variable asignment (b=a + 2a and c= 2*(a + 2a))</em></li>
<li><span>2 + 3; b= 1 - 2; 2b</span><em>several expressions at the same time</em></li>
! <li><span>F2_h; 1b5_16</span><em>hexadecimal number (base 16)</em></li>
! <li><span>3vgt_32; 1001_b</span><em>base 32 and binary</em></li>
</ul>
</p>
--- 45,52 ----
<li><span>c= 2*b= a + 2a</span><em>in-line variable asignment (b=a + 2a and c= 2*(a + 2a))</em></li>
<li><span>2 + 3; b= 1 - 2; 2b</span><em>several expressions at the same time</em></li>
! <li><span>1b5_16</span><em>hexadecimal number (base 16)</em></li>
! <li><span>3vgt_32; 1001_2</span><em>base 32 and binary</em></li>
! <li><span>23 :: _16</span><em>number 23 expressed in base 16</em></li>
! <li><span>f_16 & 1101_2</span><em>bitwise 'and' operation</em></li>
</ul>
</p>
***************
*** 60,64 ****
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.6.tar.gz?download">v0.60</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
--- 65,69 ----
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.7.tar.gz?download">v0.70</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
Index: news.html
===================================================================
RCS file: /cvsroot/ganc/web/news.html,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** news.html 23 Nov 2003 00:23:05 -0000 1.1.1.1
--- news.html 14 Dec 2003 00:59:49 -0000 1.2
***************
*** 13,18 ****
<h2>News</h2>
<hr />
! <p class="date">The last stable version of ganc is 0.6</p>
<ul class="news">
<li>21st Nov 2003<span>ganc's web page got updated</span></li>
ganc's web page got a major makeover
--- 13,21 ----
<h2>News</h2>
<hr />
! <p class="date">Last stable version of ganc is 0.7</p>
<ul class="news">
+ <li>13th Dec 2003<span>ganc-0.7 released</span></li>
+ A new hot right out of the oven release is out. Check it out in
+ the download page.
<li>21st Nov 2003<span>ganc's web page got updated</span></li>
ganc's web page got a major makeover
***************
*** 28,32 ****
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.6.tar.gz?download">v0.60</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
--- 31,35 ----
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.7.tar.gz?download">v0.70</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
Index: screenshots.html
===================================================================
RCS file: /cvsroot/ganc/web/screenshots.html,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** screenshots.html 23 Nov 2003 00:23:04 -0000 1.1.1.1
--- screenshots.html 14 Dec 2003 00:59:49 -0000 1.2
***************
*** 29,33 ****
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.6.tar.gz?download">v0.60</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
--- 29,33 ----
<p>
Download<br />
! <small>[<a href="http://prdownloads.sourceforge.net/ganc/ganc-0.7.tar.gz?download">v0.70</a>]<br />
[<a href="http://cvs.sourceforge.net/cvstarballs/ganc-cvsroot.tar.bz2">Nightly CVS tarball</a>]</small>
</p>
|
|
From: <ho...@us...> - 2003-12-14 08:45:41
|
Update of /cvsroot/ganc/ganc In directory sc8-pr-cvs1:/tmp/cvs-serv3117 Modified Files: configure.in Log Message: Added Xavi to list of authors in About dialog Index: configure.in =================================================================== RCS file: /cvsroot/ganc/ganc/configure.in,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** configure.in 13 Dec 2003 23:55:56 -0000 1.15 --- configure.in 14 Dec 2003 00:26:55 -0000 1.16 *************** *** 5,9 **** AC_INIT(src/main.c) AM_CONFIG_HEADER(config.h) ! AM_INIT_AUTOMAKE([ganc], [cvs]) dnl ***** Do --enable --disable checks ****** --- 5,9 ---- AC_INIT(src/main.c) AM_CONFIG_HEADER(config.h) ! AM_INIT_AUTOMAKE([ganc], [env]) dnl ***** Do --enable --disable checks ****** |
|
From: <ho...@us...> - 2003-12-14 08:44:54
|
Update of /cvsroot/ganc/ganc/src
In directory sc8-pr-cvs1:/tmp/cvs-serv14428/src
Modified Files:
evaluate.c parser_stuff.c reader_stuff.c
Log Message:
Fixed some obsolete parse error names
Index: evaluate.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/evaluate.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** evaluate.c 12 Dec 2003 05:46:59 -0000 1.7
--- evaluate.c 13 Dec 2003 23:55:56 -0000 1.8
***************
*** 93,102 ****
if (id==FUN_ASIN) {
if (arg<(VALUE_TYPE) -1. || arg>(VALUE_TYPE) 1.)
! NotifyError (PERROR_MATH_INVALID_ARG_ASIN, NULL);
else result= rad_to_any*asinl (arg);
}
if (id==FUN_ACOS) {
if (arg<(VALUE_TYPE) -1. || arg>(VALUE_TYPE) 1.)
! NotifyError (PERROR_MATH_INVALID_ARG_ACOS, NULL);
result= rad_to_any*acosl (arg);
}
--- 93,102 ----
if (id==FUN_ASIN) {
if (arg<(VALUE_TYPE) -1. || arg>(VALUE_TYPE) 1.)
! NotifyError (PERROR_INVALID_ARG_ASIN, NULL);
else result= rad_to_any*asinl (arg);
}
if (id==FUN_ACOS) {
if (arg<(VALUE_TYPE) -1. || arg>(VALUE_TYPE) 1.)
! NotifyError (PERROR_INVALID_ARG_ACOS, NULL);
result= rad_to_any*acosl (arg);
}
***************
*** 110,123 ****
if (id==FUN_EXP) result= expl (arg);
if (id==FUN_LN) {
! if (arg<=0.0) NotifyError (PERROR_MATH_INVALID_ARG_LN, NULL);
else result= logl (arg);
}
if (id==FUN_EXP10) result= powl (10, arg);
if (id==FUN_LOG) {
! if (arg<=0.0) NotifyError (PERROR_MATH_INVALID_ARG_LOG, NULL);
else result= log10l (arg);
}
if (id==FUN_SQRT) {
! if (arg<=0.) NotifyError (PERROR_MATH_INVALID_ARG_SQRT, NULL);
else result= sqrtl (arg);
}
--- 110,123 ----
if (id==FUN_EXP) result= expl (arg);
if (id==FUN_LN) {
! if (arg<=0.0) NotifyError (PERROR_INVALID_ARG_LN, NULL);
else result= logl (arg);
}
if (id==FUN_EXP10) result= powl (10, arg);
if (id==FUN_LOG) {
! if (arg<=0.0) NotifyError (PERROR_INVALID_ARG_LOG, NULL);
else result= log10l (arg);
}
if (id==FUN_SQRT) {
! if (arg<=0.) NotifyError (PERROR_INVALID_ARG_SQRT, NULL);
else result= sqrtl (arg);
}
***************
*** 141,145 ****
if (i<=99) { // otherwise is too big
while (i>1) v= v*i--;
! } else NotifyError (PERROR_MATH_INVALID_ARG_FACT, NULL);
return v;
}
--- 141,145 ----
if (i<=99) { // otherwise is too big
while (i>1) v= v*i--;
! } else NotifyError (PERROR_INVALID_ARG_FACT, NULL);
return v;
}
***************
*** 194,198 ****
value= arg1/arg2;
// check if division by zero occured
! if (isinf (value)) NotifyError (PERROR_MATH_DIVISION_ZERO, NULL);
return value;
}
--- 194,198 ----
value= arg1/arg2;
// check if division by zero occured
! if (isinf (value)) NotifyError (PERROR_DIVISION_ZERO, NULL);
return value;
}
***************
*** 245,254 ****
if (base<2 || base>36) { // base is not within the valid range
! NotifyError (PERROR_MATH_BASE_RANGE, NULL);
return (VALUE_TYPE) 0.;
}
value= (VALUE_TYPE) strtoul (based_number, &tail, base);
if (*tail!='\0') { // there has been an error converting the number
! NotifyError (PERROR_MATH_BASE_ERROR, NULL);
}
--- 245,254 ----
if (base<2 || base>36) { // base is not within the valid range
! NotifyError (PERROR_BASE_RANGE, NULL);
return (VALUE_TYPE) 0.;
}
value= (VALUE_TYPE) strtoul (based_number, &tail, base);
if (*tail!='\0') { // there has been an error converting the number
! NotifyError (PERROR_BASE_ERROR, NULL);
}
***************
*** 262,267 ****
void CheckNumber (VALUE_TYPE value)
{
! if (isinf (value)) NotifyError (PERROR_MATH_OVERFLOW, NULL);
! if (isnan (value)) NotifyError (PERROR_MATH_NAN, NULL);
}
--- 262,267 ----
void CheckNumber (VALUE_TYPE value)
{
! if (isinf (value)) NotifyError (PERROR_OVERFLOW, NULL);
! if (isnan (value)) NotifyError (PERROR_NAN, NULL);
}
***************
*** 308,312 ****
value= (VALUE_TYPE) strtoul (strnumber, &tail, base);
if (*tail!='\0') { // error converting the number
! NotifyError (PERROR_MATH_BASE_ERROR, NULL);
}
}
--- 308,312 ----
value= (VALUE_TYPE) strtoul (strnumber, &tail, base);
if (*tail!='\0') { // error converting the number
! NotifyError (PERROR_BASE_ERROR, NULL);
}
}
Index: parser_stuff.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/parser_stuff.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** parser_stuff.c 13 Dec 2003 03:08:27 -0000 1.9
--- parser_stuff.c 13 Dec 2003 23:55:56 -0000 1.10
***************
*** 647,651 ****
int SetInputBase (int base)
{
! if (base<2 || base>36) NotifyError (PERROR_MATH_BASE_RANGE, NULL);
ibase= base;
--- 647,651 ----
int SetInputBase (int base)
{
! if (base<2 || base>36) NotifyError (PERROR_BASE_RANGE, NULL);
ibase= base;
***************
*** 660,664 ****
int SetOutputBase (int base)
{
! if (base<2 || base>36) NotifyError (PERROR_MATH_BASE_RANGE, NULL);
obase= base;
--- 660,664 ----
int SetOutputBase (int base)
{
! if (base<2 || base>36) NotifyError (PERROR_BASE_RANGE, NULL);
obase= base;
***************
*** 703,707 ****
output_format.base= (int) value;
if (output_format.base<2 || output_format.base>36)
! NotifyError (PERROR_MATH_BASE_RANGE, NULL);
break;
}
--- 703,707 ----
output_format.base= (int) value;
if (output_format.base<2 || output_format.base>36)
! NotifyError (PERROR_BASE_RANGE, NULL);
break;
}
Index: reader_stuff.c
===================================================================
RCS file: /cvsroot/ganc/ganc/src/reader_stuff.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** reader_stuff.c 13 Dec 2003 02:56:52 -0000 1.13
--- reader_stuff.c 13 Dec 2003 23:55:56 -0000 1.14
***************
*** 38,42 ****
"parse error",
"isolated decimal dot",
! "floating point exception", // 5
"base out of range",
"base conversion error",
--- 38,42 ----
"parse error",
"isolated decimal dot",
! "", // 5
"base out of range",
"base conversion error",
***************
*** 167,171 ****
{
int salir=0;
!
// set local variables to contain pipes
from_main= pipe_from_main;
--- 167,171 ----
{
int salir=0;
!
// set local variables to contain pipes
from_main= pipe_from_main;
***************
*** 181,185 ****
// **FIXME** this may not be very portable
rl_bind_key (DEL_KEY, rl_named_function ("delete-char"));
!
// loop ends when kill_yourself signal comes from pipe
while (!salir) { // loop never ends. It's killed from main process
--- 181,185 ----
// **FIXME** this may not be very portable
rl_bind_key (DEL_KEY, rl_named_function ("delete-char"));
!
// loop ends when kill_yourself signal comes from pipe
while (!salir) { // loop never ends. It's killed from main process
|
|
From: <ho...@us...> - 2003-12-14 08:37:39
|
Update of /cvsroot/ganc/CVSROOT
In directory sc8-pr-cvs1:/tmp/cvs-serv6791
Modified Files:
loginfo
Log Message:
Still trying to fix statistics problem
Index: loginfo
===================================================================
RCS file: /cvsroot/ganc/CVSROOT/loginfo,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** loginfo 13 Dec 2003 22:58:17 -0000 1.5
--- loginfo 13 Dec 2003 22:59:24 -0000 1.6
***************
*** 29,32 ****
#DEFAULT (echo "") >> $CVSROOT/CVSROOT/history
! ALL (echo ""; id; echo %{sVv}; date; cat) >> /cvsroot/ganc/CVSROOT/commitlog
ALL /cvsroot/sitedocs/CVSROOT/cvstools/syncmail %{sVv} gan...@li...
--- 29,32 ----
#DEFAULT (echo "") >> $CVSROOT/CVSROOT/history
! ALL (echo ""; id; echo %{sVv}; date; cat) >> $CVSROOT/CVSROOT/commitlog
ALL /cvsroot/sitedocs/CVSROOT/cvstools/syncmail %{sVv} gan...@li...
|